#1618 Fixing bug in well path angle calculation + corresponding update to fracture azimuth angle. Calculating difference between well path and fracture angle and displaying warning if less than 10 deg.

This commit is contained in:
astridkbjorke
2017-06-27 14:11:55 +02:00
parent 2501264013
commit 2625ce6ea9
6 changed files with 58 additions and 15 deletions

View File

@@ -156,15 +156,14 @@ double RigSimulationWellCoordsAndMD::simWellAzimuthAngle(const cvf::Vec3d& posit
p2 = m_wellPathPoints[closestIndex + 0];
}
cvf::Vec3d direction = p1 - p2;
cvf::Vec3d direction = p2 - p1;
if (abs(direction.x()) > 1e-5)
if (abs(direction.y()) > 1e-5)
{
double atanValue = direction.y() / direction.x();
double atanValue = direction.x() / direction.y();
azimuthAngle = atan(atanValue);
azimuthAngle = cvf::Math::toDegrees(azimuthAngle);
azimuthAngle = -azimuthAngle;
}
}