mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-12 08:25:03 -05:00
#1417 - pre-proto - Adding function for calculating perforation length in center cell - need to be extended for cases where perforation interval goes outside the center stimPlan cell.
This commit is contained in:
1 parent
8351c6f9d0
commit
ed03d1fb8e
5 files changed
+108
-9
No files matched your search
@@ -43,6 +43,7 @@
|
|||||||
#include "RimFractureTemplate.h"
|
#include "RimFractureTemplate.h"
|
||||||
#include "RimStimPlanFractureTemplate.h"
|
#include "RimStimPlanFractureTemplate.h"
|
||||||
#include "RigStimPlanCell.h"
|
#include "RigStimPlanCell.h"
|
||||||
|
#include "RimSimWellFracture.h"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -103,7 +104,7 @@ bool RifEclipseExportTools::writeFracturesToTextFile(const QString& fileName, c
|
|||||||
out << "\n";
|
out << "\n";
|
||||||
|
|
||||||
//Included for debug / prototyping only
|
//Included for debug / prototyping only
|
||||||
//printTransmissibilityFractureToWell(fractures, out, caseToApply);
|
printTransmissibilityFractureToWell(fractures, out, caseToApply);
|
||||||
|
|
||||||
printStimPlanFractureTrans(fractures, out);
|
printStimPlanFractureTrans(fractures, out);
|
||||||
|
|
||||||
@@ -607,9 +608,55 @@ void RifEclipseExportTools::printTransmissibilityFractureToWell(const std::vecto
|
|||||||
out << qSetFieldWidth(16);
|
out << qSetFieldWidth(16);
|
||||||
out << fracture->name().left(15) + " ";
|
out << fracture->name().left(15) + " ";
|
||||||
|
|
||||||
if (fracture->attachedFractureDefinition()->orientation == RimFractureTemplate::TRANSVERSE_WELL_PATH)
|
|
||||||
|
|
||||||
|
|
||||||
|
if (fracture->attachedFractureDefinition()->orientation == RimFractureTemplate::ALONG_WELL_PATH)
|
||||||
{
|
{
|
||||||
out << "Transverse Fracture";
|
out << "Linear inflow";
|
||||||
|
|
||||||
|
RimStimPlanFractureTemplate* fracTemplateStimPlan;
|
||||||
|
if (dynamic_cast<RimStimPlanFractureTemplate*>(fracture->attachedFractureDefinition()))
|
||||||
|
{
|
||||||
|
fracTemplateStimPlan = dynamic_cast<RimStimPlanFractureTemplate*>(fracture->attachedFractureDefinition());
|
||||||
|
}
|
||||||
|
else continue;
|
||||||
|
|
||||||
|
//TODO: Can be removed when implementation of dip angle is more general:
|
||||||
|
RimSimWellFracture* simWellFrac;
|
||||||
|
if (dynamic_cast<RimSimWellFracture*>(fracture))
|
||||||
|
{
|
||||||
|
simWellFrac = dynamic_cast<RimSimWellFracture*>(fracture);
|
||||||
|
}
|
||||||
|
else continue;
|
||||||
|
|
||||||
|
double wellDip = simWellFrac->wellDipAtFracturePosition();
|
||||||
|
|
||||||
|
double perforationLengthVert = fracture->perforationLength * cos(wellDip);
|
||||||
|
double perforationLengthHor = fracture->perforationLength * sin(wellDip);
|
||||||
|
|
||||||
|
RigStimPlanCell* stimPlanCell = fracTemplateStimPlan->getStimPlanCellAtWell();
|
||||||
|
//TODO: Error in getting the StimPlanWellCell here!!!
|
||||||
|
|
||||||
|
out << stimPlanCell->getI();
|
||||||
|
out << stimPlanCell->getJ();
|
||||||
|
|
||||||
|
//TODO: Check if perforation length is larger than cell - expand to neightbour cells if needed!
|
||||||
|
|
||||||
|
RigFractureTransCalc transmissibilityCalculator(caseToApply, fracture);
|
||||||
|
double RadTransInStimPlanCell = transmissibilityCalculator.computeLinearTransmissibilityToWellinStimPlanCell(stimPlanCell, perforationLengthVert, perforationLengthHor);
|
||||||
|
|
||||||
|
out << RadTransInStimPlanCell;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
if (fracture->attachedFractureDefinition()->orientation == RimFractureTemplate::TRANSVERSE_WELL_PATH
|
||||||
|
|| fracture->attachedFractureDefinition()->orientation == RimFractureTemplate::AZIMUTH)
|
||||||
|
{
|
||||||
|
out << "Radial inflow";
|
||||||
|
|
||||||
RimStimPlanFractureTemplate* fracTemplateStimPlan;
|
RimStimPlanFractureTemplate* fracTemplateStimPlan;
|
||||||
if (dynamic_cast<RimStimPlanFractureTemplate*>(fracture->attachedFractureDefinition()))
|
if (dynamic_cast<RimStimPlanFractureTemplate*>(fracture->attachedFractureDefinition()))
|
||||||
|
|||||||
@@ -110,6 +110,15 @@ double RimSimWellFracture::wellAzimuthAtFracturePosition()
|
|||||||
return simWellAzimuth;
|
return simWellAzimuth;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
///
|
||||||
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
double RimSimWellFracture::wellDipAtFracturePosition()
|
||||||
|
{
|
||||||
|
updateBranchGeometry();
|
||||||
|
double simWellDip = m_branchCenterLines[m_branchIndex].simWellDipAngle(fracturePosition());
|
||||||
|
return simWellDip;
|
||||||
|
}
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
///
|
///
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
|||||||
@@ -45,6 +45,7 @@ public:
|
|||||||
void updateAzimuthFromFractureDefinition() override;
|
void updateAzimuthFromFractureDefinition() override;
|
||||||
|
|
||||||
double wellAzimuthAtFracturePosition() override;
|
double wellAzimuthAtFracturePosition() override;
|
||||||
|
double wellDipAtFracturePosition();
|
||||||
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|||||||
@@ -138,7 +138,7 @@ double RigSimulationWellCoordsAndMD::simWellAzimuthAngle(const cvf::Vec3d& posit
|
|||||||
size_t closestIndex = findClosestIndex(position);
|
size_t closestIndex = findClosestIndex(position);
|
||||||
|
|
||||||
//For vertical well (x-component of direction = 0) returned angle will be 0.
|
//For vertical well (x-component of direction = 0) returned angle will be 0.
|
||||||
double AzimuthAngle = 0.0;
|
double azimuthAngle = 0.0;
|
||||||
|
|
||||||
if (closestIndex != cvf::UNDEFINED_DOUBLE)
|
if (closestIndex != cvf::UNDEFINED_DOUBLE)
|
||||||
{
|
{
|
||||||
@@ -162,13 +162,55 @@ double RigSimulationWellCoordsAndMD::simWellAzimuthAngle(const cvf::Vec3d& posit
|
|||||||
if (abs(direction.x()) > 1e-5)
|
if (abs(direction.x()) > 1e-5)
|
||||||
{
|
{
|
||||||
double atanValue = direction.y() / direction.x();
|
double atanValue = direction.y() / direction.x();
|
||||||
AzimuthAngle = atan(atanValue);
|
azimuthAngle = atan(atanValue);
|
||||||
AzimuthAngle = cvf::Math::toDegrees(AzimuthAngle);
|
azimuthAngle = cvf::Math::toDegrees(azimuthAngle);
|
||||||
AzimuthAngle = -AzimuthAngle;
|
azimuthAngle = -azimuthAngle;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return AzimuthAngle;
|
return azimuthAngle;
|
||||||
|
}
|
||||||
|
|
||||||
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
///
|
||||||
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
double RigSimulationWellCoordsAndMD::simWellDipAngle(const cvf::Vec3d& position) const
|
||||||
|
{
|
||||||
|
size_t closestIndex = findClosestIndex(position);
|
||||||
|
|
||||||
|
double dipAngle = 0.0;
|
||||||
|
|
||||||
|
if (closestIndex != cvf::UNDEFINED_DOUBLE)
|
||||||
|
{
|
||||||
|
cvf::Vec3d p1;
|
||||||
|
cvf::Vec3d p2;
|
||||||
|
|
||||||
|
if (closestIndex > 0)
|
||||||
|
{
|
||||||
|
p1 = m_wellPathPoints[closestIndex - 1];
|
||||||
|
p2 = m_wellPathPoints[closestIndex - 0];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
p1 = m_wellPathPoints[closestIndex + 1];
|
||||||
|
p2 = m_wellPathPoints[closestIndex + 0];
|
||||||
|
}
|
||||||
|
|
||||||
|
cvf::Vec3d direction = p1 - p2;
|
||||||
|
|
||||||
|
double horizonal = sqrt(pow(direction.x(), 2) + pow(direction.y(), 2));
|
||||||
|
double vertical = direction.z();
|
||||||
|
|
||||||
|
if (abs(vertical) > 1e-5)
|
||||||
|
{
|
||||||
|
double atanValue = vertical / horizonal;
|
||||||
|
dipAngle = atan(atanValue);
|
||||||
|
dipAngle = cvf::Math::toDegrees(dipAngle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return dipAngle;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
|||||||
@@ -44,7 +44,7 @@ public:
|
|||||||
size_t findClosestIndex(const cvf::Vec3d& position) const;
|
size_t findClosestIndex(const cvf::Vec3d& position) const;
|
||||||
|
|
||||||
double simWellAzimuthAngle(const cvf::Vec3d& position) const;
|
double simWellAzimuthAngle(const cvf::Vec3d& position) const;
|
||||||
|
double simWellDipAngle(const cvf::Vec3d& position) const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void computeMeasuredDepths();
|
void computeMeasuredDepths();
|
||||||
|
|||||||
Reference in new issue
Block a user