macrostat.models.ECO3IOPC.BehaviorECO3IOPC#

class macrostat.models.ECO3IOPC.BehaviorECO3IOPC(parameters: ParametersECO3IOPC | None = None, scenarios: ScenariosECO3IOPC | None = None, variables: VariablesECO3IOPC | None = None, scenario: int = 0, debug: bool = False)[source]#

Bases: Behavior

Behavior class for Marco Veronese Passarella’s ECO-3IO-PC model

__init__(parameters: ParametersECO3IOPC | None = None, scenarios: ScenariosECO3IOPC | None = None, variables: VariablesECO3IOPC | None = None, scenario: int = 0, debug: bool = False)[source]#

Initialize the behavior of Marco Veronese Passarella’s ECO-3IO-PC model

Parameters:
  • parameters (ParametersECO3IOPC | None) – The parameters of the model.

  • scenarios (ScenariosECO3IOPC | None) – The scenarios of the model.

  • variables (VariablesECO3IOPC | None) – The variables of the model.

  • record (bool) – Whether to record the model output.

  • scenario (int) – The scenario to use for the model.

Methods

__init__([parameters, scenarios, variables, ...])

Initialize the behavior of Marco Veronese Passarella's ECO-3IO-PC model

add_module(name, module)

Add a child module to the current module.

apply(fn)

Apply fn recursively to every submodule (as returned by .children()) as well as self.

apply_parameter_shocks(t, scenario)

Apply parameter shocks to the model.

bfloat16()

Casts all floating point parameters and buffers to bfloat16 datatype.

buffers([recurse])

Return an iterator over module buffers.

carbon_mass_nonrenewable_energy(t, scenario)

The carbon mass of non-renewable energy is given by the conversion of emissions (due to non-renewable energy) with a fixed constant

central_bank_bill_holdings(t, scenario[, params])

Calculate the central bank bill holdings.

central_bank_money_stock(t, scenario[, params])

Calculate the central bank money stock.

central_bank_profits(t, scenario[, params])

Calculate the central bank profits (income on bills held).

children()

Return an iterator over immediate children modules.

co2_intensity_change(t, scenario[, params])

The energy emission intensity decreases by a fixed percentage each period

compile(*args, **kwargs)

Compile this Module's forward using torch.compile().

compute_theoretical_steady_state(**kwargs)

Compute the theoretical steady state of the model.

compute_theoretical_steady_state_per_step(...)

Compute the theoretical steady state of the model per step.

consumption(t, scenario[, params])

Calculate the consumption.

consumption_government(t, scenario[, params])

Calculate the consumption of the government.

cpu()

Move all model parameters and buffers to the CPU.

cuda([device])

Move all model parameters and buffers to the GPU.

cumulative_co2_emissions(t, scenario[, params])

Cumulative CO2 emissions are simply incremented by the current emissions

diffmax(x1, x2)

Smooth approximation to the minimum B: https://mathoverflow.net/questions/35191/a-differentiable-approximation-to-the-minimum-function

diffmax_v(x)

Smooth approximation to the maximum for a tensor.

diffmin(x1, x2)

Smooth approximation to the minimum B: https://mathoverflow.net/questions/35191/a-differentiable-approximation-to-the-minimum-function

diffmin_v(x)

Smooth approximation to the minimum.

diffwhere(condition, x1, x2)

Where condition that is differentiable with respect to the condition.

discarding_of_socioeconomic_stock(t, scenario)

The discarding of socioeconomic stock occurs as a percentage of existing stock, converted into units of matter

disposable_income(t, scenario[, params])

Calculate the disposable income.

double()

Casts all floating point parameters and buffers to double datatype.

emissions_from_nonrenewable_energy(t, scenario)

Emissions are based on the use of non-renewable energy, with a fixed emission intensity

energy_reserves(t, scenario[, params])

Energyreserves are depleted by human use and incremented by the conversion from resources

energy_to_resource_conversion(t, scenario[, ...])

Energy resources are converted into reserves at a fixed rate

energy_used_in_production(t, scenario[, params])

Energy use in production is given by a fixed energy intensity of production

eval()

Set the module in evaluation mode.

expected_disposable_income(t, scenario[, params])

The expected disposable income is simply the prior period's disposable income.

