Rheolef  7.2
an efficient C++ finite element environment
 
Loading...
Searching...
No Matches
sinusprod_helmholtz.h
Go to the documentation of this file.
1
25struct f {
26 Float operator() (const point& x) const {
27 switch (d) {
28 case 1: return (1+d*pi*pi)*sin(pi*x[0]);
29 case 2: return (1+d*pi*pi)*sin(pi*x[0])*sin(pi*x[1]);
30 default: return (1+d*pi*pi)*sin(pi*x[0])*sin(pi*x[1])*sin(pi*x[2]);
31 }}
32 f(size_t d1) : d(d1), pi(acos(Float(-1.0))) {}
33 size_t d; const Float pi;
34};
35struct g {
36 Float operator() (const point& x) const {
37 switch (d) {
38 case 1: return -pi;
39 case 2: return -pi*(sin(pi*x[0]) + sin(pi*x[1]));
40 default: return -pi*( sin(pi*x[0])*sin(pi*x[1])
41 + sin(pi*x[1])*sin(pi*x[2])
42 + sin(pi*x[2])*sin(pi*x[0]));
43 }}
44 g(size_t d1) : d(d1), pi(acos(Float(-1.0))) {}
45 size_t d; const Float pi;
46};
see the Float page for the full documentation
see the point page for the full documentation
Definition cavity_dg.h:29
point operator()(const point &x) const
Definition cavity_dg.h:30
f(size_t d1)
const Float pi
Definition cavity_dg.h:25
size_t d
point operator()(const point &x) const
Definition cavity_dg.h:26
g(size_t d1)
const Float pi