Skip to content

Commit

Permalink
Changing Grid Quadrature class so that the quadrature points do not i…
Browse files Browse the repository at this point in the history
…nclude the domain boundaries, but the center of each subdomain.
  • Loading branch information
manavbhatia committed Feb 18, 2014
1 parent 5ec34c1 commit c25f937
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/quadrature/quadrature_grid_1D.C
Expand Up @@ -37,10 +37,11 @@ void QGrid::init_1D(const ElemType,

_points.resize(_order + 1);
_weights.resize(_order + 1);
Real dx = 2.0/(double)(_order+1);
for (int i = 0; i != _order + 1; ++i)
{
_points[i](0) = 2.0 * (double)i / (double)_order - 1.0;
_weights[i] = 2.0 / (double)(_order + 1);
_points[i](0) = ((i+0.5)*dx-1.0);
_weights[i] = dx;
}
return;
}
Expand Down

0 comments on commit c25f937

Please sign in to comment.