expected_wealth(t, scenario[, params])

Calculate the expected wealth.

extra_repr()

Return the extra representation of the module.

extraction_of_matter(t, scenario[, params])

The matter extracted is the difference in the matter consumed and the matter that was recycled

final_demand(t, scenario[, params])

Calculate the final demand as the sum of household and government demands spread over the sectors

float()

Casts all floating point parameters and buffers to float datatype.

forward()

Forward pass of the behavior.

get_buffer(target)

Return the buffer given by target if it exists, otherwise throw an error.

get_extra_state()

Return any extra state to include in the module's state_dict.

get_parameter(target)

Return the parameter given by target if it exists, otherwise throw an error.

get_submodule(target)

Return the submodule given by target if it exists, otherwise throw an error.

government_bill_issuance(t, scenario[, params])

Calculate the government bill issuance.

half()

Casts all floating point parameters and buffers to half datatype.

household_bill_demand(t, scenario[, params])

Calculate the household bill demand.

household_bill_holdings(t, scenario[, params])

Calculate the household bill holdings.

household_money_stock(t, scenario[, params])

Calculate the household deposits as a residual.

inflation(t, scenario[, params])

Compute the inflation (i.e. term for absence of money illusion).

initialize()

Initialize the behavior of Passarella's 3IO-PC model in the spirit of Godley & Lavoie, by keeping all variables as zero.

interest_earned_on_bills_household(t, scenario)

Calculate the interest earned on bills by the household.

ipu([device])

Move all model parameters and buffers to the IPU.

load_state_dict(state_dict[, strict, assign])

Copy parameters and buffers from state_dict into this module and its descendants.

material_goods_production(t, scenario[, params])

The material goods production in the economy

matter_reserves(t, scenario[, params])

Matter reserves are depleted by human use and incremented by the conversion from resources

matter_to_resource_conversion(t, scenario[, ...])

Matter resources is converted into reserves at a fixed rate

modules()

Return an iterator over all modules in the network.

mtia([device])

Move all model parameters and buffers to the MTIA.

named_buffers([prefix, recurse, ...])

Return an iterator over module buffers, yielding both the name of the buffer as well as the buffer itself.

named_children()

Return an iterator over immediate children modules, yielding both the name of the module as well as the module itself.

named_modules([memo, prefix, remove_duplicate])

Return an iterator over all modules in the network, yielding both the name of the module as well as the module itself.

named_parameters([prefix, recurse, ...])

Return an iterator over module parameters, yielding both the name of the parameter as well as the parameter itself.

national_income(t, scenario[, params])

National income is the sum of nominal final demand

non_renewable_energy_used_in_production(t, ...)

Non-renewable energy use in production is given by the difference in energy used and renewable energy used.

oxygen(t, scenario[, params])

The oxygen level is given by the difference in emissions and the carbon mass of energy

parameters([recurse])

Return an iterator over module parameters.

price_indices(t, scenario[, params])

Compute the consumer and government price indices based on their consumption shares

prices(t, scenario[, params])

Compute the sectoral prices as the sum of unit labour cost and a markup on intermediate prices

propensity_to_consume_income(t, scenario[, ...])

Endogenous propensity to consume out of income, dependent on the rate of interest

real_gross_output(t, scenario[, params])

Compute real gross output as the solution to the linear set of equations

recycling_of_discarded_stock(t, scenario[, ...])

A fixed share of the discarded socioeconomic stock is recycled

register_backward_hook(hook)

Register a backward hook on the module.

register_buffer(name, tensor[, persistent])

Add a buffer to the module.

register_forward_hook(hook, *[, prepend, ...])

Register a forward hook on the module.

register_forward_pre_hook(hook, *[, ...])

Register a forward pre-hook on the module.

register_full_backward_hook(hook[, prepend])

Register a backward hook on the module.

register_full_backward_pre_hook(hook[, prepend])

Register a backward pre-hook on the module.

register_load_state_dict_post_hook(hook)

Register a post-hook to be run after module's load_state_dict() is called.

register_load_state_dict_pre_hook(hook)

Register a pre-hook to be run before module's load_state_dict() is called.

register_module(name, module)

Alias for add_module().

register_parameter(name, param)

Add a parameter to the module.

