mirror of
https://github.com/OPM/ResInsight.git
synced 2025-01-23 23:13:39 -06:00
This commit is contained in:
parent
3d2fca1866
commit
b9767a35a4
@ -71,7 +71,7 @@ double defaultPorosity()
|
|||||||
|
|
||||||
double defaultPermeability()
|
double defaultPermeability()
|
||||||
{
|
{
|
||||||
return 1.0e-5;
|
return 1.0e-4;
|
||||||
}
|
}
|
||||||
|
|
||||||
double zeroReplacementForLogarithmicPlot()
|
double zeroReplacementForLogarithmicPlot()
|
||||||
|
@ -110,6 +110,16 @@ bool RifStimPlanModelGeologicalFrkExporter::writeToFile( RimStimPlanModel* stimP
|
|||||||
std::vector<double> stressGradients = stimPlanModel->calculator()->calculateStressGradient();
|
std::vector<double> stressGradients = stimPlanModel->calculator()->calculateStressGradient();
|
||||||
fixupStressGradients( stressGradients, MIN_STRESS_GRADIENT, MAX_STRESS_GRADIENT, DEFAULT_STRESS_GRADIENT );
|
fixupStressGradients( stressGradients, MIN_STRESS_GRADIENT, MAX_STRESS_GRADIENT, DEFAULT_STRESS_GRADIENT );
|
||||||
|
|
||||||
|
// Make sure porosity and permeability is valid
|
||||||
|
std::vector<double> porosity = stimPlanModel->calculator()->calculatePorosity();
|
||||||
|
fixupLowerBoundary( porosity, stimPlanModel->defaultPorosity(), "porosity" );
|
||||||
|
|
||||||
|
std::vector<double> horizontalPermeability = stimPlanModel->calculator()->calculateHorizontalPermeability();
|
||||||
|
fixupLowerBoundary( horizontalPermeability, stimPlanModel->defaultPermeability(), "horizontal permeability" );
|
||||||
|
|
||||||
|
std::vector<double> verticalPermeability = stimPlanModel->calculator()->calculateVerticalPermeability();
|
||||||
|
fixupLowerBoundary( verticalPermeability, stimPlanModel->defaultPermeability() * 0.1, "vertical permeability" );
|
||||||
|
|
||||||
std::map<QString, std::vector<double>> values;
|
std::map<QString, std::vector<double>> values;
|
||||||
values["dpthlyr"] = tvd;
|
values["dpthlyr"] = tvd;
|
||||||
values["strs"] = stimPlanModel->calculator()->calculateStress();
|
values["strs"] = stimPlanModel->calculator()->calculateStress();
|
||||||
@ -122,9 +132,9 @@ bool RifStimPlanModelGeologicalFrkExporter::writeToFile( RimStimPlanModel* stimP
|
|||||||
values["pembed"] = stimPlanModel->calculator()->calculateProppandEmbedment();
|
values["pembed"] = stimPlanModel->calculator()->calculateProppandEmbedment();
|
||||||
values["zoneResPres"] = stimPlanModel->calculator()->calculateReservoirPressure();
|
values["zoneResPres"] = stimPlanModel->calculator()->calculateReservoirPressure();
|
||||||
values["zoneWaterSat"] = stimPlanModel->calculator()->calculateImmobileFluidSaturation();
|
values["zoneWaterSat"] = stimPlanModel->calculator()->calculateImmobileFluidSaturation();
|
||||||
values["zonePorosity"] = stimPlanModel->calculator()->calculatePorosity();
|
values["zonePorosity"] = porosity;
|
||||||
values["zoneHorizPerm"] = stimPlanModel->calculator()->calculateHorizontalPermeability();
|
values["zoneHorizPerm"] = horizontalPermeability;
|
||||||
values["zoneVertPerm"] = stimPlanModel->calculator()->calculateVerticalPermeability();
|
values["zoneVertPerm"] = verticalPermeability;
|
||||||
values["zoneTemp"] = stimPlanModel->calculator()->calculateTemperature();
|
values["zoneTemp"] = stimPlanModel->calculator()->calculateTemperature();
|
||||||
values["zoneRelPerm"] = stimPlanModel->calculator()->calculateRelativePermeabilityFactor();
|
values["zoneRelPerm"] = stimPlanModel->calculator()->calculateRelativePermeabilityFactor();
|
||||||
values["zonePoroElas"] = stimPlanModel->calculator()->calculatePoroElasticConstant();
|
values["zonePoroElas"] = stimPlanModel->calculator()->calculatePoroElasticConstant();
|
||||||
@ -295,6 +305,27 @@ void RifStimPlanModelGeologicalFrkExporter::fixupStressGradients( std::vector<do
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
///
|
||||||
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
void RifStimPlanModelGeologicalFrkExporter::fixupLowerBoundary( std::vector<double>& values,
|
||||||
|
double minValue,
|
||||||
|
const QString& property )
|
||||||
|
{
|
||||||
|
for ( double& value : values )
|
||||||
|
{
|
||||||
|
if ( value < minValue )
|
||||||
|
{
|
||||||
|
RiaLogging::warning(
|
||||||
|
QString( "Found %1 outside valid lower boundary (%2). Replacing %3 with default value: %2." )
|
||||||
|
.arg( property )
|
||||||
|
.arg( minValue )
|
||||||
|
.arg( value ) );
|
||||||
|
value = minValue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
///
|
///
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
@ -54,7 +54,7 @@ private:
|
|||||||
double minStressGradient,
|
double minStressGradient,
|
||||||
double maxStressGradient,
|
double maxStressGradient,
|
||||||
double defaultStressGradient );
|
double defaultStressGradient );
|
||||||
|
static void fixupLowerBoundary( std::vector<double>& values, double minValue, const QString& property );
|
||||||
static std::pair<std::vector<double>, std::vector<double>> createDepthRanges( const std::vector<double>& tvd );
|
static std::pair<std::vector<double>, std::vector<double>> createDepthRanges( const std::vector<double>& tvd );
|
||||||
|
|
||||||
static bool warnOnInvalidData( const QString& label, const std::vector<double>& values );
|
static bool warnOnInvalidData( const QString& label, const std::vector<double>& values );
|
||||||
|
Loading…
Reference in New Issue
Block a user