Skip to content

Table of Contents

t3co/tco/tcocalc

TCOCalc Objects

Python
class TCOCalc()

__new__

Python
def __new__(cls, *args, **kwargs)

Creates a new instance of the TCOCalc class.

__init__

Python
def __init__(year_index: int,
             vehicle: Vehicle,
             scenario: Scenario,
             energy: Energy,
             payload_cap_cost_multiplier: float = None,
             cap_costs: CapitalCosts = None)

Initializes the TCOCalc instance.

Arguments:

  • year_index int - The year index.
  • vehicle Vehicle - The vehicle instance.
  • scenario Scenario - The scenario instance.
  • energy Energy - The energy instance.
  • payload_cap_cost_multiplier float, optional - Payload capacity cost multiplier. Defaults to None.
  • cap_costs CapitalCosts, optional - Capital costs instance. Defaults to None.

calculate_capital_costs

Python
def calculate_capital_costs(vehicle: Vehicle, scenario: Scenario) -> None

Calculates the capital costs.

Arguments:

  • vehicle Vehicle - The vehicle instance.
  • scenario Scenario - The scenario instance.

calculate_opportunity_costs

Python
def calculate_opportunity_costs(vehicle: Vehicle, scenario: Scenario,
                                energy: Energy) -> None

Calculates the opportunity costs.

Arguments:

  • vehicle Vehicle - The vehicle instance.
  • scenario Scenario - The scenario instance.
  • energy Energy - The energy instance.

calculate_operating_costs

Python
def calculate_operating_costs(vehicle: Vehicle, scenario: Scenario,
                              energy: Energy) -> None

Calculates the operating costs.

Arguments:

  • vehicle Vehicle - The vehicle instance.
  • scenario Scenario - The scenario instance.
  • energy Energy - The energy instance.

set_total_cost

Python
def set_total_cost(scenario: Scenario) -> None

Sets the total cost for the year.

Arguments:

  • scenario Scenario - The scenario instance.

set_disc_total_cost

Python
def set_disc_total_cost(vehicle: Vehicle,
                        scenario: Scenario,
                        payload_cap_cost_multiplier: float = None,
                        TCO_switch="DIRECT") -> None

Sets the discounted total cost for the year.

Arguments:

  • vehicle Vehicle - The vehicle instance.
  • scenario Scenario - The scenario instance.
  • payload_cap_cost_multiplier float, optional - Payload capacity cost multiplier. Defaults to None.
  • TCO_switch str, optional - TCO calculation method. Defaults to "DIRECT".

__str__

Python
def __str__() -> str

Returns a string representation of the TCOCalc instance.

Returns:

  • str - String representation of the TCOCalc instance.