register_state_dict_post_hook(hook)

Register a post-hook for the state_dict() method.

register_state_dict_pre_hook(hook)

Register a pre-hook for the state_dict() method.

renewable_energy_used_in_production(t, scenario)

Renewable energy use in production is given by a fixed energy intensity of production combined with a fixed share of energy sourced from renewables

requires_grad_([requires_grad])

Change if autograd should record operations on parameters in this module.

set_extra_state(state)

Set extra state contained in the loaded state_dict.

set_interest_rate(t, scenario[, params])

Set the interest rate.

set_submodule(target, module[, strict])

Set the submodule given by target if it exists, otherwise throw an error.

share_memory()

See torch.Tensor.share_memory_().

socioeconomic_stock(t, scenario[, params])

The socioeconomic stock grows through material extraction and shrinks due to discards

state_dict(*args[, destination, prefix, ...])

Return a dictionary containing references to the whole state of the module.

step(**kwargs)

Step function of the Godley-Lavoie 2006 PC model.

stock_of_durable_goods(t, scenario[, params])

The stock of durable goods evolves based on inflows from consumption and outflows from discard

tanhmask(x)

Convert a variable into 0 (x<0) and 1 (x>0)

taxes(t, scenario[, params])

Calculate the taxes.

temperature(t, scenario[, params])

Temperature is determined by a transformation of cumulative CO2

to(*args, **kwargs)

Move and/or cast the parameters and buffers.

to_empty(*, device[, recurse])

Move the parameters and buffers to the specified device without copying storage.

train([mode])

Set the module in training mode.

type(dst_type)

Casts all parameters and buffers to dst_type.

waste(t, scenario[, params])

Waste is computed as the difference in matter extraction and the growth in the SocioeconomicStock

wealth(t, scenario[, params])

Calculate the wealth.

xpu([device])

Move all model parameters and buffers to the XPU.

zero_grad([set_to_none])

Reset gradients of all model parameters.

Attributes

T_destination

call_super_init

dump_patches

version

training

carbon_mass_nonrenewable_energy(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

The carbon mass of non-renewable energy is given by the conversion of emissions (due to non-renewable energy) with a fixed constant

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} cen(t) &= \frac{emis(t)}{car} \end{align}

Dependency

  • state: Emissions

  • params: CarbonToCO2Conversion

Sets

  • CarbonMassOfEnergy

central_bank_bill_holdings(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the central bank bill holdings.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} B_{CB}(t) = B_{s}(t) - B_{h}(t) \end{align}

Dependency

  • state: GovernmentBillStock

  • state: HouseholdBillStock

Sets

  • CentralBankBillStock

central_bank_money_stock(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the central bank money stock.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} H_{s}(t) = H_{s}(t-1) + (B_{CB}(t) - B_{CB}(t-1)) \end{align}

Dependency

  • state: CentralBankBillStock

  • prior: CentralBankMoneyStock

  • prior: CentralBankBillStock

Sets

  • CentralBankMoneyStock

central_bank_profits(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the central bank profits (income on bills held).

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} r(t-1)B_{CB}(t-1) \end{align}

Dependency

  • prior: InterestRate

  • prior: CentralBankBillStock

Sets

  • CentralBankProfits

co2_intensity_change(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

The energy emission intensity decreases by a fixed percentage each period

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} \beta_e(t) = \beta_e(t-1) (1 - \Delta_\% \beta_e) \end{align}

Dependency

  • prior: CO2IntensityNonRenewableEnergy

  • params: CO2IntensityNonRenewableEnergyGrowth

Sets

  • CO2IntensityNonRenewableEnergy

consumption(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the consumption.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} c(t) = \alpha_1 \left(\frac{YD^e(t)}{p_c(t)} - \pi(t)\right) + \alpha_2 \frac{V(t-1)}{p_c(t)} \end{align}

Dependency

  • state: PropensityToConsumeIncome

  • state: ExpectedDisposableIncome

  • state: ConsumerPriceIndex

  • state: ConsumerPriceInflation

  • prior: Wealth

  • params: PropensityToConsumeSavings

Sets

  • RealConsumptionHousehold

