From d12388b23ee71cd4c61d845db22697f95b9489c9 Mon Sep 17 00:00:00 2001 From: Gareth Aneurin Tribello Date: Wed, 4 Dec 2024 08:35:30 +0000 Subject: [PATCH] Converted variables in Quaternion.cpp that were accidentally declared as float to doubles --- src/crystdistrib/Quaternion.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/crystdistrib/Quaternion.cpp b/src/crystdistrib/Quaternion.cpp index 700b04d016..677dd16eb9 100644 --- a/src/crystdistrib/Quaternion.cpp +++ b/src/crystdistrib/Quaternion.cpp @@ -334,7 +334,7 @@ void Quaternion::calculateCV( const unsigned& mode, const std::vector& m for(unsigned i=0; i<3; ++i) derivs[3][i] = (S)*(tdy[i].getRow(0) - tdx[i].getRow(1)) + (y[0]-x[1])*dS[i]; } else if ((x[0] > y[1])&(x[0] > z[2])) { - float S = sqrt(1.0 + x[0] - y[1] - z[2]) * 2; // S=4*qx + double S = sqrt(1.0 + x[0] - y[1] - z[2]) * 2; // S=4*qx for(unsigned i=0; i<3; ++i) dS[i] = (2/S)*(tdx[i].getRow(0) - tdy[i].getRow(1) - tdz[i].getRow(2)); vals[0] = (z[1] - y[2]) / S; @@ -350,7 +350,7 @@ void Quaternion::calculateCV( const unsigned& mode, const std::vector& m for(unsigned i=0; i<3; ++i) derivs[3][i] = (1/S)*(tdx[i].getRow(2) + tdz[i].getRow(0)) - (vals[3]/S)*dS[i]; } else if (y[1] > z[2]) { - float S = sqrt(1.0 + y[1] - x[0] - z[2]) * 2; // S=4*qy + double S = sqrt(1.0 + y[1] - x[0] - z[2]) * 2; // S=4*qy for(unsigned i=0; i<3; ++i) dS[i] = (2/S)*( -tdx[i].getRow(0) + tdy[i].getRow(1) - tdz[i].getRow(2)); @@ -367,7 +367,7 @@ void Quaternion::calculateCV( const unsigned& mode, const std::vector& m for(unsigned i=0; i<3; ++i) derivs[3][i] = (1/S)*(tdy[i].getRow(2) + tdz[i].getRow(1)) - (vals[3]/S)*dS[i]; } else { - float S = sqrt(1.0 + z[2] - x[0] - y[1]) * 2; // S=4*qz + double S = sqrt(1.0 + z[2] - x[0] - y[1]) * 2; // S=4*qz for(unsigned i=0; i<3; ++i) dS[i] = (2/S)*(-tdx[i].getRow(0) - tdy[i].getRow(1) + tdz[i].getRow(2));