~ubuntu-branches/ubuntu/trusty/rheolef/trusty

« back to all changes in this revision

Viewing changes to doc/pexamples/sinusprod.icc

  • Committer: Package Import Robot
  • Author(s): Pierre Saramito
  • Date: 2012-04-06 09:12:21 UTC
  • mfrom: (1.1.5)
  • Revision ID: package-import@ubuntu.com-20120406091221-m58me99p1nxqui49
Tags: 6.0-1
* New upstream release 6.0 (major changes):
  - massively distributed and parallel support
  - full FEM characteristic method (Lagrange-Gakerkin method) support
  - enhanced users documentation 
  - source code supports g++-4.7 (closes: #667356)
* debian/control: dependencies for MPI distributed solvers added
* debian/rules: build commands simplified
* debian/librheolef-dev.install: man1/* to man9/* added
* debian/changelog: package description rewritted (closes: #661689)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
const Float pi = acos(Float(-1.0));
 
2
struct u : std::unary_function<point,Float> {
 
3
  Float operator() (const point& x) const {
 
4
    switch (d) {
 
5
     case 0:  return 0;
 
6
     case 1:  return sin(pi*x[0]);
 
7
     case 2:  return sin(pi*x[0])*sin(pi*x[1]);
 
8
     default: return sin(pi*x[0])*sin(pi*x[1])*sin(pi*x[2]);
 
9
    }
 
10
  }
 
11
  u(size_t d1) : d(d1) {}
 
12
  size_t d;
 
13
};