mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#1589 Setting includeFractures to false and read-only when using setting "Use Default Connection Factors and WPImult (excludes fractures)"
This commit is contained in:
parent
6febf1dfbf
commit
50a0dcd499
@ -42,7 +42,7 @@ namespace caf
|
||||
void RicExportCompletionDataSettingsUi::CompdatExportType::setUp()
|
||||
{
|
||||
addItem(RicExportCompletionDataSettingsUi::TRANSMISSIBILITIES, "TRANSMISSIBILITIES", "Calculated Transmissibilities");
|
||||
addItem(RicExportCompletionDataSettingsUi::WPIMULT_AND_DEFAULT_CONNECTION_FACTORS, "WPIMULT_AND_DEFAULT_CONNECTION_FACTORS", "Default Connection Factors and WPIMULT");
|
||||
addItem(RicExportCompletionDataSettingsUi::WPIMULT_AND_DEFAULT_CONNECTION_FACTORS, "WPIMULT_AND_DEFAULT_CONNECTION_FACTORS", "Default Connection Factors and WPIMULT (Fractures Not Supported)");
|
||||
setDefault(RicExportCompletionDataSettingsUi::TRANSMISSIBILITIES);
|
||||
}
|
||||
}
|
||||
@ -156,13 +156,29 @@ void RicExportCompletionDataSettingsUi::defineUiOrdering(QString uiConfigName, c
|
||||
caf::PdmUiGroup* fishboneGroup = uiOrdering.addNewGroup("Export of Fishbone Completions");
|
||||
fishboneGroup->add(&includeFishbones);
|
||||
fishboneGroup->add(&excludeMainBoreForFishbones);
|
||||
if (!includeFishbones) excludeMainBoreForFishbones.uiCapability()->setUiReadOnly(true);
|
||||
else excludeMainBoreForFishbones.uiCapability()->setUiReadOnly(false);
|
||||
|
||||
caf::PdmUiGroup* perfIntervalGroup = uiOrdering.addNewGroup("Export of Perforation Completions");
|
||||
perfIntervalGroup->add(&includePerforations);
|
||||
perfIntervalGroup->add(&timeStep);
|
||||
|
||||
if (!includePerforations) timeStep.uiCapability()->setUiReadOnly(true);
|
||||
else timeStep.uiCapability()->setUiReadOnly(false);
|
||||
|
||||
caf::PdmUiGroup* fractureGroup = uiOrdering.addNewGroup("Export of Fracture Completions");
|
||||
fractureGroup->add(&includeFractures);
|
||||
|
||||
if (compdatExport == WPIMULT_AND_DEFAULT_CONNECTION_FACTORS)
|
||||
{
|
||||
includeFractures = false;
|
||||
includeFractures.uiCapability()->setUiReadOnly(true);
|
||||
}
|
||||
else if (compdatExport == TRANSMISSIBILITIES)
|
||||
{
|
||||
includeFractures = true;
|
||||
includeFractures.uiCapability()->setUiReadOnly(false);
|
||||
}
|
||||
|
||||
}
|
||||
uiOrdering.skipRemainingFields();
|
||||
}
|
||||
|
@ -288,51 +288,51 @@ std::vector<RigCompletionData> RicExportFractureCompletionsImpl::generateCompdat
|
||||
//If fracture has orientation along well, linear inflow along well and radial flow at endpoints
|
||||
|
||||
RigWellPathStimplanIntersector wellFractureIntersector(wellPathGeometry, fracture);
|
||||
const std::map<size_t, RigWellPathStimplanIntersector::WellCellIntersection >& fractureWellCells = wellFractureIntersector.intersections();
|
||||
const std::map<size_t, RigWellPathStimplanIntersector::WellCellIntersection >& fractureWellCells = wellFractureIntersector.intersections();
|
||||
|
||||
for (const auto& fracCellIdxIsectDataPair : fractureWellCells)
|
||||
{
|
||||
size_t fracWellCellIdx = fracCellIdxIsectDataPair.first;
|
||||
|
||||
if(!blockedFractureCellIndices.count(fracWellCellIdx))
|
||||
if (!blockedFractureCellIndices.count(fracWellCellIdx))
|
||||
{
|
||||
RigWellPathStimplanIntersector::WellCellIntersection intersection = fracCellIdxIsectDataPair.second;
|
||||
|
||||
const RigFractureCell& fractureWellCell = fractureGrid->cellFromIndex(fracWellCellIdx);
|
||||
|
||||
double radialTrans = 0.0;
|
||||
if (intersection.endpointCount)
|
||||
{
|
||||
radialTrans = RigFractureTransmissibilityEquations::fractureCellToWellRadialTrans(fractureWellCell.getConductivtyValue(),
|
||||
fractureWellCell.cellSizeX(),
|
||||
fractureWellCell.cellSizeZ(),
|
||||
fracture->wellRadius(caseToApply->eclipseCaseData()->unitsType()),
|
||||
fracTemplate->skinFactor(),
|
||||
cDarcyInCorrectUnit);
|
||||
}
|
||||
double radialTrans = 0.0;
|
||||
if (intersection.endpointCount)
|
||||
{
|
||||
radialTrans = RigFractureTransmissibilityEquations::fractureCellToWellRadialTrans(fractureWellCell.getConductivtyValue(),
|
||||
fractureWellCell.cellSizeX(),
|
||||
fractureWellCell.cellSizeZ(),
|
||||
fracture->wellRadius(caseToApply->eclipseCaseData()->unitsType()),
|
||||
fracTemplate->skinFactor(),
|
||||
cDarcyInCorrectUnit);
|
||||
}
|
||||
|
||||
double linearTrans = 0.0;
|
||||
if (intersection.hlength > 0.0 || intersection.vlength > 0.0 )
|
||||
if (intersection.hlength > 0.0 || intersection.vlength > 0.0)
|
||||
{
|
||||
linearTrans = RigFractureTransmissibilityEquations::fractureCellToWellLinearTrans(fractureWellCell.getConductivtyValue(),
|
||||
fractureWellCell.cellSizeX(),
|
||||
fractureWellCell.cellSizeZ(),
|
||||
intersection.vlength,
|
||||
intersection.hlength ,
|
||||
fracture->perforationEfficiency,
|
||||
intersection.hlength,
|
||||
fracture->perforationEfficiency,
|
||||
fracTemplate->skinFactor(),
|
||||
cDarcyInCorrectUnit);
|
||||
}
|
||||
|
||||
double totalWellTrans = 0.5 * intersection.endpointCount * radialTrans + linearTrans;
|
||||
|
||||
transCondenser.addNeighborTransmissibility( { true, RigTransmissibilityCondenser::CellAddress::WELL, 1 },
|
||||
{ false, RigTransmissibilityCondenser::CellAddress::STIMPLAN, fracWellCellIdx },
|
||||
totalWellTrans);
|
||||
transCondenser.addNeighborTransmissibility({ true, RigTransmissibilityCondenser::CellAddress::WELL, 1 },
|
||||
{ false, RigTransmissibilityCondenser::CellAddress::STIMPLAN, fracWellCellIdx },
|
||||
totalWellTrans);
|
||||
}
|
||||
else
|
||||
{
|
||||
RiaLogging::warning(QString("Fracture well cell is not located within the settings provided by Fracture Containment.")
|
||||
RiaLogging::warning(QString("Fracture well cell is not located within the settings provided by Fracture Containment.")
|
||||
+ "\n Fracture named: " + fracture->name());
|
||||
}
|
||||
}
|
||||
|
@ -109,8 +109,6 @@ void RicWellPathExportCompletionDataFeature::onActionTriggered(bool isChecked)
|
||||
QString projectFolder = app->currentProjectPath();
|
||||
QString defaultDir = RiaApplication::instance()->lastUsedDialogDirectoryWithFallback("COMPLETIONS", projectFolder);
|
||||
|
||||
//RicExportCompletionDataSettingsUi exportSettings;
|
||||
|
||||
bool onlyWellPathCollectionSelected = noWellPathsSelectedDirectly();
|
||||
RicExportCompletionDataSettingsUi exportSettings(onlyWellPathCollectionSelected);
|
||||
|
||||
@ -436,12 +434,12 @@ RigCompletionData RicWellPathExportCompletionDataFeature::combineEclipseCellComp
|
||||
}
|
||||
|
||||
|
||||
if (settings.compdatExport == RicExportCompletionDataSettingsUi::TRANSMISSIBILITIES)
|
||||
if (completions[0].completionType() == RigCompletionData::FRACTURE
|
||||
|| settings.compdatExport == RicExportCompletionDataSettingsUi::TRANSMISSIBILITIES)
|
||||
{
|
||||
resultCompletion.setCombinedValuesExplicitTrans(totalTrans, completionType);
|
||||
}
|
||||
|
||||
if (settings.compdatExport == RicExportCompletionDataSettingsUi::WPIMULT_AND_DEFAULT_CONNECTION_FACTORS)
|
||||
else if (settings.compdatExport == RicExportCompletionDataSettingsUi::WPIMULT_AND_DEFAULT_CONNECTION_FACTORS)
|
||||
{
|
||||
//calculate trans for main bore - but as Eclipse will do it!
|
||||
double transmissibilityEclipseCalculation = RicWellPathExportCompletionDataFeature::calculateTransmissibilityAsEclipseDoes(settings.caseToApply(),
|
||||
@ -616,7 +614,7 @@ void RicWellPathExportCompletionDataFeature::generateWpimultTable(RifEclipseData
|
||||
|
||||
for (auto& completion : completionData)
|
||||
{
|
||||
if (completion.wpimult() == 0.0)
|
||||
if (completion.wpimult() == 0.0 || completion.isDefaultValue(completion.wpimult()))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user