mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#3712 Non-Darcy Perforations : Adjust computation of 'kh'
This commit is contained in:
@@ -131,7 +131,7 @@ std::vector<RigCompletionData>
|
|||||||
{
|
{
|
||||||
// No change in transmissibility for main bore
|
// No change in transmissibility for main bore
|
||||||
auto transmissibilityAndPermeability =
|
auto transmissibilityAndPermeability =
|
||||||
RicWellPathExportCompletionDataFeatureImpl::calculateTransmissibilityAndPermeability(
|
RicWellPathExportCompletionDataFeatureImpl::calculateTransmissibilityAndKh(
|
||||||
settings.caseToApply,
|
settings.caseToApply,
|
||||||
wellPath,
|
wellPath,
|
||||||
wellBorePart.lengthsInCell,
|
wellBorePart.lengthsInCell,
|
||||||
@@ -146,7 +146,7 @@ std::vector<RigCompletionData>
|
|||||||
{
|
{
|
||||||
// Adjust transmissibility for fishbone laterals
|
// Adjust transmissibility for fishbone laterals
|
||||||
auto transmissibilityAndPermeability =
|
auto transmissibilityAndPermeability =
|
||||||
RicWellPathExportCompletionDataFeatureImpl::calculateTransmissibilityAndPermeability(
|
RicWellPathExportCompletionDataFeatureImpl::calculateTransmissibilityAndKh(
|
||||||
settings.caseToApply,
|
settings.caseToApply,
|
||||||
wellPath,
|
wellPath,
|
||||||
wellBorePart.lengthsInCell,
|
wellBorePart.lengthsInCell,
|
||||||
|
|||||||
@@ -1658,46 +1658,39 @@ std::vector<RigCompletionData> RicWellPathExportCompletionDataFeatureImpl::gener
|
|||||||
const RimNonDarcyPerforationParameters* nonDarcyParameters =
|
const RimNonDarcyPerforationParameters* nonDarcyParameters =
|
||||||
wellPath->perforationIntervalCollection()->nonDarcyParameters();
|
wellPath->perforationIntervalCollection()->nonDarcyParameters();
|
||||||
|
|
||||||
double transmissibility = 0.0;
|
double transmissibility = 0.0;
|
||||||
double effectivePermeability = 0.0;
|
double kh = RigCompletionData::defaultValue();
|
||||||
|
double dFactor = RigCompletionData::defaultValue();
|
||||||
|
|
||||||
{
|
{
|
||||||
auto transmissibilityAndPermeability =
|
auto transmissibilityAndKh = calculateTransmissibilityAndKh(settings.caseToApply,
|
||||||
calculateTransmissibilityAndPermeability(settings.caseToApply,
|
wellPath,
|
||||||
wellPath,
|
cell.intersectionLengthsInCellCS,
|
||||||
cell.intersectionLengthsInCellCS,
|
interval->skinFactor(),
|
||||||
interval->skinFactor(),
|
interval->diameter(unitSystem) / 2,
|
||||||
interval->diameter(unitSystem) / 2,
|
cell.globCellIndex,
|
||||||
cell.globCellIndex,
|
settings.useLateralNTG);
|
||||||
settings.useLateralNTG);
|
|
||||||
|
|
||||||
transmissibility = transmissibilityAndPermeability.first;
|
transmissibility = transmissibilityAndKh.first;
|
||||||
|
|
||||||
if (nonDarcyParameters->nonDarcyFlowType() != RimNonDarcyPerforationParameters::NON_DARCY_NONE)
|
if (nonDarcyParameters->nonDarcyFlowType() == RimNonDarcyPerforationParameters::NON_DARCY_USER_DEFINED)
|
||||||
{
|
{
|
||||||
effectivePermeability =
|
kh = transmissibilityAndKh.second;
|
||||||
transmissibilityAndPermeability.second * nonDarcyParameters->gridPermeabilityScalingFactor();
|
dFactor = nonDarcyParameters->userDefinedDFactor();
|
||||||
}
|
}
|
||||||
}
|
else if (nonDarcyParameters->nonDarcyFlowType() == RimNonDarcyPerforationParameters::NON_DARCY_COMPUTED)
|
||||||
|
{
|
||||||
|
kh = transmissibilityAndKh.second;
|
||||||
|
|
||||||
double dFactor = RigCompletionData::defaultValue();
|
const double effectivePermeability =
|
||||||
double kh = RigCompletionData::defaultValue();
|
kh * nonDarcyParameters->gridPermeabilityScalingFactor() / cell.intersectionLengthsInCellCS.length();
|
||||||
|
|
||||||
if (nonDarcyParameters->nonDarcyFlowType() == RimNonDarcyPerforationParameters::NON_DARCY_USER_DEFINED)
|
dFactor = calculateDFactor(settings.caseToApply,
|
||||||
{
|
cell.intersectionLengthsInCellCS,
|
||||||
dFactor = nonDarcyParameters->userDefinedDFactor();
|
cell.globCellIndex,
|
||||||
}
|
wellPath->perforationIntervalCollection()->nonDarcyParameters(),
|
||||||
else if (nonDarcyParameters->nonDarcyFlowType() == RimNonDarcyPerforationParameters::NON_DARCY_COMPUTED)
|
effectivePermeability);
|
||||||
{
|
}
|
||||||
dFactor = calculateDFactor(settings.caseToApply,
|
|
||||||
cell.intersectionLengthsInCellCS,
|
|
||||||
cell.globCellIndex,
|
|
||||||
wellPath->perforationIntervalCollection()->nonDarcyParameters(),
|
|
||||||
effectivePermeability);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (nonDarcyParameters->nonDarcyFlowType() != RimNonDarcyPerforationParameters::NON_DARCY_NONE)
|
|
||||||
{
|
|
||||||
kh = effectivePermeability * cell.intersectionLengthsInCellCS.length();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
completion.setTransAndWPImultBackgroundDataFromPerforation(
|
completion.setTransAndWPImultBackgroundDataFromPerforation(
|
||||||
@@ -2307,15 +2300,15 @@ CellDirection RicWellPathExportCompletionDataFeatureImpl::calculateCellMainDirec
|
|||||||
///
|
///
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
std::pair<double, double>
|
std::pair<double, double>
|
||||||
RicWellPathExportCompletionDataFeatureImpl::calculateTransmissibilityAndPermeability(RimEclipseCase* eclipseCase,
|
RicWellPathExportCompletionDataFeatureImpl::calculateTransmissibilityAndKh(RimEclipseCase* eclipseCase,
|
||||||
const RimWellPath* wellPath,
|
const RimWellPath* wellPath,
|
||||||
const cvf::Vec3d& internalCellLengths,
|
const cvf::Vec3d& internalCellLengths,
|
||||||
double skinFactor,
|
double skinFactor,
|
||||||
double wellRadius,
|
double wellRadius,
|
||||||
size_t globalCellIndex,
|
size_t globalCellIndex,
|
||||||
bool useLateralNTG,
|
bool useLateralNTG,
|
||||||
size_t volumeScaleConstant,
|
size_t volumeScaleConstant,
|
||||||
CellDirection directionForVolumeScaling)
|
CellDirection directionForVolumeScaling)
|
||||||
{
|
{
|
||||||
RigEclipseCaseData* eclipseCaseData = eclipseCase->eclipseCaseData();
|
RigEclipseCaseData* eclipseCaseData = eclipseCase->eclipseCaseData();
|
||||||
|
|
||||||
@@ -2367,7 +2360,7 @@ std::pair<double, double>
|
|||||||
double permy = permyAccessObject->cellScalarGlobIdx(globalCellIndex);
|
double permy = permyAccessObject->cellScalarGlobIdx(globalCellIndex);
|
||||||
double permz = permzAccessObject->cellScalarGlobIdx(globalCellIndex);
|
double permz = permzAccessObject->cellScalarGlobIdx(globalCellIndex);
|
||||||
|
|
||||||
const double totalPermeabilityForCell = RigTransmissibilityEquations::totalPermeability(permx, permy, permz);
|
const double totalKh = RigTransmissibilityEquations::totalPermeability(permx, permy, permz, internalCellLengths, latNtg, ntg);
|
||||||
|
|
||||||
double darcy = RiaEclipseUnitTools::darcysConstant(wellPath->unitSystem());
|
double darcy = RiaEclipseUnitTools::darcysConstant(wellPath->unitSystem());
|
||||||
|
|
||||||
@@ -2387,7 +2380,7 @@ std::pair<double, double>
|
|||||||
|
|
||||||
const double totalConnectionFactor = RigTransmissibilityEquations::totalConnectionFactor(transx, transy, transz);
|
const double totalConnectionFactor = RigTransmissibilityEquations::totalConnectionFactor(transx, transy, transz);
|
||||||
|
|
||||||
return std::make_pair(totalConnectionFactor, totalPermeabilityForCell);
|
return std::make_pair(totalConnectionFactor, totalKh);
|
||||||
}
|
}
|
||||||
|
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
|||||||
@@ -83,7 +83,7 @@ public:
|
|||||||
const cvf::Vec3d& lengthsInCell);
|
const cvf::Vec3d& lengthsInCell);
|
||||||
|
|
||||||
static std::pair<double, double>
|
static std::pair<double, double>
|
||||||
calculateTransmissibilityAndPermeability(RimEclipseCase* eclipseCase,
|
calculateTransmissibilityAndKh(RimEclipseCase* eclipseCase,
|
||||||
const RimWellPath* wellPath,
|
const RimWellPath* wellPath,
|
||||||
const cvf::Vec3d& internalCellLengths,
|
const cvf::Vec3d& internalCellLengths,
|
||||||
double skinFactor,
|
double skinFactor,
|
||||||
|
|||||||
@@ -18,9 +18,6 @@
|
|||||||
|
|
||||||
#include "RigTransmissibilityEquations.h"
|
#include "RigTransmissibilityEquations.h"
|
||||||
|
|
||||||
#include "cvfBase.h"
|
|
||||||
#include "cvfMath.h"
|
|
||||||
|
|
||||||
#include <cmath>
|
#include <cmath>
|
||||||
#include <limits>
|
#include <limits>
|
||||||
|
|
||||||
@@ -60,19 +57,26 @@ double RigTransmissibilityEquations::totalConnectionFactor(double transX, double
|
|||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
///
|
///
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
double RigTransmissibilityEquations::totalPermeability(const double permx, const double permy, const double permz)
|
double RigTransmissibilityEquations::totalPermeability(double cellPermX,
|
||||||
|
double cellPermY,
|
||||||
|
double cellPermZ,
|
||||||
|
const cvf::Vec3d& internalCellLengths,
|
||||||
|
double lateralNtg,
|
||||||
|
double ntg)
|
||||||
{
|
{
|
||||||
const double kx = cvf::Math::sqrt(permy * permz);
|
// Compute kh for each local grid cell axis
|
||||||
const double ky = cvf::Math::sqrt(permx * permz);
|
// Use permeability values for the two other axis
|
||||||
const double kz = cvf::Math::sqrt(permy * permx);
|
double khx = sqrt(cellPermY * cellPermZ) * internalCellLengths.x() * lateralNtg;
|
||||||
|
double khy = sqrt(cellPermX * cellPermZ) * internalCellLengths.y() * lateralNtg;
|
||||||
|
double khz = sqrt(cellPermX * cellPermY) * internalCellLengths.z() * ntg;
|
||||||
|
|
||||||
const double totalPerm = cvf::Math::sqrt(kx * kx + ky * ky + kz * kz);
|
const double totalKh = cvf::Math::sqrt(khx * khx + khy * khy + khz * khz);
|
||||||
|
|
||||||
return totalPerm;
|
return totalKh;
|
||||||
}
|
}
|
||||||
|
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
///
|
///
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
double RigTransmissibilityEquations::permeability(const double conductivity, const double width)
|
double RigTransmissibilityEquations::permeability(const double conductivity, const double width)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -18,6 +18,10 @@
|
|||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
#include "cvfBase.h"
|
||||||
|
#include "cvfMath.h"
|
||||||
|
#include "cvfVector3.h"
|
||||||
|
|
||||||
class RigTransmissibilityEquations
|
class RigTransmissibilityEquations
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
@@ -34,7 +38,12 @@ public:
|
|||||||
|
|
||||||
static double totalConnectionFactor(double transX, double transY, double transZ);
|
static double totalConnectionFactor(double transX, double transY, double transZ);
|
||||||
|
|
||||||
static double totalPermeability(const double permx, const double permy, const double permz);
|
static double totalPermeability(double cellPermX,
|
||||||
|
double cellPermY,
|
||||||
|
double cellPermZ,
|
||||||
|
const cvf::Vec3d& internalCellLengths,
|
||||||
|
double lateralNtg,
|
||||||
|
double ntg);
|
||||||
|
|
||||||
static double permeability(const double conductivity, const double width);
|
static double permeability(const double conductivity, const double width);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user