|
6 | 6 | from geophires_x import EconomicsSam |
7 | 7 | from geophires_x.EconomicsSam import calculate_sam_economics, SamEconomicsCalculations |
8 | 8 | from geophires_x.EconomicsUtils import BuildPricingModel, wacc_output_parameter, nominal_discount_rate_parameter, \ |
9 | | - real_discount_rate_parameter, after_tax_irr_parameter, moic_parameter |
| 9 | + real_discount_rate_parameter, after_tax_irr_parameter, moic_parameter, project_vir_parameter |
10 | 10 | from geophires_x.OptionList import Configuration, WellDrillingCostCorrelation, EconomicModel, EndUseOptions, PlantType, \ |
11 | 11 | _WellDrillingCostCorrelationCitation |
12 | 12 | from geophires_x.Parameter import intParameter, floatParameter, OutputParameter, ReadParameter, boolParameter, \ |
@@ -1839,13 +1839,7 @@ def __init__(self, model: Model): |
1839 | 1839 | CurrentUnits=PercentUnit.PERCENT, |
1840 | 1840 | PreferredUnits=PercentUnit.PERCENT, |
1841 | 1841 | ) |
1842 | | - self.ProjectVIR = self.OutputParameterDict[self.ProjectVIR.Name] = OutputParameter( |
1843 | | - "Project Value Investment Ratio", |
1844 | | - display_name='Project VIR=PI=PIR', |
1845 | | - UnitType=Units.PERCENT, |
1846 | | - PreferredUnits=PercentUnit.TENTH, |
1847 | | - CurrentUnits=PercentUnit.TENTH |
1848 | | - ) |
| 1842 | + self.ProjectVIR = self.OutputParameterDict[self.ProjectVIR.Name] = project_vir_parameter() |
1849 | 1843 | self.ProjectMOIC = self.OutputParameterDict[self.ProjectMOIC.Name] = moic_parameter() |
1850 | 1844 | self.ProjectPaybackPeriod = self.OutputParameterDict[self.ProjectPaybackPeriod.Name] = OutputParameter( |
1851 | 1845 | "Project Payback Period", |
@@ -2799,9 +2793,7 @@ def Calculate(self, model: Model) -> None: |
2799 | 2793 | convertible_unit(self.ProjectIRR.CurrentUnits)).magnitude |
2800 | 2794 |
|
2801 | 2795 | self.ProjectMOIC.value = self.sam_economics_calculations.moic.value |
2802 | | - |
2803 | | - # TODO SAM economic models VIR https://github.com/NREL/GEOPHIRES-X/issues/390 |
2804 | | - # self.ProjectVIR.value = non_calculated_output_placeholder_val |
| 2796 | + self.ProjectVIR.value = self.sam_economics_calculations.project_vir.value |
2805 | 2797 |
|
2806 | 2798 | # Calculate the project payback period |
2807 | 2799 | if self.econmodel.value == EconomicModel.SAM_SINGLE_OWNER_PPA: |
|
0 commit comments