From 7a3e435bcf6373a6beb670fdf3ebb08f15dae376 Mon Sep 17 00:00:00 2001
From: Oliver Sander <sander@igpm.rwth-aachen.de>
Date: Wed, 4 Jan 2012 11:07:46 +0000
Subject: [PATCH] Explicitly request Quaternion multiplication instead of
 Rotation multiplication. This is now mandatory since Quaternions are not
 implicitly casted to Rotations anymore (via Quaternion --> FieldVector<4> -->
 Rotation).  This implicit cast lead to a nasty bug here, because it involved
 a normalization of the argument.

[[Imported from SVN: r8347]]
---
 dune/gfe/rodlocalstiffness.hh | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/dune/gfe/rodlocalstiffness.hh b/dune/gfe/rodlocalstiffness.hh
index f518bad2..5fc8907d 100644
--- a/dune/gfe/rodlocalstiffness.hh
+++ b/dune/gfe/rodlocalstiffness.hh
@@ -258,10 +258,10 @@ interpolationDerivative(const Rotation<RT,3>& q0, const Rotation<RT,3>& q1, doub
         for (int j=0; j<4; j++)
             dw[j] = 0.5 * (i==j);  // dExp[j][i] at v=0
         
-        dw = q1InvQ0.mult(dw);
+        dw = q1InvQ0.Quaternion<double>::mult(dw);
         
         mat.umv(dw,grad[i]);
-        grad[i] = q1.mult(grad[i]);
+        grad[i] = q1.Quaternion<double>::mult(grad[i]);
 
     }
     }
@@ -295,10 +295,10 @@ interpolationDerivative(const Rotation<RT,3>& q0, const Rotation<RT,3>& q1, doub
         for (int j=0; j<4; j++)
             dw[j] = 0.5 * ((i-3)==j);  // dExp[j][i-3] at v=0
 
-        dw = q0InvQ1.mult(dw);
+        dw = q0InvQ1.Quaternion<double>::mult(dw);
         
         mat.umv(dw,grad[i]);
-        grad[i] = q0.mult(grad[i]);
+        grad[i] = q0.Quaternion<double>::mult(grad[i]);
 
     }
     }
@@ -384,7 +384,7 @@ interpolationVelocityDerivative(const Rotation<RT,3>& q0, const Rotation<RT,3>&
         grad[i] += addend0;
         grad[i] += vHv;
 
-        grad[i] = q0.mult(grad[i]);
+        grad[i] = q0.Quaternion<double>::mult(grad[i]);
     }
 
 
@@ -403,7 +403,7 @@ interpolationVelocityDerivative(const Rotation<RT,3>& q0, const Rotation<RT,3>&
 
         //  \parder{\xi}{w^1_j} = ...
         Dune::FieldVector<RT,3> dxi(0);
-        dExpInv.umv(q0Inv.mult(q1.mult(dw)), dxi);
+        dExpInv.umv(q0Inv.Quaternion<double>::mult(q1.Quaternion<double>::mult(dw)), dxi);
 
         Quaternion<RT> vHv;
         for (int j=0; j<4; j++) {
@@ -421,12 +421,12 @@ interpolationVelocityDerivative(const Rotation<RT,3>& q0, const Rotation<RT,3>&
         // ///////////////////////////////////
             
         
-        dw = q0Inv.mult(q1.mult(dw));
+        dw = q0Inv.Quaternion<double>::mult(q1.Quaternion<double>::mult(dw));
         
         mat.umv(dw,grad[i]);
         grad[i] += vHv;
 
-        grad[i] = q0.mult(grad[i]);
+        grad[i] = q0.Quaternion<double>::mult(grad[i]);
 
     }
 
-- 
GitLab