From 743b91054314cc76f9620d033d660057dcd8a30a Mon Sep 17 00:00:00 2001 From: Oliver Sander <sander@igpm.rwth-aachen.de> Date: Sun, 15 Apr 2012 16:14:27 +0000 Subject: [PATCH] Fixed very stupid index bug. Don't use a loop with 4 iteration to clear an array, if the array has only length 3. Boy, this did take a while to find... [[Imported from SVN: r8593]] --- 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 e3daeb91..63e5a1eb 100644 --- a/dune/gfe/cosseratenergystiffness.hh +++ b/dune/gfe/cosseratenergystiffness.hh @@ -170,7 +170,7 @@ public: // for testing Dune::array<Tensor3<double,3,4,4>, 3> dd_dq_dq; Rotation<double,3>::getSecondDerivativesOfDirectors(dd_dq_dq); - for (size_t i=0; i<4; i++) + for (size_t i=0; i<dDR_dv.size(); i++) dDR_dv[i] = 0; for (int i=0; i<3; i++) -- GitLab