From 3d5cb115be2396f2629403db3586e80b91666c0d Mon Sep 17 00:00:00 2001 From: Oliver Sander <sander@igpm.rwth-aachen.de> Date: Fri, 13 Dec 2013 09:32:33 +0000 Subject: [PATCH] Bugfix: energy scalar product was plain wrong [[Imported from SVN: r9587]] --- dune/gfe/symmetricmatrix.hh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dune/gfe/symmetricmatrix.hh b/dune/gfe/symmetricmatrix.hh index 3ce94c90..d6d32d7c 100644 --- a/dune/gfe/symmetricmatrix.hh +++ b/dune/gfe/symmetricmatrix.hh @@ -72,7 +72,7 @@ public: T result = 0; for (size_t i=0; i<N; i++) for (size_t j=0; j<=i; j++) - result += (1+(i!=j)) * operator()(i,j) * v1[i] * v2[j]; + result += (1-0.5*(i==j)) * operator()(i,j) * (v1[i] * v2[j] + v1[j] * v2[i]); return result; } -- GitLab