2015-09-02 05:34:12 -05:00
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
//
|
|
|
|
// Copyright (C) 2015- Statoil ASA
|
|
|
|
// Copyright (C) 2015- Ceetron Solutions AS
|
2019-09-06 03:40:57 -05:00
|
|
|
//
|
2015-09-02 05:34:12 -05:00
|
|
|
// 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.
|
2019-09-06 03:40:57 -05:00
|
|
|
//
|
2015-09-02 05:34:12 -05:00
|
|
|
// 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.
|
2019-09-06 03:40:57 -05:00
|
|
|
//
|
|
|
|
// See the GNU General Public License at <http://www.gnu.org/licenses/gpl.html>
|
2015-09-02 05:34:12 -05:00
|
|
|
// for more details.
|
|
|
|
//
|
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
2019-11-06 03:07:56 -06:00
|
|
|
#include "RigWbsParameter.h"
|
2015-11-04 09:22:53 -06:00
|
|
|
#include "RimWellLogCurve.h"
|
2015-09-18 12:42:54 -05:00
|
|
|
|
2015-09-02 05:34:12 -05:00
|
|
|
#include "cafPdmChildField.h"
|
2019-09-06 03:40:57 -05:00
|
|
|
#include "cafPdmPtrField.h"
|
2015-09-02 05:34:12 -05:00
|
|
|
|
2019-02-11 07:23:05 -06:00
|
|
|
class RigFemResultAddress;
|
2018-09-03 04:24:35 -05:00
|
|
|
class RigGeoMechWellLogExtractor;
|
2017-12-07 07:51:58 -06:00
|
|
|
class RigWellPath;
|
2015-09-18 12:42:54 -05:00
|
|
|
class RimCase;
|
2015-09-02 05:34:12 -05:00
|
|
|
class RimEclipseResultDefinition;
|
|
|
|
class RimGeoMechResultDefinition;
|
2018-01-09 03:11:28 -06:00
|
|
|
class Rim3dView;
|
2015-12-09 04:32:46 -06:00
|
|
|
class RimWellPath;
|
2015-09-02 05:34:12 -05:00
|
|
|
|
|
|
|
//==================================================================================================
|
2019-09-06 03:40:57 -05:00
|
|
|
///
|
|
|
|
///
|
2015-09-02 05:34:12 -05:00
|
|
|
//==================================================================================================
|
2015-11-04 09:19:38 -06:00
|
|
|
class RimWellLogExtractionCurve : public RimWellLogCurve
|
2015-09-02 05:34:12 -05:00
|
|
|
{
|
|
|
|
CAF_PDM_HEADER_INIT;
|
2019-09-06 03:40:57 -05:00
|
|
|
|
2015-09-02 05:34:12 -05:00
|
|
|
public:
|
|
|
|
RimWellLogExtractionCurve();
|
2018-10-18 12:45:57 -05:00
|
|
|
~RimWellLogExtractionCurve() override;
|
2017-04-25 05:31:49 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
enum TrajectoryType
|
|
|
|
{
|
|
|
|
WELL_PATH,
|
|
|
|
SIMULATION_WELL
|
|
|
|
};
|
2016-12-17 09:30:38 -06:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void setWellPath( RimWellPath* wellPath );
|
|
|
|
RimWellPath* wellPath() const;
|
2017-04-25 09:12:22 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void setFromSimulationWellName( const QString& simWellName, int branchIndex, bool branchDetection );
|
2016-12-17 09:30:38 -06:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void setCase( RimCase* rimCase );
|
|
|
|
RimCase* rimCase() const;
|
2015-09-02 05:34:12 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void setPropertiesFromView( Rim3dView* view );
|
2015-10-15 07:37:57 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
TrajectoryType trajectoryType() const;
|
|
|
|
QString wellName() const override;
|
2020-01-28 03:09:23 -06:00
|
|
|
QString wellLogChannelUiName() const override;
|
2019-09-06 03:40:57 -05:00
|
|
|
QString wellLogChannelName() const override;
|
2020-01-29 05:52:07 -06:00
|
|
|
QString wellLogChannelUnits() const override;
|
2019-09-06 03:40:57 -05:00
|
|
|
QString wellDate() const override;
|
|
|
|
int branchIndex() const;
|
|
|
|
bool branchDetection() const;
|
2016-09-16 05:46:25 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
bool isEclipseCurve() const;
|
|
|
|
QString caseName() const;
|
2017-10-04 07:36:33 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
int currentTimeStep() const;
|
|
|
|
void setCurrentTimeStep( int timeStep );
|
2017-04-26 09:59:52 -05:00
|
|
|
|
2020-06-05 08:58:25 -05:00
|
|
|
void setEclipseResultVariable( const QString& resVarname );
|
|
|
|
QString eclipseResultVariable() const;
|
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void setGeoMechResultAddress( const RigFemResultAddress& resAddr );
|
2018-07-10 05:44:58 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void setTrajectoryType( TrajectoryType trajectoryType );
|
|
|
|
void setWellName( QString wellName );
|
|
|
|
void setBranchDetection( bool branchDetection );
|
|
|
|
void setBranchIndex( int index );
|
2018-10-18 12:45:57 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
static void findAndLoadWbsParametersFromLasFiles( const RimWellPath* wellPath,
|
|
|
|
RigGeoMechWellLogExtractor* geomExtractor );
|
|
|
|
|
2019-10-03 07:41:37 -05:00
|
|
|
void setAutoNameComponents( bool addCaseName, bool addProperty, bool addWellname, bool addTimeStep, bool addDate );
|
2020-07-02 06:06:31 -05:00
|
|
|
RiaDefines::PhaseType phaseType() const override;
|
2019-10-03 07:41:37 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
protected:
|
2020-08-31 07:31:35 -05:00
|
|
|
QString createCurveAutoName() override;
|
|
|
|
void onLoadDataAndUpdate( bool updateParentPlot ) override;
|
|
|
|
void onCaseSettingsChanged( const caf::SignalEmitter* emitter );
|
|
|
|
void connectCaseSignals( RimCase* rimCase );
|
|
|
|
|
2019-10-03 07:16:56 -05:00
|
|
|
virtual void performDataExtraction( bool* isUsingPseudoLength );
|
2019-10-03 07:57:46 -05:00
|
|
|
void extractData( bool* isUsingPseudoLength, bool performDataSmoothing = false, double smoothingThreshold = -1.0 );
|
2019-09-06 03:40:57 -05:00
|
|
|
|
2020-02-12 04:43:15 -06:00
|
|
|
void fieldChangedByUi( const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue ) override;
|
2019-09-06 03:40:57 -05:00
|
|
|
void defineUiOrdering( QString uiConfigName, caf::PdmUiOrdering& uiOrdering ) override;
|
|
|
|
void defineUiTreeOrdering( caf::PdmUiTreeOrdering& uiTreeOrdering, QString uiConfigName = "" ) override;
|
|
|
|
QList<caf::PdmOptionItemInfo> calculateValueOptions( const caf::PdmFieldHandle* fieldNeedingOptions,
|
|
|
|
bool* useOptionsOnly ) override;
|
|
|
|
void initAfterRead() override;
|
2015-09-03 13:54:15 -05:00
|
|
|
|
2019-10-03 07:57:46 -05:00
|
|
|
static QString dataSourceGroupKeyword();
|
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void setLogScaleFromSelectedResult();
|
|
|
|
void clampTimestep();
|
|
|
|
void clampBranchIndex();
|
|
|
|
std::set<QString> sortedSimWellNames();
|
|
|
|
void clearGeneratedSimWellPaths();
|
2015-12-09 04:32:46 -06:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
caf::PdmPtrField<RimCase*> m_case;
|
|
|
|
caf::PdmField<caf::AppEnum<TrajectoryType>> m_trajectoryType;
|
|
|
|
caf::PdmPtrField<RimWellPath*> m_wellPath;
|
|
|
|
caf::PdmField<QString> m_simWellName;
|
|
|
|
caf::PdmField<int> m_branchIndex;
|
|
|
|
caf::PdmField<bool> m_branchDetection;
|
2017-10-05 06:42:40 -05:00
|
|
|
|
2015-09-02 05:34:12 -05:00
|
|
|
caf::PdmChildField<RimEclipseResultDefinition*> m_eclipseResultDefinition;
|
|
|
|
caf::PdmChildField<RimGeoMechResultDefinition*> m_geomResultDefinition;
|
|
|
|
caf::PdmField<int> m_timeStep;
|
2015-09-17 11:42:35 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
caf::PdmField<bool> m_addCaseNameToCurveName;
|
|
|
|
caf::PdmField<bool> m_addPropertyToCurveName;
|
|
|
|
caf::PdmField<bool> m_addWellNameToCurveName;
|
|
|
|
caf::PdmField<bool> m_addTimestepToCurveName;
|
|
|
|
caf::PdmField<bool> m_addDateToCurveName;
|
2017-04-25 05:31:49 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
std::vector<const RigWellPath*> m_wellPathsWithExtractors;
|
2015-09-02 05:34:12 -05:00
|
|
|
};
|