NREL / GEOPHIRES-X

MIT License
26 stars 21 forks source link

Starting Cooling Sale Price #163

Closed geo-curious closed 2 weeks ago

geo-curious commented 3 months ago

In example 11 there are two lines for starting and finishing cooling sale price. These are meant to be read into economics.py. It appears in the version I have 3.4.4 that this value is never read into the revenue model. The NPV is unchanging as a result.

geo-curious commented 3 months ago

In example 11 there are two lines for starting and finishing cooling sale price. These are meant to be read into economics.py. It appears in the version I have 3.4.4 that this value is never read into the revenue model. The NPV is unchanging as a result.

I implemented a workaround, but this should be changed elsewhere. The CoolPrice needs to be swapped manually with the HeatPrice on ~line 2508 of economics.py: elif model.surfaceplant.enduse_option.value == EndUseOptions.HEAT: self.HeatRevenue.value, self.HeatCummRevenue.value = CalculateRevenue( model.surfaceplant.plant_lifetime.value, model.surfaceplant.construction_years.value, self.CCap.value, self.Coam.value, model.surfaceplant.HeatkWhProduced.value, self.CoolPrice.value)

softwareengineerprogrammer commented 3 months ago

@geo-curious sounds like this is a bug if I'm understanding correctly - please submit a PR to get the fix merged in, thanks!

softwareengineerprogrammer commented 3 months ago

Assignees:

  1. [ ] @geo-curious to provide PR
  2. [X] @malcolm-dsider re: pricing model
  3. [ ] @kfbeckers re: AC correctness
malcolm-dsider commented 3 months ago

Looking at the pricing model aspect of this report: As @geo-curious reports, Example 11 (Absorption Chiller) does include the lines: Starting Cooling Sale Price,0.0655 Ending Cooling Sale Price,0.0655

This sets the cooling price at a constant $0.0655/kWh for the lifetime of the project.

When the code read this, it set the Parameters "CoolingStartPrice" and "CoolingEndPrice" which are used in only one place, a call to the function "BuildPricingModel", which returns an array called "CoolingPrice", which is just an array equal to the number of years in the project, with a constant value in every slot (=0.0655).

That array is used in only one place, in this code:

elif model.surfaceplant.enduse_option.value == EndUseOptions.HEAT and model.surfaceplant.plant_type.value in [PlantType.ABSORPTION_CHILLER]: self.CoolingRevenue.value, self.CoolingCummRevenue.value = CalculateRevenue( model.surfaceplant.plant_lifetime.value, model.surfaceplant.construction_years.value, model.surfaceplant.cooling_kWh_Produced.value, self.CoolingPrice.value) self.TotalRevenue.value = self.CoolingRevenue.value

This all is correct, so I don't understand the problem, nor the fix suggested by @geo-curious .