Skip to content
Snippets Groups Projects
Commit 9edaad6c authored by Oliver Sander's avatar Oliver Sander Committed by sander@FU-BERLIN.DE
Browse files

Simplify formula for a third derivative

[[Imported from SVN: r9191]]
parent 47f8e733
No related branches found
No related tags found
No related merge requests found
...@@ -387,10 +387,7 @@ public: ...@@ -387,10 +387,7 @@ public:
} else if (i==N-1 and j==N-1 and k==N-1) { } else if (i==N-1 and j==N-1 and k==N-1) {
dFdqdqdq[i][j][k] = -2.0/Dune::Power<3>::eval(q[N-1]) dFdqdqdq[i][j][k] = (2.0*p[N-1] -1 -4*p[N-1] -3*diffNormSquared)/(p[N-1]*Dune::Power<3>::eval(q[N-1]));
- (2*p[N-1]*p[N-1]*q[N-1] - p[N-1]*q[N-1]*q[N-1]) / (p[N-1]*p[N-1]*Dune::Power<4>::eval(q[N-1]))
+ 2 * (p[N-1]-q[N-1]) / (p[N-1]*Dune::Power<3>::eval(q[N-1]))
- 3 * diffNormSquared / (p[N-1]*Dune::Power<4>::eval(q[N-1]));
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment