From fa044ef9dad54b074e0edb561ef4e49e740f3273 Mon Sep 17 00:00:00 2001
From: Oliver Sander <sander@igpm.rwth-aachen.de>
Date: Mon, 19 Dec 2011 16:18:46 +0000
Subject: [PATCH] bugfix: missing identity matrix in the
 longQuadraticMembraneEnergy

[[Imported from SVN: r8307]]
---
 dune/gfe/cosseratenergystiffness.hh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dune/gfe/cosseratenergystiffness.hh b/dune/gfe/cosseratenergystiffness.hh
index 5d2f0a97..8753f5ee 100644
--- a/dune/gfe/cosseratenergystiffness.hh
+++ b/dune/gfe/cosseratenergystiffness.hh
@@ -161,7 +161,7 @@ public:
         Dune::FieldMatrix<double,dim-1,dim-1> sym2x2;
         for (int i=0; i<dim-1; i++)
             for (int j=0; j<dim-1; j++)
-                sym2x2[i][j] = 0.5 * (U[i][j] + U[j][i]);
+                sym2x2[i][j] = 0.5 * (U[i][j] + U[j][i]) - (i==j);
 
         result += mu_ * sym2x2.frobenius_norm2();
         
-- 
GitLab