code wiki / _hdl_build / nx_batt_econ.nx
nx_batt_econ.nx
buildroot/runtime/_hdl_build/nx_batt_econ.nx
about
nx_batt_econ.nx -- shared economic CORE for the battery-reclamation finance organs (DRY #15). Pure i64 cents,
no-float, NO imports. Both nx_batt_finmodel (the workup) and nx_batt_bizplan (the written plan) compute from THIS
single source, so the plan can NEVER drift from the model. Constants are itemized + line-summed in
nx_batt_finmodel (its gate asserts the sum == these); figures grounded in
knowledge/research/2026-06-23-battery-reclaim-cost-basis.md (verified anchors + flagged assumptions). license_tier: ORIGINAL
dependencies 0 imports · 2 importers
imports: none
imported by: nx_batt_bizplan.nxnx_batt_finmodel.nx
structs
| none |
consts
| 7 | const BE_CAPEX_TOTAL: i64 = 4148800 // $41,488.00 initial investment (itemized in nx_batt_finmodel) |
| 8 | const BE_OPEX_TOTAL: i64 = 880000 // $8,800.00 / mo operating cost (itemized in nx_batt_finmodel) |
functions
| 12 | func be_scenario_net(cell_c: i64, price_pct: i64, demand_pct: i64, extra_opex: i64) -> i64 |
| 24 | func be_base_net() -> i64 { return be_scenario_net(529, 100, 100, 0) } |
| 25 | func be_gross_base() -> i64 { return be_base_net() + BE_OPEX_TOTAL } |
| 26 | func be_payoff_months(capex: i64, net: i64) -> i64 |