an efficient C++ finite element environment
|
|
Convection-diffusion equation by BDF2 scheme and the method of characteristics
int main (
int argc,
char **argv) {
string approx = (argc > 2) ? argv[2] : "P1";
Float nu = (argc > 3) ? atof(argv[3]) : 1e-2;
size_t n_max = (argc > 4) ? atoi(argv[4]) : 50;
size_t d = omega.dimension();
Float delta_t = 2*acos(-1.)/n_max;
space Vh (omega, approx,
"vector");
space Xh (omega, approx);
Xh.block ("boundary");
<< event (0, phi_h);
for (
size_t n = 1;
n <= n_max;
n++) {
phi_h_prec = phi_h;
dout << event (t, phi_h);
}
}
details::field_expr_v2_nonlinear_node_nary< typename details::function_traits< Function >::functor_type,typename details::field_expr_v2_nonlinear_terminal_wrapper_traits< Exprs >::type... > ::type compose(const Function &f, const Exprs &... exprs)
see the compose page for the full documentation
Float alpha[pmax+1][pmax+1]
see the catchmark page for the full documentation
rheolef::std enable_if ::type dot const Expr1 expr1, const Expr2 expr2 dot(const Expr1 &expr1, const Expr2 &expr2)
dot(x,y): see the expression page for the full documentation
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
Float phi(const point &nu, Float a, Float b)
see the space page for the full documentation
Convection-diffusion equation – the rotating hill benchmark.
std::enable_if< details::is_field_convertible< Expr >::value,details::field_expr_v2_nonlinear_terminal_field< typename Expr::scalar_type,typename Expr::memory_type,details::differentiate_option::gradient >>::type grad(const Expr &expr)
grad(uh): see the expression 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
int main(int argc, char **argv)
see the environment page for the full documentation
field lh(Float epsilon, Float t, const test &v)
see the characteristic page for the full documentation
This file is part of Rheolef.
see the test page for the full documentation
see the problem page for the full documentation
see the Float page for the full documentation
see the branch page for the full documentation
void set_family(family_type type)
see the test page for the full documentation
double Float
see the Float page for the full documentation
odiststream dout(cout)
see the diststream page for the full documentation
see the geo page for the full documentation