Skip to content

Commit 199a4ca

Browse files
Change 'Well depth (or total length if not vertical)' output to 'Well depth' - claim of total length if not vertical is not accurate. NREL#321
1 parent 397e569 commit 199a4ca

File tree

3 files changed

+14
-7
lines changed

3 files changed

+14
-7
lines changed

src/geophires_x/Outputs.py

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -638,6 +638,8 @@ class Outputs:
638638
This class handles all the outputs for the GEOPHIRESv3 model.
639639
"""
640640

641+
VERTICAL_WELL_DEPTH_OUTPUT_NAME = 'Well depth'
642+
641643
def __init__(self, model:Model, output_file:str ='HDR.out'):
642644
model.logger.info(f'Init {__class__!s}: {__name__}')
643645
self.ParameterDict = {}
@@ -860,7 +862,7 @@ def PrintOutputs(self, model: Model):
860862
summary.append(OutputTableItem('Number of injection wells', '{0:10.0f}'.format(model.wellbores.ninj.value)))
861863
summary.append(OutputTableItem('Flowrate per production well', '{0:10.1f}'.format(model.wellbores.prodwellflowrate.value),
862864
model.wellbores.prodwellflowrate.CurrentUnits.value))
863-
summary.append(OutputTableItem('Well depth (or total length, if not vertical)',
865+
summary.append(OutputTableItem(Outputs.VERTICAL_WELL_DEPTH_OUTPUT_NAME,
864866
'{0:10.1f}'.format(model.reserv.depth.value),
865867
model.reserv.depth.CurrentUnits.value))
866868

@@ -926,7 +928,7 @@ def PrintOutputs(self, model: Model):
926928

927929
engineering_parameters.append(OutputTableItem('Number of Production Wells', '{0:10.0f}'.format(model.wellbores.nprod.value)))
928930
engineering_parameters.append(OutputTableItem('Number of Injection Wells', '{0:10.0f}'.format(model.wellbores.ninj.value)))
929-
engineering_parameters.append(OutputTableItem('Well depth (or total length, if not vertical)',
931+
engineering_parameters.append(OutputTableItem(Outputs.VERTICAL_WELL_DEPTH_OUTPUT_NAME,
930932
'{0:10.1f}'.format(model.reserv.depth.value),
931933
model.reserv.depth.CurrentUnits.value))
932934
engineering_parameters.append(OutputTableItem('Water loss rate', '{0:10.1f}'.format(model.reserv.waterloss.value * 100),
@@ -1613,7 +1615,7 @@ def PrintOutputs(self, model: Model):
16131615
f.write(f' Number of production wells: {model.wellbores.nprod.value:10.0f}'+NL)
16141616
f.write(f' Number of injection wells: {model.wellbores.ninj.value:10.0f}'+NL)
16151617
f.write(f' Flowrate per production well: {model.wellbores.prodwellflowrate.value:10.1f} ' + model.wellbores.prodwellflowrate.CurrentUnits.value + NL)
1616-
f.write(f' Well depth (or total length, if not vertical): {model.reserv.depth.value:10.1f} ' +model.reserv.depth.CurrentUnits.value + NL)
1618+
f.write(f' {Outputs._field_label(Outputs.VERTICAL_WELL_DEPTH_OUTPUT_NAME, 49)}{model.reserv.depth.value:10.1f} ' + model.reserv.depth.CurrentUnits.value + NL)
16171619

16181620
if model.reserv.numseg.value == 1:
16191621
f.write(f' Geothermal gradient: {model.reserv.gradient.value[0]:10.4g} ' + model.reserv.gradient.CurrentUnits.value + NL)
@@ -1669,7 +1671,7 @@ def PrintOutputs(self, model: Model):
16691671
f.write(NL)
16701672
f.write(f' Number of Production Wells: {model.wellbores.nprod.value:10.0f}' + NL)
16711673
f.write(f' Number of Injection Wells: {model.wellbores.ninj.value:10.0f}' + NL)
1672-
f.write(f' Well depth (or total length, if not vertical): {model.reserv.depth.value:10.1f} ' + model.reserv.depth.CurrentUnits.value + NL)
1674+
f.write(f' {Outputs._field_label(Outputs.VERTICAL_WELL_DEPTH_OUTPUT_NAME, 49)}{model.reserv.depth.value:10.1f} ' + model.reserv.depth.CurrentUnits.value + NL)
16731675
f.write(f' Water loss rate: {model.reserv.waterloss.value*100:10.1f} ' + model.reserv.waterloss.CurrentUnits.value + NL)
16741676
f.write(f' Pump efficiency: {model.surfaceplant.pump_efficiency.value:10.1f} ' + model.surfaceplant.pump_efficiency.CurrentUnits.value + NL)
16751677
f.write(f' Injection temperature: {model.wellbores.Tinj.value:10.1f} ' + model.wellbores.Tinj.CurrentUnits.value + NL)
@@ -2163,3 +2165,7 @@ def o(output_param: OutputParameter):
21632165

21642166

21652167
model.logger.info(f'Complete {__class__!s}: {sys._getframe().f_code.co_name}')
2168+
2169+
@staticmethod
2170+
def _field_label(field_name:str, print_width_before_value: int) -> str:
2171+
return f'{field_name}:{" " * (print_width_before_value - len(field_name))}'

src/geophires_x/SUTRAOutputs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ def PrintOutputs(self, model: Model):
9797
f.write(NL)
9898
f.write(f" Number of Production Wells: {model.wellbores.nprod.value:10.0f}" + NL)
9999
f.write(f" Number of Injection Wells: {model.wellbores.ninj.value:10.0f}" + NL)
100-
f.write(f" Well Depth: {model.reserv.depth.value:10.1f} " + model.reserv.depth.CurrentUnits.value + NL)
100+
f.write(f" Well depth: {model.reserv.depth.value:10.1f} " + model.reserv.depth.CurrentUnits.value + NL)
101101

102102
pump_efficiency_display_unit = model.surfaceplant.pump_efficiency.CurrentUnits.value
103103
pump_efficiency_display = f'{model.surfaceplant.pump_efficiency.value:10.1f} {pump_efficiency_display_unit}'

src/geophires_x_client/geophires_x_result.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ class GeophiresXResult:
4343
'Number of injection wells',
4444
'Flowrate per production well',
4545
'Well depth',
46-
'Well depth (or total length, if not vertical)',
46+
'Well depth (or total length, if not vertical)', # deprecated
4747
'Geothermal gradient',
4848
'Segment 1 Geothermal gradient',
4949
'Segment 1 Thickness',
@@ -101,7 +101,8 @@ class GeophiresXResult:
101101
'ENGINEERING PARAMETERS': [
102102
'Number of Production Wells',
103103
'Number of Injection Wells',
104-
'Well depth (or total length, if not vertical)',
104+
'Well depth',
105+
'Well depth (or total length, if not vertical)', # deprecated
105106
'Water loss rate', # %
106107
'Pump efficiency', # %
107108
'Injection temperature',

0 commit comments

Comments
 (0)