#8019 StimPlan model: Apply default poro and perm as minimum values (#8023)

This commit is contained in:
Kristian Bendiksen 2021-09-20 12:30:01 +02:00 committed by GitHub
parent 3d2fca1866
commit b9767a35a4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 36 additions and 5 deletions

View File

@ -71,7 +71,7 @@ double defaultPorosity()
double defaultPermeability()
{
return 1.0e-5;
return 1.0e-4;
}
double zeroReplacementForLogarithmicPlot()

View File

@ -110,6 +110,16 @@ bool RifStimPlanModelGeologicalFrkExporter::writeToFile( RimStimPlanModel* stimP
std::vector<double> stressGradients = stimPlanModel->calculator()->calculateStressGradient();
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;
values["dpthlyr"] = tvd;
values["strs"] = stimPlanModel->calculator()->calculateStress();
@ -122,9 +132,9 @@ bool RifStimPlanModelGeologicalFrkExporter::writeToFile( RimStimPlanModel* stimP
values["pembed"] = stimPlanModel->calculator()->calculateProppandEmbedment();
values["zoneResPres"] = stimPlanModel->calculator()->calculateReservoirPressure();
values["zoneWaterSat"] = stimPlanModel->calculator()->calculateImmobileFluidSaturation();
values["zonePorosity"] = stimPlanModel->calculator()->calculatePorosity();
values["zoneHorizPerm"] = stimPlanModel->calculator()->calculateHorizontalPermeability();
values["zoneVertPerm"] = stimPlanModel->calculator()->calculateVerticalPermeability();
values["zonePorosity"] = porosity;
values["zoneHorizPerm"] = horizontalPermeability;
values["zoneVertPerm"] = verticalPermeability;
values["zoneTemp"] = stimPlanModel->calculator()->calculateTemperature();
values["zoneRelPerm"] = stimPlanModel->calculator()->calculateRelativePermeabilityFactor();
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;
}
}
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------

View File

@ -54,7 +54,7 @@ private:
double minStressGradient,
double maxStressGradient,
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 bool warnOnInvalidData( const QString& label, const std::vector<double>& values );