NREL / SAM

System Advisor Model (SAM)
BSD 3-Clause "New" or "Revised" License
337 stars 140 forks source link

Fix Federal Depreciation Calculation in Host Developer Send-to-Excel with Equations #1793

Closed cpaulgilman closed 3 months ago

cpaulgilman commented 3 months ago

Cell CashFlow!B398 incorrectly referred to $C$141 for federal custom depreciation allocation which caused divide by zero errors that propagated through workbook all the way to LCOE and NPV results.

This issue only affected Host Developer send-to-Excel with equations when 20-yr SL allocation (Inputs!C141) is set to zero.

Checked that all other FOM spreadsheets do not have this problem.

Fixes #1784

Type of change

Please delete options that are not relevant.

Checklist:

If you have added a new compute module in a SSC pull request related to this one, be sure to check the Process Requirements.