CYCLUS
Loading...
Searching...
No Matches
facility_cost.cycpp.h File Reference

Go to the source code of this file.

Functions

double CalculateUnitCost (double production_capacity, double units_to_produce, double input_cost_per_unit=0.0) const
 
double CalculateUnitPrice (double production_capacity, double units_to_produce, double input_cost_per_unit=0.0) const
 
std::unordered_map< std::string, double > GenerateParamList () const override
 

Variables

double annual_labor_cost
 
double annual_operations_and_maintenance
 
double capital_cost
 
double cost_override
 
std::vector< int > cycpp_shape_annual_labor_cost = {0}
 
std::vector< int > cycpp_shape_annual_operations_and_maintenance = {0}
 
std::vector< int > cycpp_shape_capital_cost = {0}
 
std::vector< int > cycpp_shape_cost_override = {0}
 
std::vector< int > cycpp_shape_facility_depreciation_lifetime = {0}
 
std::vector< int > cycpp_shape_facility_operational_lifetime = {0}
 
std::vector< int > cycpp_shape_property_insurance_rate = {0}
 
std::vector< int > cycpp_shape_property_tax_rate = {0}
 
double facility_depreciation_lifetime
 
double facility_operational_lifetime
 
double property_insurance_rate
 
double property_tax_rate
 

Function Documentation

◆ CalculateUnitCost()

double CalculateUnitCost ( double production_capacity,
double units_to_produce,
double input_cost_per_unit = 0.0 ) const

Calculates the levelized unit cost of production, accounting for capital depreciation, O&M, labor, property taxes, and input costs.

unit_cost = cost_override if cost_override > 0, otherwise unit_cost = production_cost + material_cost

Where:

  • production_cost = levelized_fixed_costs/units_produced_annually + levelized_variable_costs + (initial_investment/units_produced_annually) * [property_tax_insurance_rate + (1/(1-income_tax_rate)) * PMT(facility_lifetime, tax_modified_rate_of_return, 1, 0) - (1/facility_lifetime) * (income_tax_rate/(1-income_tax_rate))]
  • material_cost = Unit Cost of Material (weighted average of input material unit values)
  • units_produced_annually = production_capacity * timesteps_per_year
  • levelized_fixed_costs = annual_operations_and_maintenance
  • levelized_variable_costs = annual_labor_cost
  • initial_investment = capital_cost
  • property_and_insurance_rate = property_tax_rate + property_insurance_rate
  • tax_modified_rate_of_return = (1-income_tax_rate)*bond_rate*bond_fraction + shareholder_rate*shareholder_fraction
  • income_tax_rate = Income Tax Rate
  • facility_lifetime = facility_depreciation_lifetime

The model assumes straight-line depreciation over the facility lifetime.

Parameters
production_capacityMaximum throughput per timestep
units_to_produceNumber of units produced in the batch
input_cost(Optional) Total cost of input materials used in the batch
Returns
Estimated levelized cost to produce one unit

Definition at line 118 of file facility_cost.cycpp.h.

◆ CalculateUnitPrice()

double CalculateUnitPrice ( double production_capacity,
double units_to_produce,
double input_cost_per_unit = 0.0 ) const

Definition at line 206 of file facility_cost.cycpp.h.

◆ GenerateParamList()

std::unordered_map< std::string, double > GenerateParamList ( ) const
override

Definition at line 82 of file facility_cost.cycpp.h.

Variable Documentation

◆ annual_labor_cost

double annual_labor_cost

Definition at line 62 of file facility_cost.cycpp.h.

◆ annual_operations_and_maintenance

double annual_operations_and_maintenance

Definition at line 37 of file facility_cost.cycpp.h.

◆ capital_cost

double capital_cost

This includes the required header to add facility costs to archetypes.

One should only need to:

  • '#include "toolkit/facility_cost.cycpp.h"' in the header of the archetype class (as private)
  • Add InitEconParameters() to EnterNotify() in the cc file of the archetype class. How to add parameters to this file:
  1. Add the pragma. A default value MUST be added to ensure backwards compatibility.
  2. Edit the unordered_map called "econ_params" i. add the desired parameter to the array {"name", value} ii. the value of the pair should be the variable name exactly
  3. Add "std::vector<int> cycpp_shape_<param_name> = {0};" to the end of the file with the other ones, reaplcing <param_name> with the name you put in the econ_params array (again, must match exactly).

Definition at line 23 of file facility_cost.cycpp.h.

◆ cost_override

double cost_override

Definition at line 70 of file facility_cost.cycpp.h.

◆ cycpp_shape_annual_labor_cost

std::vector<int> cycpp_shape_annual_labor_cost = {0}

Definition at line 219 of file facility_cost.cycpp.h.

◆ cycpp_shape_annual_operations_and_maintenance

std::vector<int> cycpp_shape_annual_operations_and_maintenance = {0}

Definition at line 216 of file facility_cost.cycpp.h.

◆ cycpp_shape_capital_cost

std::vector<int> cycpp_shape_capital_cost = {0}

Definition at line 214 of file facility_cost.cycpp.h.

◆ cycpp_shape_cost_override

std::vector<int> cycpp_shape_cost_override = {0}

Definition at line 220 of file facility_cost.cycpp.h.

◆ cycpp_shape_facility_depreciation_lifetime

std::vector<int> cycpp_shape_facility_depreciation_lifetime = {0}

Definition at line 218 of file facility_cost.cycpp.h.

◆ cycpp_shape_facility_operational_lifetime

std::vector<int> cycpp_shape_facility_operational_lifetime = {0}

Definition at line 217 of file facility_cost.cycpp.h.

◆ cycpp_shape_property_insurance_rate

std::vector<int> cycpp_shape_property_insurance_rate = {0}

Definition at line 221 of file facility_cost.cycpp.h.

◆ cycpp_shape_property_tax_rate

std::vector<int> cycpp_shape_property_tax_rate = {0}

Definition at line 215 of file facility_cost.cycpp.h.

◆ facility_depreciation_lifetime

double facility_depreciation_lifetime

Definition at line 53 of file facility_cost.cycpp.h.

◆ facility_operational_lifetime

double facility_operational_lifetime

Definition at line 45 of file facility_cost.cycpp.h.

◆ property_insurance_rate

double property_insurance_rate

Definition at line 78 of file facility_cost.cycpp.h.

◆ property_tax_rate

double property_tax_rate

Definition at line 31 of file facility_cost.cycpp.h.