2017-01-02 14:13:34 +01:00
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
//
|
|
|
|
|
// Copyright (C) 2017 Statoil ASA
|
|
|
|
|
//
|
|
|
|
|
// ResInsight is free software: you can redistribute it and/or modify
|
|
|
|
|
// it under the terms of the GNU General Public License as published by
|
|
|
|
|
// the Free Software Foundation, either version 3 of the License, or
|
|
|
|
|
// (at your option) any later version.
|
|
|
|
|
//
|
|
|
|
|
// ResInsight is distributed in the hope that it will be useful, but WITHOUT ANY
|
|
|
|
|
// WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
|
|
|
// FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
|
//
|
|
|
|
|
// See the GNU General Public License at <http://www.gnu.org/licenses/gpl.html>
|
|
|
|
|
// for more details.
|
|
|
|
|
//
|
|
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
2017-06-14 07:25:34 +02:00
|
|
|
#include "RiaEclipseUnitTools.h"
|
|
|
|
|
|
2017-06-09 13:05:59 +02:00
|
|
|
#include "Rim3dPropertiesInterface.h"
|
2017-02-22 13:24:07 +01:00
|
|
|
#include "RimCheckableNamedObject.h"
|
2017-01-10 13:37:50 +01:00
|
|
|
|
2017-01-04 08:10:02 +01:00
|
|
|
#include "cvfBase.h"
|
|
|
|
|
#include "cvfObject.h"
|
2017-01-02 14:13:34 +01:00
|
|
|
#include "cvfVector3.h"
|
2017-01-12 10:52:47 +01:00
|
|
|
#include "cvfMatrix4.h"
|
2017-02-15 11:29:44 +01:00
|
|
|
#include "cvfPlane.h"
|
2017-01-02 14:13:34 +01:00
|
|
|
|
2017-03-02 10:08:45 +01:00
|
|
|
#include "cafAppEnum.h"
|
2017-02-15 11:29:44 +01:00
|
|
|
#include "cafPdmChildField.h"
|
|
|
|
|
#include "cafPdmFieldCvfVec3d.h"
|
2017-01-19 10:43:23 +01:00
|
|
|
#include "cafPdmProxyValueField.h"
|
|
|
|
|
#include "cafPdmPtrField.h"
|
2017-02-07 09:09:00 +01:00
|
|
|
|
2017-01-19 10:43:23 +01:00
|
|
|
|
2017-02-06 13:22:18 +01:00
|
|
|
class RimEclipseCase;
|
2017-01-19 10:43:23 +01:00
|
|
|
class RimEllipseFractureTemplate;
|
2017-01-19 07:28:04 +01:00
|
|
|
class RivWellFracturePartMgr;
|
2017-02-22 13:24:07 +01:00
|
|
|
class RimFractureTemplate;
|
2017-05-16 10:55:31 +02:00
|
|
|
class RigFracturedEclipseCellExportData;
|
2017-05-16 17:52:57 +02:00
|
|
|
class RigMainGrid;
|
2017-01-04 08:10:02 +01:00
|
|
|
|
2017-01-02 14:13:34 +01:00
|
|
|
//==================================================================================================
|
|
|
|
|
///
|
|
|
|
|
///
|
|
|
|
|
//==================================================================================================
|
2017-06-09 13:05:59 +02:00
|
|
|
class RimFracture : public RimCheckableNamedObject, public Rim3dPropertiesInterface
|
2017-01-02 14:13:34 +01:00
|
|
|
{
|
|
|
|
|
CAF_PDM_HEADER_INIT;
|
|
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
RimFracture(void);
|
|
|
|
|
virtual ~RimFracture(void);
|
|
|
|
|
|
2017-02-17 14:11:47 +01:00
|
|
|
caf::PdmField<double> azimuth;
|
|
|
|
|
caf::PdmField<double> perforationLength;
|
2017-04-18 15:23:26 +02:00
|
|
|
caf::PdmField<double> perforationEfficiency;
|
2017-06-08 09:15:50 +02:00
|
|
|
caf::PdmField<double> wellDiameter;
|
2017-04-18 15:23:26 +02:00
|
|
|
|
2017-03-06 13:32:42 +01:00
|
|
|
caf::PdmField<double> dip;
|
2017-03-29 10:12:01 +02:00
|
|
|
caf::PdmField<double> tilt;
|
2017-02-17 14:11:47 +01:00
|
|
|
|
|
|
|
|
caf::PdmField<int> stimPlanTimeIndexToPlot;
|
2017-02-28 14:28:14 +01:00
|
|
|
caf::PdmField<bool> showPolygonFractureOutline;
|
|
|
|
|
|
2017-03-02 10:08:45 +01:00
|
|
|
|
2017-06-20 14:46:58 +02:00
|
|
|
double wellRadius(RiaEclipseUnitTools::UnitSystem unitSystem) const;
|
2017-05-22 18:11:03 +02:00
|
|
|
cvf::Vec3d anchorPosition() const ;
|
2017-01-19 10:43:23 +01:00
|
|
|
void setAnchorPosition(const cvf::Vec3d& pos);
|
2017-06-20 14:46:58 +02:00
|
|
|
RiaEclipseUnitTools::UnitSystem fractureUnit() const;
|
|
|
|
|
void setFractureUnit(RiaEclipseUnitTools::UnitSystem unitSystem);
|
2017-01-10 10:53:54 +01:00
|
|
|
|
2017-06-20 11:18:19 +02:00
|
|
|
bool isEclipseCellWithinContainment(const RigMainGrid* mainGrid,
|
2017-06-20 16:40:32 +02:00
|
|
|
size_t globalCellIndex) const;
|
2017-06-16 14:13:42 +02:00
|
|
|
size_t findAnchorEclipseCell(const RigMainGrid* mainGrid) const;
|
|
|
|
|
|
2017-06-23 10:16:39 +02:00
|
|
|
cvf::Mat4d transformMatrix() const;
|
2017-01-12 10:52:47 +01:00
|
|
|
|
2017-02-07 09:09:00 +01:00
|
|
|
void setFractureTemplate(RimFractureTemplate* fractureTemplate);
|
2017-06-09 17:21:59 +02:00
|
|
|
RimFractureTemplate* fractureTemplate() const;
|
2017-01-10 15:29:38 +01:00
|
|
|
|
2017-01-19 07:28:04 +01:00
|
|
|
RivWellFracturePartMgr* fracturePartManager();
|
|
|
|
|
|
2017-06-12 12:45:09 +02:00
|
|
|
void clearDisplayGeometryCache();
|
2017-01-11 14:32:15 +01:00
|
|
|
|
2017-06-12 12:45:09 +02:00
|
|
|
void triangleGeometry(std::vector<cvf::uint>* triangleIndices, std::vector<cvf::Vec3f>* vxCoords );
|
2017-01-10 13:37:50 +01:00
|
|
|
|
2017-05-16 17:52:57 +02:00
|
|
|
std::vector<size_t> getPotentiallyFracturedCells(const RigMainGrid* mainGrid);
|
2017-03-20 12:29:09 +01:00
|
|
|
|
2017-01-19 10:43:23 +01:00
|
|
|
virtual void fieldChangedByUi(const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue) override;
|
2017-02-06 11:44:24 +01:00
|
|
|
cvf::Vec3d fracturePosition() const;
|
|
|
|
|
|
2017-06-29 15:06:44 +02:00
|
|
|
virtual void updateAzimuthBasedOnWellAzimuthAngle() = 0;
|
2017-06-29 10:34:20 +02:00
|
|
|
virtual double wellAzimuthAtFracturePosition() const = 0;
|
2017-08-02 11:13:27 +02:00
|
|
|
virtual double fractureMD() const = 0;
|
2017-06-29 15:06:44 +02:00
|
|
|
|
2017-08-14 22:16:03 +02:00
|
|
|
virtual void loadDataAndUpdate() = 0;
|
|
|
|
|
|
2017-01-10 10:53:54 +01:00
|
|
|
protected:
|
2017-01-19 10:43:23 +01:00
|
|
|
virtual QList<caf::PdmOptionItemInfo> calculateValueOptions(const caf::PdmFieldHandle* fieldNeedingOptions, bool * useOptionsOnly) override;
|
|
|
|
|
virtual void defineUiOrdering(QString uiConfigName, caf::PdmUiOrdering& uiOrdering) override;
|
|
|
|
|
virtual void defineEditorAttribute(const caf::PdmFieldHandle* field, QString uiConfigName, caf::PdmUiEditorAttribute * attribute) override;
|
2017-02-23 09:47:30 +01:00
|
|
|
|
2017-01-04 08:10:02 +01:00
|
|
|
private:
|
2017-01-19 10:43:23 +01:00
|
|
|
cvf::Vec3d fracturePositionForUi() const;
|
2017-06-29 10:34:20 +02:00
|
|
|
double wellFractureAzimuthDiff() const;
|
2017-01-19 10:43:23 +01:00
|
|
|
|
2017-06-29 11:28:30 +02:00
|
|
|
QString wellFractureAzimuthDiffText() const;
|
|
|
|
|
QString wellAzimuthAtFracturePositionText() const;
|
|
|
|
|
|
2017-06-09 13:05:59 +02:00
|
|
|
virtual cvf::BoundingBox boundingBoxInDomainCoords() override;
|
2017-01-06 13:13:25 +01:00
|
|
|
|
2017-01-19 13:35:07 +01:00
|
|
|
protected:
|
2017-02-07 11:08:56 +01:00
|
|
|
caf::PdmPtrField<RimFractureTemplate*> m_fractureTemplate;
|
2017-01-19 10:43:23 +01:00
|
|
|
caf::PdmProxyValueField<cvf::Vec3d> m_uiAnchorPosition;
|
2017-06-20 14:46:58 +02:00
|
|
|
caf::PdmField< RiaEclipseUnitTools::UnitSystemType > m_fractureUnit;
|
2017-06-27 14:11:55 +02:00
|
|
|
|
2017-06-29 11:28:30 +02:00
|
|
|
caf::PdmProxyValueField<QString> m_uiWellPathAzimuth;
|
|
|
|
|
caf::PdmProxyValueField<QString> m_uiWellFractureAzimuthDiff;
|
2017-06-27 14:11:55 +02:00
|
|
|
caf::PdmField<QString> m_wellFractureAzimuthAngleWarning;
|
|
|
|
|
|
2017-01-19 10:43:23 +01:00
|
|
|
|
2017-01-19 13:35:07 +01:00
|
|
|
private:
|
|
|
|
|
caf::PdmField<cvf::Vec3d> m_anchorPosition;
|
2017-01-19 10:43:23 +01:00
|
|
|
|
2017-06-09 17:21:59 +02:00
|
|
|
cvf::ref<RivWellFracturePartMgr> m_fracturePartMgr;
|
2017-01-02 14:13:34 +01:00
|
|
|
};
|