The tensor transport-diffusion benchmark with the discontinuous Galerkin method.
int main(
int argc,
char**argv) {
space Xh (omega, argv[2],
"tensor");
Float alpha = (argc > 3) ? atof(argv[3]) : 1;
Float nu = (argc > 4) ? atof(argv[4]) : 3;
Float t0 = (argc > 5) ? atof(argv[5]) : acos(-1.)/8;
Float eps = (argc > 6) ? atof(argv[6]) : 1e-2;
size_t d = omega.dimension();
size_t k = Xh.degree();
+ eps*dddot(grad_h(
sigma), grad_h(tau)))
+ integrate ("boundary",
max(0, -dot(
u,normal()))*ddot(
sigma,tau))
+ integrate ("internal_sides",
- dot(
u,normal())*ddot(jump(
sigma),average(tau))
+ 0.5*alpha*abs(dot(
u,normal()))
*ddot(jump(
sigma),jump(tau)))
+ integrate("sides",
eps*
eta*penalty()*ddot(jump(
sigma),jump(tau))
- eps*ddot(jump(
sigma), average(grad_h(tau )*normal()))
- eps*ddot(jump(tau) , average(grad_h(
sigma)*normal())));
+ integrate ("boundary",
- eps*ddot(
sigma_g(
nu,t0),grad_h(tau)*normal())
}
field lh(Float epsilon, Float t, const test &v)
see the Float page for the full documentation
see the field page for the full documentation
see the geo page for the full documentation
see the problem page for the full documentation
see the catchmark page for the full documentation
see the environment page for the full documentation
see the space page for the full documentation
see the tensor page for the full documentation
see the test page for the full documentation
see the test page for the full documentation
The tensor transport-diffusion benchmark – right-hand-side and exact solution.
This file is part of Rheolef.
rheolef - reference manual