Convert ALQ output to units used in the deck

This commit is contained in:
Svenn Tveit 2024-11-20 09:39:49 +01:00
parent 48f9e90248
commit f2e42b96ca

View File

@ -1041,17 +1041,19 @@ namespace Opm
deferred_logger); deferred_logger);
auto [max_alq, success] = glift->wellTestALQ(); auto [max_alq, success] = glift->wellTestALQ();
std::string msg; std::string msg;
const auto& unit_system = schedule.getUnits();
if (success) { if (success) {
well_state.setALQ(well_name, max_alq); well_state.setALQ(well_name, max_alq);
msg = fmt::format( msg = fmt::format(
"GLIFT WTEST: Well {} : Setting ALQ to optimized value = {}", "GLIFT WTEST: Well {} : Setting ALQ to optimized value = {}",
well_name, max_alq); well_name, unit_system.from_si(UnitSystem::measure::gas_surface_rate, max_alq));
} }
else { else {
if (!gl_well.use_glo()) { if (!gl_well.use_glo()) {
msg = fmt::format( msg = fmt::format(
"GLIFT WTEST: Well {} : Setting ALQ to WLIFTOPT item 3 = {}", "GLIFT WTEST: Well {} : Gas lift optimization deactivated. Setting ALQ to WLIFTOPT item 3 = {}",
well_name, well_state.getALQ(well_name)); well_name,
unit_system.from_si(UnitSystem::measure::gas_surface_rate, well_state.getALQ(well_name)));
} }
else { else {