Compute entalpy for thermal boundary

This commit is contained in:
Tor Harald Sandve 2024-01-18 16:04:32 +01:00
parent ff8372bc40
commit 5c1bbd304b
2 changed files with 8 additions and 1 deletions

View File

@ -170,6 +170,10 @@ public:
const auto& rho = FluidSystem::density(fluidState, phaseIdx, regionIdx);
fluidState.setDensity(phaseIdx, rho);
if (enableEnergy) {
const auto& h = FluidSystem::enthalpy(fluidState, phaseIdx, regionIdx);
fluidState.setEnthalpy(phaseIdx, h);
}
}
// set the salt concentration

View File

@ -1597,7 +1597,10 @@ public:
const auto& rho = FluidSystem::density(fluidState, phaseIdx, pvtRegionIdx);
fluidState.setDensity(phaseIdx, rho);
if (enableEnergy) {
const auto& h = FluidSystem::enthalpy(fluidState, phaseIdx, pvtRegionIdx);
fluidState.setEnthalpy(phaseIdx, h);
}
}
fluidState.checkDefined();
return fluidState;