an efficient C++ finite element environment
|
|
Go to the documentation of this file.
29 int main(
int argc,
char**argv) {
31 Float err_expected = (argc > 1) ? atof(argv[1]) : 1;
36 Float err_linf_l2 = 0,
41 bool have_meas_omega =
false;
42 dout <<
"# t err_l2(t) err_linf(t)" << endl;
43 while (
din >> even(t,uh)) {
44 const geo& omega = uh.get_geo();
45 if (!have_meas_omega) {
47 have_meas_omega =
true;
50 iopt.
set_order (2*uh.get_space().degree()+1);
54 err_linf_linf = max(err_linf_linf, err_linf);
55 err_linf_l2 = max(err_linf_l2, err_l2);
56 err_l2_l2 += sqr(err_l2);
57 dout << t <<
" " << err_l2 <<
" " << err_linf << endl;
60 err_l2_l2 = sqrt(err_l2_l2/
n);
61 dout <<
"# err_l2_l2 = " << err_l2_l2 << endl
62 <<
"# err_linf_l2 = " << err_linf_l2 << endl
63 <<
"# err_linf_linf = " << err_linf_linf << endl;
64 return (err_linf_l2 <= err_expected) ? 0 : 1;
see the catchmark page for the full documentation
see the field page for the full documentation
field_basic< Float > field
see the field page for the full documentation
std::enable_if< details::is_field_expr_v2_nonlinear_arg< Expr >::value &&! is_undeterminated< Result >::value, Result >::type integrate(const geo_basic< T, M > &omega, const Expr &expr, const integrate_option &iopt, Result dummy=Result())
see the integrate page for the full documentation
rheolef - reference manual
see the integrate_option page for the full documentation
field_basic< T, M > interpolate(const space_basic< T, M > &V2h, const field_basic< T, M > &u1h)
see the interpolate page for the full documentation
idiststream din
see the diststream page for the full documentation
see the environment page for the full documentation
int main(int argc, char **argv)
This file is part of Rheolef.
see the Float page for the full documentation
see the branch page for the full documentation
The diffusive Burgers equation – its exact solution.
odiststream dout(cout)
see the diststream page for the full documentation
see the geo page for the full documentation