Skip to content
Snippets Groups Projects
Commit 50bd65ef authored by Amaury Johnen's avatar Amaury Johnen
Browse files

fix bug

parent 542bdc6f
No related branches found
No related tags found
No related merge requests found
...@@ -362,7 +362,7 @@ fullMatrix<double> generateBez2LagMatrixPyramid ...@@ -362,7 +362,7 @@ fullMatrix<double> generateBez2LagMatrixPyramid
{ {
if(exponent.size1() != point.size1() || exponent.size2() != point.size2() || if(exponent.size1() != point.size1() || exponent.size2() != point.size2() ||
exponent.size2() != 3){ exponent.size2() != 3){
Msg::Fatal("Wrong sizes for bez2lag matrix generation %d %d -- %d %d", Msg::Fatal("Wrong sizes for pyramid's bez2lag matrix generation %d %d -- %d %d",
exponent.size1(),point.size1(), exponent.size1(),point.size1(),
exponent.size2(),point.size2()); exponent.size2(),point.size2());
return fullMatrix<double>(1, 1); return fullMatrix<double>(1, 1);
...@@ -518,7 +518,7 @@ void bezierBasis::_construct(int parentType, int p) ...@@ -518,7 +518,7 @@ void bezierBasis::_construct(int parentType, int p)
if (parentType == TYPE_PYR) { if (parentType == TYPE_PYR) {
_numLagCoeff = p == 0 ? 4 : 8; _numLagCoeff = p == 0 ? 4 : 8;
_exponents = gmshGenerateMonomialsPyramidGeneral(false, 2, _order); _exponents = gmshGenerateMonomialsPyramidGeneral(false, _order+2, _order);
subPoints = generateSubPointsPyr(_order); subPoints = generateSubPointsPyr(_order);
_numDivisions = static_cast<int>(subPoints.size()); _numDivisions = static_cast<int>(subPoints.size());
......
...@@ -906,7 +906,7 @@ fullMatrix<double> gmshGenerateMonomialsPyramidGeneral( ...@@ -906,7 +906,7 @@ fullMatrix<double> gmshGenerateMonomialsPyramidGeneral(
} }
// Between bottom & top // Between bottom & top
for (int k = nk-1; k > 0; ++k) { for (int k = nk-1; k > 0; --k) {
int currentnij = pyr ? k+nij : nij; int currentnij = pyr ? k+nij : nij;
for (int i = 0; i <= currentnij; ++i) { for (int i = 0; i <= currentnij; ++i) {
for (int j = 0; j <= currentnij; ++j, ++index) { for (int j = 0; j <= currentnij; ++j, ++index) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment