Skip to content

Commit a5a98f4

Browse files
discount rate & term interest rate
1 parent a323151 commit a5a98f4

File tree

1 file changed

+13
-6
lines changed

1 file changed

+13
-6
lines changed

src/geophires_x/EconomicsSam.py

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424

2525
import geophires_x.Model as Model
2626
from geophires_x.EconomicsSamCashFlow import _calculate_sam_economics_cash_flow
27+
from geophires_x.Parameter import Parameter
2728
from geophires_x.Units import convertible_unit
2829

2930
_SAM_CASH_FLOW_PROFILE_KEY = 'Cash Flow'
@@ -103,14 +104,17 @@ def _get_single_owner_parameters(model: Model) -> dict[str, Any]:
103104

104105
ret: dict[str, Any] = {}
105106

107+
def pct(econ_value: Parameter) -> float:
108+
return econ_value.quantity().to(convertible_unit('%')).magnitude
109+
106110
itc = econ.RITCValue.value
107111
total_capex_musd = econ.CCap.value + itc
108112
ret['total_installed_cost'] = total_capex_musd * 1e6
109113

110114
opex_musd = econ.Coam.value
111115
ret['om_fixed'] = [opex_musd * 1e6]
112116
# GEOPHIRES assumes O&M fixed costs are not affected by inflation
113-
ret['om_fixed_escal'] = -1.0 * econ.RINFL.quantity().to(convertible_unit('%')).magnitude
117+
ret['om_fixed_escal'] = -1.0 * pct(econ.RINFL)
114118

115119
# FIXME TODO provide entire generation profile
116120
average_net_generation_MW = _get_average_net_generation_MW(model)
@@ -142,13 +146,16 @@ def _get_single_owner_parameters(model: Model) -> dict[str, Any]:
142146
ret['ppa_escalation'] = ppa_escalation_rate_percent
143147

144148
# Debt/equity ratio ('Fraction of Investment in Bonds' parameter)
145-
ret['debt_percent'] = econ.FIB.quantity().to(convertible_unit('%')).magnitude
146-
147-
# TODO/WIP interest rate
148-
# ret['real_discount_rate']
149+
ret['debt_percent'] = pct(econ.FIB)
149150

150151
# 'Property Tax Rate'
151-
ret['property_tax_rate'] = econ.PTR.quantity().to(convertible_unit('%')).magnitude
152+
ret['property_tax_rate'] = pct(econ.PTR)
153+
154+
# Interest rate
155+
ret['real_discount_rate'] = pct(econ.discountrate)
156+
ret['term_int_rate'] = pct(econ.BIR)
157+
158+
# TODO 'Inflated Equity Interest Rate' (may not have equivalent in SAM...?)
152159

153160
return ret
154161

0 commit comments

Comments
 (0)