Behavior PCEX2#
This is the documentation of the behavior module of the PCEX2 model from Godley & Lavoie (2006, Chapter 4), detailing the equations of the model.
Initialization#
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.initialize(self)
Initialize the behavior of the Godley-Lavoie 2006 PCEX2 model.
Within the book the initialization is generally to set all non-scenario variables to zero. Accordingly
Equations
\begin{align} C(0) &= 0 \\ G(0) &= 0 \\ Y(0) &= 0 \\ T(0) &= 0 \\ YD(0) &= 0 \\ V(0) &= 0 \\ H_s(0) &= 0 \\ H_h(0) &= 0 \\ B_h(0) &= 0 \\ B_s(0) &= 0 \\ B_{CB}(0) &= 0 \\ r(0) &= 0 \\ \end{align}Dependency
Sets
ConsumptionHousehold
ConsumptionGovernment
NationalIncome
InterestEarnedOnBillsHousehold
CentralBankProfits
Taxes
HouseholdMoneyStock
CentralBankMoneyStock
HouseholdBillStock
GovernmentBillStock
CentralBankBillStock
Wealth
InterestRate
DisposableIncome
Main Simulation Loop#
Scenario-determined variables#
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.consumption_government(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the consumption of the government. This is given exogenously by the scenario.
- Parameters:
Dependency
scenario: ConsumptionGovernment
Sets
ConsumptionGovernment
Variables based on prior steps#
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.interest_earned_on_bills_household(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the interest earned on bills by the household.
- Parameters:
Equations
\begin{align} r(t-1)B_h(t-1) \end{align}Dependency
prior: InterestRate
prior: HouseholdBillStock
Sets
InterestEarnedOnBillsHousehold
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.expected_disposable_income(self, t: tensor, scenario: dict, params: dict | None = None)
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
Solution of the step#
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.consumption(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the consumption.
- Parameters:
Equations
\begin{align} C(t) = (\alpha_{10} - \iota r(t-1)) YD^e(t) + \alpha_2 V(t-1) \end{align}Dependency
state: ExpectedDisposableIncome
prior: Wealth
params: PropensityToConsumeIncomeBase
params: PropensityToConsumeIncomeInterest
params: PropensityToConsumeSavings
Sets
ConsumptionHousehold
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.national_income(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the national income based on the closed-form solution derived in the documentation.
The closed-form solution is used to avoid the need to solve the system of equations iteratively, thus preserving the differentiability of the model trajectory.
- Parameters:
Equations
\begin{align} Y(t) = C(t) + G(t) \end{align}Dependency
state: ConsumptionHousehold
state: ConsumptionGovernment
Sets
NationalIncome
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.taxes(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the taxes.
- 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
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.disposable_income(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the disposable income.
- 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
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.wealth(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the wealth.
- Parameters:
Equations
\begin{align} V(t) = V(t-1) + YD(t) - C(t) \end{align}Dependency
state: DisposableIncome
state: ConsumptionHousehold
prior: Wealth
Sets
Wealth
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.expected_wealth(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the expected wealth.
- Parameters:
Equations
\begin{align} V^e(t) = V(t-1) + YD^e(t) - C(t) \end{align}Dependency
state: ExpectedDisposableIncome
state: ConsumptionHousehold
prior: Wealth
Sets
ExpectedWealth
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.household_bill_demand(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the household bill demand.
- 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
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.household_bill_holdings(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the household bill holdings.
- Parameters:
Equations
\begin{align} B_h(t) = B_h(t-1) + (B_h^d(t) - B_h(t-1)) \end{align}Dependency
state: HouseholdBillDemand
prior: HouseholdBillStock
Sets
HouseholdBillStock
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.household_money_stock(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the household deposits as a residual.
- Parameters:
Equations
\begin{align} H_h(t) = V(t) - B_h(t) \end{align}Dependency
state: Wealth
state: HouseholdBillStock
Sets
HouseholdMoneyStock
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.central_bank_profits(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the central bank profits (income on bills held).
- Parameters:
Equations
\begin{align} r(t-1)B_{CB}(t-1) \end{align}Dependency
prior: InterestRate
prior: CentralBankBillStock
Sets
CentralBankProfits
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.government_bill_issuance(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the government bill issuance.
- 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: GovernmentBillStock
state: GovernmentDemand
state: Taxes
state: CentralBankProfits
Sets
GovernmentBillStock
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.central_bank_bill_holdings(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the central bank bill holdings.
- Parameters:
Equations
\begin{align} B_{CB}(t) = B_{s}(t) - B_{h}(t) \end{align}Dependency
state: GovernmentBillStock
state: HouseholdBillStock
Sets
CentralBankBillStock
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.central_bank_money_stock(self, t: int, scenario: dict, params: dict | None = None, **kwargs)
Calculate the central bank money stock.
- 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
Theoretical Steady State Solution#
- macrostat.models.GL06PCEX2.behavior.BehaviorGL06PCEX2.compute_theoretical_steady_state_per_step(self, t: int, params: dict, scenario: dict)
Compute the theoretical steady state of the model for each given period. This is done per-period as there are parameters and scenarios that may be time-varying, so the interpretation is a timeseries of the theoretical steady state at a given period based on the parameters and scenarios at that period.
- Parameters:
Equations
\begin{align} G^\star(t) &= G(t)\\ r^\star(t) &= r(t)\\ \alpha_3 &= \frac{1-\alpha_1}{\alpha_2}\\ YD^\star(t) = YD^{e\star}(t) &= \frac{G^\star(t)}{\frac{\theta}{1-\theta} - r^\star(t)\cdot\left(\left(\lambda_0 + \lambda_1 r^\star(t) \right)\alpha_3 - \lambda_2\right)}\\ C^\star(t) &= YD^\star(t)\\ Y^\star(t) &= C^\star(t) + G^\star(t)\\ V^\star(t) = V^{e\star}(t) &= \alpha_3 YD^\star(t)\\ B_d^\star(t) = B_h^\star(t) &= \left(\left(\lambda_0 + \lambda_1 r^\star(t) \right)\alpha_3 - \lambda_2\right)\cdot YD^\star(t)\\ T^\star(t) &= \theta\cdot \left(Y^\star(t) + r^\star(t) B_h^\star(t)\right)\\ H_h^\star(t) &= V^{e\star}(t) - B_h^\star(t)\\ B_s^\star(t) &= \frac{r^\star(t) B_{CB}^\star(t) + T^\star(t) - G^\star(t)}{r^\star(t)}\\ B_{CB}^\star(t) &= B_s^\star(t) - B_h^\star(t)\\ H_s^\star(t) &= H_{s}(t-1) + (B_{CB}(t) - B_{CB}(t-1)) \end{align}