From 8fb8454c1c52e625eeaddef2669b4b425dfe9d0e Mon Sep 17 00:00:00 2001 From: Matt Prilliman <54449384+mjprilliman@users.noreply.github.com> Date: Fri, 4 Oct 2024 16:30:23 -0500 Subject: [PATCH] Add option to turn off reservoir replacements --- ...mal Power_All Equity Partnership Flip.json | 1 + .../Geothermal Power_LCOE Calculator.json | 1 + ...rmal Power_Leveraged Partnership Flip.json | 1 + .../Geothermal Power_Merchant Plant.json | 1 + .../defaults/Geothermal Power_None.json | 1 + .../Geothermal Power_Sale Leaseback.json | 1 + .../Geothermal Power_Single Owner.json | 1 + deploy/runtime/ui/Geothermal Costs.json | 3 +- deploy/runtime/ui/Geothermal OM Costs.json | 13 ++-- .../ui/Geothermal Plant and Equipment.json | 66 ++++++++++++++++++- 10 files changed, 79 insertions(+), 10 deletions(-) diff --git a/deploy/runtime/defaults/Geothermal Power_All Equity Partnership Flip.json b/deploy/runtime/defaults/Geothermal Power_All Equity Partnership Flip.json index 387b17ff1..038da2e7d 100644 --- a/deploy/runtime/defaults/Geothermal Power_All Equity Partnership Flip.json +++ b/deploy/runtime/defaults/Geothermal Power_All Equity Partnership Flip.json @@ -29,6 +29,7 @@ 0.0, 0.0 ], + "allow_reservoir_replacements": 0.0, "ambient_pressure": 14.7, "analysis_period": 25.0, "analysis_period_warning": "No messages.", diff --git a/deploy/runtime/defaults/Geothermal Power_LCOE Calculator.json b/deploy/runtime/defaults/Geothermal Power_LCOE Calculator.json index eb2a563eb..2070a7410 100644 --- a/deploy/runtime/defaults/Geothermal Power_LCOE Calculator.json +++ b/deploy/runtime/defaults/Geothermal Power_LCOE Calculator.json @@ -29,6 +29,7 @@ 0.0, 0.0 ], + "allow_reservoir_replacements": 0.0, "ambient_pressure": 14.7, "analysis_type": 0.0, "annual_albedo": "nan", diff --git a/deploy/runtime/defaults/Geothermal Power_Leveraged Partnership Flip.json b/deploy/runtime/defaults/Geothermal Power_Leveraged Partnership Flip.json index fe7c0d098..9a07cfdce 100644 --- a/deploy/runtime/defaults/Geothermal Power_Leveraged Partnership Flip.json +++ b/deploy/runtime/defaults/Geothermal Power_Leveraged Partnership Flip.json @@ -29,6 +29,7 @@ 0.0, 0.0 ], + "allow_reservoir_replacements": 0.0, "ambient_pressure": 14.7, "analysis_period": 25.0, "analysis_period_warning": "No messages.", diff --git a/deploy/runtime/defaults/Geothermal Power_Merchant Plant.json b/deploy/runtime/defaults/Geothermal Power_Merchant Plant.json index c4f3b3ae4..b86272fc8 100644 --- a/deploy/runtime/defaults/Geothermal Power_Merchant Plant.json +++ b/deploy/runtime/defaults/Geothermal Power_Merchant Plant.json @@ -29,6 +29,7 @@ 0.0, 0.0 ], + "allow_reservoir_replacements": 0.0, "ambient_pressure": 14.7, "analysis_period": 25.0, "analysis_period_warning": "No messages.", diff --git a/deploy/runtime/defaults/Geothermal Power_None.json b/deploy/runtime/defaults/Geothermal Power_None.json index 887d309cb..e6af395a7 100644 --- a/deploy/runtime/defaults/Geothermal Power_None.json +++ b/deploy/runtime/defaults/Geothermal Power_None.json @@ -29,6 +29,7 @@ 0.0, 0.0 ], + "allow_reservoir_replacements": 0.0, "ambient_pressure": 14.7, "analysis_type": 0.0, "annual_albedo": "nan", diff --git a/deploy/runtime/defaults/Geothermal Power_Sale Leaseback.json b/deploy/runtime/defaults/Geothermal Power_Sale Leaseback.json index c39aec6e7..7b97f76bc 100644 --- a/deploy/runtime/defaults/Geothermal Power_Sale Leaseback.json +++ b/deploy/runtime/defaults/Geothermal Power_Sale Leaseback.json @@ -29,6 +29,7 @@ 0.0, 0.0 ], + "allow_reservoir_replacements": 0.0, "ambient_pressure": 14.7, "analysis_period": 25.0, "analysis_period_warning": "No messages.", diff --git a/deploy/runtime/defaults/Geothermal Power_Single Owner.json b/deploy/runtime/defaults/Geothermal Power_Single Owner.json index c06546e04..098c1c0e2 100644 --- a/deploy/runtime/defaults/Geothermal Power_Single Owner.json +++ b/deploy/runtime/defaults/Geothermal Power_Single Owner.json @@ -29,6 +29,7 @@ 0.0, 0.0 ], + "allow_reservoir_replacements": 0.0, "ambient_pressure": 14.7, "analysis_period": 25.0, "analysis_period_warning": "No messages.", diff --git a/deploy/runtime/ui/Geothermal Costs.json b/deploy/runtime/ui/Geothermal Costs.json index d6786e379..794fc41b1 100644 --- a/deploy/runtime/ui/Geothermal Costs.json +++ b/deploy/runtime/ui/Geothermal Costs.json @@ -12904,7 +12904,8 @@ "\t\tssc_var( geothermal, 'design_temp', ${design_temp} );", "\t\tssc_var( geothermal, 'specify_pump_work', ${specify_pump_work} ); // INTEGER", "\t\tssc_var( geothermal, 'specified_pump_work_amount', ${specified_pump_work_amount} );", - "", + "\t\t\r", + "\t\tssc_var( geothermal, 'allow_reservoir_replacements', ${allow_reservoir_replacements});", "\t\t// detailed geothermal inputs", "\t\tssc_var( geothermal, 'rock_thermal_conductivity', ${rock_thermal_conductivity} );", "\t\tssc_var( geothermal, 'rock_specific_heat', ${rock_specific_heat} );", diff --git a/deploy/runtime/ui/Geothermal OM Costs.json b/deploy/runtime/ui/Geothermal OM Costs.json index b7948c7bf..7993b776d 100644 --- a/deploy/runtime/ui/Geothermal OM Costs.json +++ b/deploy/runtime/ui/Geothermal OM Costs.json @@ -1,7 +1,7 @@ { "Name": "Geothermal OM Costs", - "Width": 778.0, - "Height": 209.0, + "Width": 551.0, + "Height": 206.0, "FormObjects": { "Button": { "Visible": 1.0, @@ -12,11 +12,11 @@ }, "X": { "Type": 3.0, - "Integer": 111.0 + "Integer": 24.0 }, "Y": { "Type": 3.0, - "Integer": 78.0 + "Integer": 57.0 }, "Width": { "Type": 3.0, @@ -61,7 +61,7 @@ }, "Height": { "Type": 3.0, - "Integer": 180.0 + "Integer": 108.0 }, "Tool Tip": { "Type": 5.0, @@ -110,7 +110,8 @@ "\t}\r", "\tssc_var( geothermal, 'resource_depth', ${resource_depth} );\r", "\tssc_var( geothermal, 'dt_prod_well', ${dt_prod_well} );\t\r", - "\tssc_var( geothermal, 'prod_well_choice', ${prod_well_choice} );\t\t\t\t\t\t\t\t\t\t\t\t\r", + "\tssc_var( geothermal, 'prod_well_choice', ${prod_well_choice} );\t\r", + "\tssc_var( geothermal, 'allow_reservoir_replacements', ${allow_reservoir_replacements});\t\t\t\t\t\t\t\t\t\t\t\r", "\t// Other inputs\t\t\t\t\t\t\t \r", "\tssc_var( geothermal, 'geothermal_analysis_period', ${geothermal_analysis_period} ); // INTEGER\r", "\tssc_var( geothermal, 'model_choice', ${model_choice} ); // INTEGER\r", diff --git a/deploy/runtime/ui/Geothermal Plant and Equipment.json b/deploy/runtime/ui/Geothermal Plant and Equipment.json index 6fb88feec..521c28963 100644 --- a/deploy/runtime/ui/Geothermal Plant and Equipment.json +++ b/deploy/runtime/ui/Geothermal Plant and Equipment.json @@ -476,6 +476,47 @@ } } }, + "CheckBox": { + "Visible": 1.0, + "ObjectProperties": { + "Name": { + "Type": 5.0, + "String": "allow_reservoir_replacements" + }, + "X": { + "Type": 3.0, + "Integer": 42.0 + }, + "Y": { + "Type": 3.0, + "Integer": 483.0 + }, + "Width": { + "Type": 3.0, + "Integer": 249.0 + }, + "Height": { + "Type": 3.0, + "Integer": 24.0 + }, + "Tool Tip": { + "Type": 5.0, + "String": "" + }, + "Caption": { + "Type": 5.0, + "String": "Allow reservoir replacements" + }, + "State": { + "Type": 2.0, + "Boolean": 1.0 + }, + "TabOrder": { + "Type": 3.0, + "Integer": -1.0 + } + } + }, "Numeric": { "Visible": 1.0, "ObjectProperties": { @@ -1552,7 +1593,7 @@ }, "Y": { "Type": 3.0, - "Integer": 483.0 + "Integer": 513.0 }, "Width": { "Type": 3.0, @@ -2967,7 +3008,7 @@ }, "Y": { "Type": 3.0, - "Integer": 483.0 + "Integer": 513.0 }, "Width": { "Type": 3.0, @@ -3496,6 +3537,19 @@ "sscVariableName": "", "sscVariableValue": "" }, + "allow_reservoir_replacements": { + "Version": 4.0, + "Type": 1.0, + "Label": "Allow reservoir replacements", + "Units": "0/1", + "Group": "Geothermal Plant and Equipment", + "IndexLabels": "", + "Flags": 3.0, + "DefaultValue": 0.0, + "UIObject": "CheckBox", + "sscVariableName": "", + "sscVariableValue": "" + }, "ambient_pressure": { "Version": 4.0, "Type": 1.0, @@ -4100,7 +4154,7 @@ "//\tssc_var( obj, 'adjust:constant', 0.0 );", "//\tssc_var( obj, 'adjust', {\"constant\" = 0.0} );", "\tssc_var( obj, 'adjust_constant', 0.0 );\r", - "", + "\tssc_var( obj, 'allow_reservoir_replacements', ${allow_reservoir_replacements});", "\tssc_var( obj, 'resource_type', ${resource_type} ); // INTEGER", "\tssc_var( obj, 'resource_temp', ${resource_temp} );", "\tssc_var( obj, 'resource_depth', ${resource_depth} );", @@ -4309,6 +4363,7 @@ "\ton_change{'prod_well_choice'}();\r", "\tloss_adjustment_set();\r", "\ton_change{'use_weather_file_conditions'}();\r", + "\ton_change{'allow_reservoir_replacements'}();\r", "\trefresh();\r", "};\t\r", "\r", @@ -4364,6 +4419,11 @@ "\tenable('wet_bulb_temp_input', check == 0);\r", "\tenable('wet_bulb_temp_wf', check == 1);\r", "\trefresh();\r", + "};\r", + "\r", + "on_change{'allow_reservoir_replacements'} = define() {\r", + "\tcheck = value('allow_reservoir_replacements');\r", + "\tenable('temp_decline_max', check);\r", "};" ] } \ No newline at end of file