Skip to content

Commit

Permalink
BUG: triangeI.H: barycentric coordinates error
Browse files Browse the repository at this point in the history
  • Loading branch information
mattijs committed Dec 23, 2011
1 parent 14ba48f commit 1f142fe
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/OpenFOAM/meshes/primitiveShapes/triangle/triangleI.H
Original file line number Diff line number Diff line change
Expand Up @@ -269,9 +269,9 @@ Foam::scalar Foam::triangle<Point, PointRef>::barycentric

bary.setSize(3);

bary[0] = (d11*d20 - d01*d21)/denom;
bary[1] = (d00*d21 - d01*d20)/denom;
bary[2] = 1.0 - bary[0] - bary[1];
bary[1] = (d11*d20 - d01*d21)/denom;
bary[2] = (d00*d21 - d01*d20)/denom;
bary[0] = 1.0 - bary[1] - bary[2];

return denom;
}
Expand Down

0 comments on commit 1f142fe

Please sign in to comment.