consumption_government(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the consumption of the government. This is given exogenously by the scenario.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Dependency

  • scenario: ConsumptionGovernment

Sets

  • RealConsumptionGovernment

cumulative_co2_emissions(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Cumulative CO2 emissions are simply incremented by the current emissions

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} co2_{cum}(t) = co2_{cum}(t-1) + emis(t) \end{align}

Dependency

  • state: Emissions

  • prior: CumulativeCO2

Sets

  • CumulativeCO2

discarding_of_socioeconomic_stock(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

The discarding of socioeconomic stock occurs as a percentage of existing stock, converted into units of matter

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} dis(t) &= m_{mat}^\top (\zeta \cdot dc(t-1)) \end{align}

Dependency

  • prior: DurableGoodsStock

  • params: MaterialIntensity

  • params: DiscardedStockShare

Sets

  • DiscardedSocioeconomicStock

disposable_income(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the disposable income.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} YD(t) = Y(t) - T(t) + r(t-1)B_h(t-1) \end{align}

Dependency

  • state: NationalIncome

  • state: Taxes

  • state: InterestEarnedOnBillsHousehold

Sets

  • DisposableIncome

emissions_from_nonrenewable_energy(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Emissions are based on the use of non-renewable energy, with a fixed emission intensity

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} emis(t) = \beta_e nen(t) \end{align}

Dependency

  • state: NonRenewableEnergy

  • state: CO2IntensityNonRenewableEnergy

Sets

  • Emissions

energy_reserves(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Energyreserves are depleted by human use and incremented by the conversion from resources

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} k_e(t) &= k_e(t-1) + conv_e(t) - mat(t) \end{align}

Dependency

  • prior: EnergyReserves

  • state: ConversionEnergyToReserves

  • state: EnergyRequiredForProduction

Sets

  • EnergyReserves

energy_to_resource_conversion(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Energy resources are converted into reserves at a fixed rate

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} res_e(t) &= res_e(t-1) - conv_e(t)\\ conv_e(t) &= \sigma_e res_e(t) \end{align}

Dependency

  • prior: EnergyResources

  • params: EnergyToResourceConversionRate

Sets

  • EnergyResources

  • ConversionEnergyToReserves

energy_used_in_production(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Energy use in production is given by a fixed energy intensity of production

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} en(t) = \epsilon_e^\top x(t) \end{align}

Dependency

  • state: RealGrossOutput

  • params: EnergyIntensity

Sets

  • EnergyRequiredForProduction

expected_disposable_income(t: tensor, scenario: dict, params: dict | None = None)[source]#

The expected disposable income is simply the prior period’s disposable income. Equation (3.20) in the book.

Parameters:
  • t (torch.tensor) – Current time step

  • scenario (dict)

Equations

\[YD^e(t) = YD(t-1)\]

Dependency

  • prior: DisposableIncome

Sets

  • ExpectedDisposableIncome

expected_wealth(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the expected wealth.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} V^e(t) = V(t-1) + YD^e(t) - C(t) \end{align}

Dependency

  • state: ExpectedDisposableIncome

  • state: RealConsumptionHousehold

  • state: ConsumerPriceIndex

  • prior: Wealth

Sets

  • ExpectedWealth

extraction_of_matter(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

The matter extracted is the difference in the matter consumed and the matter that was recycled

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} mat(t) &= x_{mat} - rec(t) \end{align}

Dependency

  • state: RawMaterialProduction

  • state: RecycledSocioeconomicStock

Sets

  • ExtractedMatter

final_demand(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the final demand as the sum of household and government demands spread over the sectors

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} d_i(t) = \beta_{HH,i}C_{HH}(t) + \beta_{GOV,i}G(t) \end{align}

Dependency

  • state: RealConsumptionHousehold

  • state: RealConsumptionGovernment

  • params: HouseholdBudgetShare

  • params: GovernmentBudgetShare

Sets

  • RealFinalDemand

government_bill_issuance(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the government bill issuance.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} B_s(t) = B_s(t-1) + (G(t) - r(t-1)B_s(t-1)) - (T(t) + r(t-1)B_{CB}(t-1)) \end{align}

Dependency

  • prior: InterestRate

  • prior: GovernmentBillStock

  • state: GovernmentPriceIndex

  • state: RealConsumptionGovernment

  • state: Taxes

  • state: CentralBankProfits

Sets

  • GovernmentBillStock

household_bill_demand(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the household bill demand.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} \frac{B_h(t)}{V^e(t)} = \lambda_0 + \lambda_1 r(t) - \lambda_2 \frac{YD^e(t)}{V^e(t)} \end{align}

Dependency

  • state: ExpectedWealth

  • state: ExpectedDisposableIncome

  • state: InterestRate

  • params: WealthShareBills_Constant

  • params: WealthShareBills_InterestRate

  • params: WealthShareBills_Income

Sets

  • HouseholdBillDemand

household_bill_holdings(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the household bill holdings.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} B_h(t) = B_h(t-1) + (B_h^d(t) - B_h(t-1)) \end{align}

Dependency

  • state: HouseholdBillDemand

Sets

  • HouseholdBillStock

household_money_stock(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the household deposits as a residual.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} H_h(t) = V(t) - B_h(t) \end{align}

Dependency

  • state: Wealth

  • state: HouseholdBillStock

Sets

  • HouseholdMoneyStock

inflation(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Compute the inflation (i.e. term for absence of money illusion)

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} \pi(t) &= \left(\frac{p_c(t) - p_c(t-1)}{p_c(t-1)}\right)\left(\frac{V(t-1)}{p_c(t-1)}\right) \end{align}

Dependency

  • prior: Wealth

  • prior: ConsumerPriceIndex

  • state: ConsumerPriceIndex

Sets

  • ConsumerPriceInflation

initialize()[source]#

Initialize the behavior of Passarella’s 3IO-PC model in the spirit of Godley & Lavoie, by keeping all variables as zero. Accordingly, we can just “pass” the function as by default the state variables are all zero. The only exceptions are the price-indices which we initialize to one

interest_earned_on_bills_household(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the interest earned on bills by the household.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} r(t-1)B_h(t-1) \end{align}

Dependency

  • prior: InterestRate

  • prior: HouseholdBillStock

Sets

  • InterestEarnedOnBillsHousehold

material_goods_production(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

The material goods production in the economy

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} x_{mat}(t) &= m_{mat}^\top x(t) \end{align}

Dependency

  • state: RealGrossOutput

  • params: MaterialIntensity

Sets

  • RawMaterialProduction

matter_reserves(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Matter reserves are depleted by human use and incremented by the conversion from resources

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} k_m(t) &= k_m(t-1) + conv_m(t) - mat(t) \end{align}

Dependency

  • prior: MatterReserves

  • state: ConversionMatterToReserves

  • state: ExtractedMatter

Sets

  • MatterReserves

matter_to_resource_conversion(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Matter resources is converted into reserves at a fixed rate

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} res(t) &= res(t-1) - conv_m(t)\\ conv_m(t) &= \sigma_m res(t) \end{align}

Dependency

  • prior: MatterResources

  • params: MatterToResourceConversionRate

Sets

  • MatterResources

  • ConversionMatterToReserves

national_income(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

National income is the sum of nominal final demand

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} Y(t) = P^\top(t)d(t) \end{align}

Dependency

  • state: Prices

  • state: RealFinalDemand

Sets

  • NationalIncome

non_renewable_energy_used_in_production(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Non-renewable energy use in production is given by the difference in energy used and renewable energy used.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} nen(t) = en(t) - ren(t) \end{align}

Dependency

  • state: EnergyRequiredForProduction

  • state: RenewableEnergy

Sets

  • NonRenewableEnergy

oxygen(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

The oxygen level is given by the difference in emissions and the carbon mass of energy

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} o2(t) &= emis(t) - cen(t) \end{align}

Dependency

  • state: Emissions

  • state: CarbonMassOfEnergy

Sets

  • MassOfOxygen

price_indices(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Compute the consumer and government price indices based on their consumption shares

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} p_c(t) &= \beta_{HH}^\top P(t)\\ p_g(t) &= \beta_{G}^\top P(t) \end{align}

Dependency

  • state: Prices

  • params: HouseholdBudgetShare

  • params: GovernmentBudgetShare

Sets

  • ConsumerPriceIndex

  • GovernmentPriceIndex

prices(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Compute the sectoral prices as the sum of unit labour cost and a markup on intermediate prices

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} P_i(t) = \frac{w}{pr_i} + (1 + \mu)\sum_j a_{ij}P_j(t) \end{align}

Dependency

  • scenario: WageRate

  • params: LabourProductivity

  • params: Requirement

  • params: Markup

Sets

  • Prices

propensity_to_consume_income(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Endogenous propensity to consume out of income, dependent on the rate of interest

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} \alpha_1(t) = \alpha_{10} - \alpha_{11} r(t-1) \end{align}

Dependency

  • prior: InterestRate

  • params: PropensityToConsumeIncomeBase

  • params: PropensityToConsumeIncomeInterest

Sets

  • PropensityToConsumeIncome

real_gross_output(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Compute real gross output as the solution to the linear set of equations

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} x(t) = (I - A)^{-1}d(t) \end{align}

Dependency

  • state: RealFinalDemand

  • params: Requirement

Sets

  • RealGrossOutput

recycling_of_discarded_stock(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

A fixed share of the discarded socioeconomic stock is recycled

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} rec(t) &= \rho_{dis} dis(t) \end{align}

Dependency

  • state: DiscardedSocioeconomicStock

  • params: RecyclingRate

Sets

  • RecycledSocioeconomicStock

renewable_energy_used_in_production(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Renewable energy use in production is given by a fixed energy intensity of production combined with a fixed share of energy sourced from renewables

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} ren(t) = \epsilon_e^\top (\eta_{en} \cdot x(t)) \end{align}

Dependency

  • state: RealGrossOutput

  • params: EnergyIntensity

  • params: RenewableEnergyUseShare

Sets

  • RenewableEnergy

set_interest_rate(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Set the interest rate. This is given exogenously by the scenario.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} r(t) = \bar{r} \end{align)

Dependency

  • scenario: InterestRate

Sets

  • InterestRate

socioeconomic_stock(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

The socioeconomic stock grows through material extraction and shrinks due to discards

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} k_h(t) &= k_h(t-1) + x_{mat}(t) - dis(t) \end{align}

Dependency

  • prior: SocioeconomicStock

  • state: RawMaterialProduction

  • state: DiscardedSocioeconomicStock

Sets

  • SocioeconomicStock

step(**kwargs)[source]#

Step function of the Godley-Lavoie 2006 PC model.

stock_of_durable_goods(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

The stock of durable goods evolves based on inflows from consumption and outflows from discard

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} dc(t) &= dc(t-1) + B_c c(t) - \zeta dc(t-1) \end{align}

Dependency

  • prior: DurableGoodsStock

  • state: RealConsumptionHousehold

  • params: HouseholdBudgetShare

  • params: DiscardedStockShare

Sets

  • DurableGoodsStock

taxes(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the taxes.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} T(t) = \theta (Y(t) + r(t-1)B_h(t-1)) \end{align}

Dependency

  • params: TaxRate

  • state: NationalIncome

  • state: InterestEarnedOnBillsHousehold

Sets

  • Taxes

temperature(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Temperature is determined by a transformation of cumulative CO2

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} temp(t) = \frac{1}{1-fnc}\cdot tcre \cdot co2_{cum}(t) \end{align}

Dependency

  • state: CumulativeCO2

  • params: TransientClimateResponseCumCO2

  • params: NonCO2AnthropocentricForcing

Sets

  • CumulativeCO2

training: bool#
version = 'ECO3IOPC'#
waste(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Waste is computed as the difference in matter extraction and the growth in the SocioeconomicStock

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} wa(t) &= mat(t) - (k_h(t) - k_h(t-1)) \end{align}

Dependency

  • prior: SocioeconomicStock

  • state: SocioeconomicStock

  • state: ExtractedMatter

Sets

  • Waste

wealth(t: int, scenario: dict, params: dict | None = None, **kwargs)[source]#

Calculate the wealth.

Parameters:
  • t (int) – The time step.

  • scenario (dict) – The scenario.

  • params (dict | None) – The parameters.

Equations

\begin{align} V(t) = V(t-1) + YD(t) - C(t) \end{align}

Dependency

  • state: DisposableIncome

  • state: ConsumerPriceIndex

  • state: RealConsumptionHousehold

  • prior: Wealth

Sets

  • Wealth