Commit b0a1a3fd authored by Andrew Heather's avatar Andrew Heather
Browse files

BUG: quaternion - corrected construction from rotation tensor. Fixes #1348

parent c07ab245
...@@ -259,7 +259,7 @@ inline Foam::quaternion::quaternion ...@@ -259,7 +259,7 @@ inline Foam::quaternion::quaternion
- rotationTensor.zz() - rotationTensor.zz()
); );
w_ = (rotationTensor.xz() - rotationTensor.xz())/s; w_ = (rotationTensor.xz() - rotationTensor.zx())/s;
v_[0] = (rotationTensor.xy() + rotationTensor.yx())/s; v_[0] = (rotationTensor.xy() + rotationTensor.yx())/s;
v_[1] = 0.25*s; v_[1] = 0.25*s;
v_[2] = (rotationTensor.yz() + rotationTensor.zy())/s; v_[2] = (rotationTensor.yz() + rotationTensor.zy())/s;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment