Skip to content
Snippets Groups Projects
Commit 8f55ab9c authored by akbib's avatar akbib Committed by akbib@FU-BERLIN.DE
Browse files

bugfix: indices were computed wrong

[[Imported from SVN: r11298]]
parent 51b53c8b
Branches
Tags
No related merge requests found
......@@ -210,7 +210,7 @@ private:
// the resulting matrix is skew symmetric with entries <cross,degGrad[i]>
for (int i=0; i<dim; i++)
for (int j=i+1; j<dim; j++) {
int k= (-(i+j))%dim;
int k= (dim-(i+j))%dim;
res[i][j] = (cross*defGrad[k])*std::pow(-1,k);
res[j][i] = -res[i][j];
}
......
......@@ -134,8 +134,8 @@ namespace Dune {
linDet = 0;
for (int i=0; i<2; i++)
for (int j=(i+1)%3; j<3; j++) {
int k=(-(i+j))%3;
for (int j=i+1; j<3; j++) {
int k=(3-(i+j))%3;
linDet[i][j] = u[j][k]*u[k][i] - u[j][i]*(1+u[k][k]);
linDet[j][i] = u[k][j]*u[i][k] - u[i][j]*(1+u[k][k]);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment