Skip to content

Commit 1f47d62

Browse files
Add SBT to docs/schema generation
1 parent 409711f commit 1f47d62

File tree

3 files changed

+228
-18
lines changed

3 files changed

+228
-18
lines changed

src/geophires_x/SBTReservoir.py

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -190,8 +190,8 @@ def __init__(self, model: Model):
190190
AllowableRange=[1, 2],
191191
UnitType=Units.NONE,
192192
ErrMessage="assume constant user-provided flowrate (1)",
193-
ToolTipText="Must be 1 or 2. '1' means the user provides a constant mass flow rate. \
194-
'1' means the user provides an excel file with a mass flow rate profile."
193+
ToolTipText="Must be 1 or 2. '1' means the user provides a constant mass flow rate. "
194+
"'1' means the user provides an excel file with a mass flow rate profile."
195195
)
196196
self.flow_rate_file = self.ParameterDict[self.flow_rate_file.Name] = strParameter(
197197
"Flowrate File",
@@ -206,8 +206,8 @@ def __init__(self, model: Model):
206206
AllowableRange=[1, 2],
207207
UnitType=Units.NONE,
208208
ErrMessage="assume constant user-provided injection temperature (1)",
209-
ToolTipText="Must be 1 or 2. '1' means the user provides a constant injection temperature. \
210-
'1' means the user provides an excel file with an injection temperature profile."
209+
ToolTipText="Must be 1 or 2. '1' means the user provides a constant injection temperature. "
210+
"'1' means the user provides an excel file with an injection temperature profile."
211211
)
212212
self.injection_temperature_file = self.ParameterDict[self.injection_temperature_file.Name] = strParameter(
213213
"Injection Temperature File",
@@ -222,9 +222,9 @@ def __init__(self, model: Model):
222222
AllowableRange=[1, 5],
223223
UnitType=Units.NONE,
224224
ErrMessage="assume default SBT accuracy desired (1)",
225-
ToolTipText="Must be 1, 2, 3, 4 or 5 with 1 lowest accuracy and 5 highest accuracy. \
226-
Lowest accuracy runs fastest. Accuracy level impacts number of discretizations for \
227-
numerical integration and decision tree thresholds in SBT algorithm."
225+
ToolTipText="Must be 1, 2, 3, 4 or 5 with 1 lowest accuracy and 5 highest accuracy. "
226+
"Lowest accuracy runs fastest. Accuracy level impacts number of discretizations for "
227+
"numerical integration and decision tree thresholds in SBT algorithm."
228228
)
229229
self.percent_implicit = self.ParameterDict[self.percent_implicit.Name] = floatParameter(
230230
"SBT Percent Implicit Euler Scheme",
@@ -235,11 +235,11 @@ def __init__(self, model: Model):
235235
PreferredUnits=PercentUnit.TENTH,
236236
CurrentUnits=PercentUnit.TENTH,
237237
ErrMessage="assume default percent implicit (1.0)",
238-
ToolTipText="Should be between 0 and 1. Most stable is setting it to 1 which results in \
239-
a fully implicit Euler scheme when calculating the fluid temperature at each time step. \
240-
With a value of 0, the convective term is modelled using explicit Euler. \
241-
A value of 0.5 would model the convective term 50% explicit and 50% implicit, \
242-
which may be slightly more accurate than fully implicit."
238+
ToolTipText="Should be between 0 and 1. Most stable is setting it to 1 which results in "
239+
"a fully implicit Euler scheme when calculating the fluid temperature at each time step. "
240+
"With a value of 0, the convective term is modelled using explicit Euler. "
241+
"A value of 0.5 would model the convective term 50% explicit and 50% implicit, "
242+
"which may be slightly more accurate than fully implicit."
243243
)
244244
self.initial_timestep_count = self.ParameterDict[self.initial_timestep_count.Name] = intParameter(
245245
'SBT Initial Timestep Count',

src/geophires_x_schema_generator/__init__.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@
77
# Ruff disabled because imports are order-dependent
88
# ruff: noqa: I001
99
from geophires_x.Model import Model
10+
from geophires_x.SBTEconomics import SBTEconomics
11+
from geophires_x.SBTReservoir import SBTReservoir
12+
from geophires_x.SBTWellbores import SBTWellbores
1013

1114
from geophires_x.SFReservoir import SFReservoir
1215
from geophires_x.LHSReservoir import LHSReservoir
@@ -54,15 +57,18 @@ def get_parameter_sources(self) -> list:
5457
(MPFReservoir(dummy_model), 'Reservoir'),
5558
(SFReservoir(dummy_model), 'Reservoir'),
5659
(CylindricalReservoir(dummy_model), 'Reservoir'),
60+
(SBTReservoir(dummy_model), 'Reservoir'),
5761
(SUTRAReservoir(dummy_model), 'Reservoir'),
5862
(dummy_model.wellbores, 'Well Bores'),
5963
(AGSWellBores(dummy_model), 'Well Bores'),
64+
(SBTWellbores(dummy_model), 'Well Bores'),
6065
(SUTRAWellBores(dummy_model), 'Well Bores'),
6166
(dummy_model.surfaceplant, 'Surface Plant'),
6267
(SurfacePlantAGS(dummy_model), 'Surface Plant'),
6368
(SurfacePlantSUTRA(dummy_model), 'Surface Plant'),
6469
(dummy_model.economics, 'Economics'),
6570
(AGSEconomics(dummy_model), 'Economics'),
71+
(SBTEconomics(dummy_model), 'Economics'),
6672
(SUTRAEconomics(dummy_model), 'Economics'),
6773
(EconomicsCCUS(dummy_model), 'Economics'),
6874
(EconomicsAddOns(dummy_model), 'Economics'),

src/geophires_x_schema_generator/geophires-request.json

Lines changed: 210 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,13 +42,13 @@
4242
],
4343
"properties": {
4444
"Reservoir Model": {
45-
"description": "0: Simple cylindrical; 1: Multiple Parallel Fractures; 2: 1-D Linear Heat Sweep; 3: Single Fracture m/A Thermal Drawdown; 4: Annual Percentage Thermal Drawdown; 5: User-Provided Temperature Profile; 6: TOUGH2 Simulator; 7: SUTRA",
45+
"description": "0: Simple cylindrical; 1: Multiple Parallel Fractures; 2: 1-D Linear Heat Sweep; 3: Single Fracture m/A Thermal Drawdown; 4: Annual Percentage Thermal Drawdown; 5: User-Provided Temperature Profile; 6: TOUGH2 Simulator; 7: SUTRA; 8: SBT",
4646
"type": "integer",
4747
"units": null,
4848
"category": "Reservoir",
4949
"default": 4,
5050
"minimum": 0,
51-
"maximum": 7,
51+
"maximum": 8,
5252
"enum_values": [
5353
{
5454
"name": "CYLINDRICAL",
@@ -89,6 +89,11 @@
8989
"name": "SUTRA",
9090
"value": "SUTRA",
9191
"int_value": 7
92+
},
93+
{
94+
"name": "SBT",
95+
"value": "SBT",
96+
"int_value": 8
9297
}
9398
]
9499
},
@@ -462,6 +467,96 @@
462467
"minimum": 0.0,
463468
"maximum": 150
464469
},
470+
"Flowrate Model": {
471+
"description": "Must be 1 or 2. '1' means the user provides a constant mass flow rate. '1' means the user provides an excel file with a mass flow rate profile.",
472+
"type": "integer",
473+
"units": null,
474+
"category": "Reservoir",
475+
"default": "",
476+
"minimum": 1,
477+
"maximum": 2
478+
},
479+
"Flowrate File": {
480+
"description": "Excel file with a mass flow rate profile",
481+
"type": "string",
482+
"units": null,
483+
"category": "Reservoir",
484+
"default": "",
485+
"minimum": null,
486+
"maximum": null
487+
},
488+
"Injection Temperature Model": {
489+
"description": "Must be 1 or 2. '1' means the user provides a constant injection temperature. '1' means the user provides an excel file with an injection temperature profile.",
490+
"type": "integer",
491+
"units": null,
492+
"category": "Reservoir",
493+
"default": "",
494+
"minimum": 1,
495+
"maximum": 2
496+
},
497+
"Injection Temperature File": {
498+
"description": "Excel file with an injection temperature profile",
499+
"type": "string",
500+
"units": null,
501+
"category": "Reservoir",
502+
"default": "",
503+
"minimum": null,
504+
"maximum": null
505+
},
506+
"SBT Accuracy Desired": {
507+
"description": "Must be 1, 2, 3, 4 or 5 with 1 lowest accuracy and 5 highest accuracy. Lowest accuracy runs fastest. Accuracy level impacts number of discretizations for numerical integration and decision tree thresholds in SBT algorithm.",
508+
"type": "integer",
509+
"units": null,
510+
"category": "Reservoir",
511+
"default": 1,
512+
"minimum": 1,
513+
"maximum": 5
514+
},
515+
"SBT Percent Implicit Euler Scheme": {
516+
"description": "Should be between 0 and 1. Most stable is setting it to 1 which results in a fully implicit Euler scheme when calculating the fluid temperature at each time step. With a value of 0, the convective term is modelled using explicit Euler. A value of 0.5 would model the convective term 50% explicit and 50% implicit, which may be slightly more accurate than fully implicit.",
517+
"type": "number",
518+
"units": "",
519+
"category": "Reservoir",
520+
"default": 1.0,
521+
"minimum": 0.0,
522+
"maximum": 1.0
523+
},
524+
"SBT Initial Timestep Count": {
525+
"description": "The number of timesteps in the first ~3 hours of model",
526+
"type": "integer",
527+
"units": null,
528+
"category": "Reservoir",
529+
"default": 5,
530+
"minimum": 1,
531+
"maximum": 150
532+
},
533+
"SBT Final Timestep Count": {
534+
"description": "The number of timesteps after the first ~3 hours of model",
535+
"type": "number",
536+
"units": null,
537+
"category": "Reservoir",
538+
"default": 70,
539+
"minimum": 5,
540+
"maximum": 1000
541+
},
542+
"SBT Initial to Final Timestep Transition": {
543+
"description": "The time in secs at which the time arrays switches from closely spaced linear to logarithmic",
544+
"type": "number",
545+
"units": "sec",
546+
"category": "Reservoir",
547+
"default": 9900,
548+
"minimum": 1,
549+
"maximum": 40000000
550+
},
551+
"SBT Generate Wireframe Graphics": {
552+
"description": "Switch to control the generation of a wireframe drawing of a SBT wells configuration",
553+
"type": "boolean",
554+
"units": null,
555+
"category": "Reservoir",
556+
"default": false,
557+
"minimum": null,
558+
"maximum": null
559+
},
465560
"SUTRA Annual Heat File Name": {
466561
"description": "SUTRA file with heat stored, heat supplied and efficiency for each year",
467562
"type": "string",
@@ -697,13 +792,13 @@
697792
"maximum": 1.8e+30
698793
},
699794
"Closed-loop Configuration": {
700-
"description": "1: utube; 2: coaxial; 3: vertical; 4: L",
795+
"description": "1: utube; 2: coaxial; 3: vertical; 4: L; 5: EavorLoop",
701796
"type": "integer",
702797
"units": null,
703798
"category": "Well Bores",
704799
"default": 3,
705800
"minimum": 1,
706-
"maximum": 4,
801+
"maximum": 5,
707802
"enum_values": [
708803
{
709804
"name": "ULOOP",
@@ -724,17 +819,22 @@
724819
"name": "L",
725820
"value": "L",
726821
"int_value": 4
822+
},
823+
{
824+
"name": "EAVORLOOP",
825+
"value": "EavorLoop",
826+
"int_value": 5
727827
}
728828
]
729829
},
730830
"Well Geometry Configuration": {
731-
"description": "1: utube; 2: coaxial; 3: vertical; 4: L",
831+
"description": "1: utube; 2: coaxial; 3: vertical; 4: L; 5: EavorLoop",
732832
"type": "integer",
733833
"units": null,
734834
"category": "Well Bores",
735835
"default": 3,
736836
"minimum": 1,
737-
"maximum": 4,
837+
"maximum": 5,
738838
"enum_values": [
739839
{
740840
"name": "ULOOP",
@@ -755,6 +855,11 @@
755855
"name": "L",
756856
"value": "L",
757857
"int_value": 4
858+
},
859+
{
860+
"name": "EAVORLOOP",
861+
"value": "EavorLoop",
862+
"int_value": 5
758863
}
759864
]
760865
},
@@ -833,6 +938,69 @@
833938
"minimum": 0.01,
834939
"maximum": 100.0
835940
},
941+
"Vertical Section Length": {
942+
"description": "length/depth to the bottom of the vertical wellbores",
943+
"type": "number",
944+
"units": "meter",
945+
"category": "Well Bores",
946+
"default": 2000.0,
947+
"minimum": 0.01,
948+
"maximum": 10000.0
949+
},
950+
"Vertical Wellbore Spacing": {
951+
"description": "Horizontal distance between vertical wellbores",
952+
"type": "number",
953+
"units": "meter",
954+
"category": "Well Bores",
955+
"default": 100.0,
956+
"minimum": 0.01,
957+
"maximum": 10000.0
958+
},
959+
"Lateral Spacing": {
960+
"description": "Horizontal distance between laterals",
961+
"type": "number",
962+
"units": "meter",
963+
"category": "Well Bores",
964+
"default": 100.0,
965+
"minimum": 0.01,
966+
"maximum": 10000.0
967+
},
968+
"Lateral Inclination Angle": {
969+
"description": "Inclination of the lateral section, where 0 degrees would mean vertical while 90 degrees is pure horizontal",
970+
"type": "number",
971+
"units": "degrees",
972+
"category": "Well Bores",
973+
"default": 20.0,
974+
"minimum": 0.0,
975+
"maximum": 89.999999
976+
},
977+
"Discretization Length": {
978+
"description": "distance between sample point along length of model",
979+
"type": "number",
980+
"units": "meter",
981+
"category": "Well Bores",
982+
"default": 250.0,
983+
"minimum": 0.01,
984+
"maximum": 10000.0
985+
},
986+
"Junction Depth": {
987+
"description": "vertical depth where the different laterals branch out (where the multilateral section starts, second deepest depth of model)",
988+
"type": "number",
989+
"units": "meter",
990+
"category": "Well Bores",
991+
"default": 4000.0,
992+
"minimum": 1000,
993+
"maximum": 15000.0
994+
},
995+
"Lateral Endpoint Depth": {
996+
"description": "vertical depth where the lateral section ends (tip of the multilateral section, deepest depth of model)",
997+
"type": "number",
998+
"units": "meter",
999+
"category": "Well Bores",
1000+
"default": 7000.0,
1001+
"minimum": 1000,
1002+
"maximum": 15000.0
1003+
},
8361004
"End-Use Option": {
8371005
"description": "Select the end-use application of the geofluid heat: 1: Electricity; 2: Direct-Use Heat; 31: Cogeneration Topping Cycle, Heat sales considered as extra income; 32: Cogeneration Topping Cycle, Electricity sales considered as extra income; 41: Cogeneration Bottoming Cycle, Heat sales considered as extra income; 42: Cogeneration Bottoming Cycle, Electricity sales considered as extra income; 51: Cogeneration Parallel Cycle, Heat sales considered as extra income; 52: Cogeneration Parallel Cycle, Electricity sales considered as extra income",
8381006
"type": "integer",
@@ -1048,6 +1216,42 @@
10481216
"minimum": 1,
10491217
"maximum": 14
10501218
},
1219+
"Working Fluid Heat Capacity": {
1220+
"description": "Heat capacity of the working fluid",
1221+
"type": "number",
1222+
"units": "J/kg/K",
1223+
"category": "Surface Plant",
1224+
"default": 4200.0,
1225+
"minimum": 0.0,
1226+
"maximum": 10000.0
1227+
},
1228+
"Working Fluid Density": {
1229+
"description": "Density of the working fluid",
1230+
"type": "number",
1231+
"units": "kg/m**3",
1232+
"category": "Surface Plant",
1233+
"default": 1000.0,
1234+
"minimum": 0.0,
1235+
"maximum": 10000.0
1236+
},
1237+
"Working Fluid Thermal Conductivity": {
1238+
"description": "Thermal conductivity of the working fluid",
1239+
"type": "number",
1240+
"units": "W/m/K",
1241+
"category": "Surface Plant",
1242+
"default": 0.68,
1243+
"minimum": 0.0,
1244+
"maximum": 10.0
1245+
},
1246+
"Working Fluid Dynamic Viscosity": {
1247+
"description": "Dynamic viscosity of the working fluid",
1248+
"type": "number",
1249+
"units": "PaSec",
1250+
"category": "Surface Plant",
1251+
"default": 0.0006,
1252+
"minimum": 0.0,
1253+
"maximum": 1
1254+
},
10511255
"Dead-state Pressure": {
10521256
"description": "",
10531257
"type": "number",

0 commit comments

Comments
 (0)