Added test mod file for the extended path approach (with steady state file and a routine computing
the mean preserving spread correction): Real Business Cycle model with endogenous labour and CES production function.time-shift
parent
6d9983df0c
commit
20bd67a7aa
|
@ -0,0 +1,18 @@
|
|||
function m = mean_preserving_spread(autoregressive_parameter)
|
||||
% Computes the mean preserving spread for first order autoregressive process.
|
||||
%
|
||||
% The mean preserving spread m is a constant such that the mean of the process
|
||||
%
|
||||
% X_t = X^{\star} * e^{x_t - m}
|
||||
% x_t = \rho x_{t-1} + \varepsilon_t
|
||||
% \varepsilon_t \sim N(0,\sigma^2)
|
||||
%
|
||||
% is X^{\star}. This constant is such that the unconditional expectation of X_t is equal
|
||||
% to the deterministic steady state of X_t
|
||||
%
|
||||
% AUTHOR(S)
|
||||
% stephane DOT adjemian AT univ DASH lemans DOT fr
|
||||
% frederic DOT karame AT univ DASH evry DOT fr
|
||||
global M_
|
||||
|
||||
m = M_.Sigma_e/(1-autoregressive_parameter*autoregressive_parameter);
|
|
@ -0,0 +1,52 @@
|
|||
var Capital, Output, Labour, Consumption, Efficiency, efficiency;
|
||||
|
||||
varexo EfficiencyInnovation;
|
||||
|
||||
parameters beta, theta, tau, alpha, psi, delta, rho, effstar, sigma2;
|
||||
|
||||
/*
|
||||
** Calibration
|
||||
*/
|
||||
|
||||
|
||||
beta = 0.990;
|
||||
theta = 0.357;
|
||||
tau = 2.000;
|
||||
alpha = 0.450;
|
||||
psi = -0.500;
|
||||
delta = 0.020;
|
||||
rho = 0.950;
|
||||
effstar = 1.000;
|
||||
sigma2 = 0.001;
|
||||
|
||||
external_function(name=mean_preserving_spread);
|
||||
|
||||
model(block,bytecode);
|
||||
|
||||
// Eq. n°1:
|
||||
efficiency = rho*efficiency(-1) + EfficiencyInnovation;
|
||||
|
||||
// Eq. n°2:
|
||||
Efficiency = effstar*exp(efficiency-mean_preserving_spread(rho));
|
||||
|
||||
// Eq. n°3:
|
||||
Output = Efficiency*(alpha*(Capital(-1)^psi)+(1-alpha)*(Labour^psi))^(1/psi);
|
||||
|
||||
// Eq. n°4:
|
||||
Consumption + Capital - Output - (1-delta)*Capital(-1);
|
||||
|
||||
// Eq. n°5:
|
||||
((1-theta)/theta)*(Consumption/(1-Labour)) - (1-alpha)*(Output/Labour)^(1-psi);
|
||||
|
||||
// Eq. n°6:
|
||||
(((Consumption^theta)*((1-Labour)^(1-theta)))^(1-tau))/Consumption - beta*((((Consumption(1)^theta)*((1-Labour(1))^(1-theta)))^(1-tau))/Consumption(1))*(alpha*((Output(1)/Capital)^(1-psi))+1-delta);
|
||||
|
||||
end;
|
||||
|
||||
shocks;
|
||||
var EfficiencyInnovation = sigma2;
|
||||
end;
|
||||
|
||||
steady;
|
||||
|
||||
ts = extended_path([],100);
|
|
@ -0,0 +1,46 @@
|
|||
function [ys, info] = rbc_steadystate(ys, exogenous)
|
||||
% Steady state routine for rbc.mod (Business Cycle model with endogenous labour and CES production function)
|
||||
|
||||
|
||||
% AUTHOR(S)
|
||||
% stephane DOT adjemian AT univ DASH lemans DOT fr
|
||||
% frederic DOT karame AT univ DASH evry DOT fr
|
||||
|
||||
% Output_per_unit_of_Capital = (((1/beta)-1+delta)/alpha)^(1/(1-psi));
|
||||
% Consumption_per_unit_of_Capital = Output_per_unit_of_Capital - delta;
|
||||
% Labour_per_unit_of_Capital = (((Output_per_unit_of_Capital/effstar)^psi-alpha)/(1-alpha))^(1/psi);
|
||||
% Output_per_unit_of_Labour = Output_per_unit_of_Capital/Labour_per_unit_of_Capital;
|
||||
% Consumption_per_unit_of_Labour = Consumption_per_unit_of_Capital/Labour_per_unit_of_Capital;
|
||||
% SteadyStateLabour = 1/(1 + Consumption_per_unit_of_Labour/((theta*(1-alpha)/(1-theta))*(Output_per_unit_of_Labour^(1-psi))));
|
||||
% SteadyStateConsumption = Consumption_per_unit_of_Labour*SteadyStateLabour;
|
||||
% SteadyStateCapital = SteadyStateLabour/Labour_per_unit_of_Capital;
|
||||
% SteadyStateOutput = Output_per_unit_of_Capital*SteadyStateCapital;
|
||||
% ShareOfCapital = alpha/(alpha+(1-alpha)*Labour_per_unit_of_Capital^psi);
|
||||
|
||||
global M_
|
||||
|
||||
info = 0;
|
||||
|
||||
% Compute steady state ratios.
|
||||
Output_per_unit_of_Capital=((1/M_.params(1)-1+M_.params(6))/M_.params(4))^(1/(1-M_.params(5)));
|
||||
Consumption_per_unit_of_Capital=Output_per_unit_of_Capital-M_.params(6);
|
||||
Labour_per_unit_of_Capital=(((Output_per_unit_of_Capital/M_.params(8))^M_.params(5)-M_.params(4))/(1-M_.params(4)))^(1/M_.params(5));
|
||||
Output_per_unit_of_Labour=Output_per_unit_of_Capital/Labour_per_unit_of_Capital;
|
||||
Consumption_per_unit_of_Labour=Consumption_per_unit_of_Capital/Labour_per_unit_of_Capital;
|
||||
|
||||
% Compute steady state share of capital.
|
||||
ShareOfCapital=M_.params(4)/(M_.params(4)+(1-M_.params(4))*Labour_per_unit_of_Capital^M_.params(5));
|
||||
|
||||
% Compute steady state of the endogenous variables.
|
||||
SteadyStateLabour=1/(1+Consumption_per_unit_of_Labour/((1-M_.params(4))*M_.params(2)/(1-M_.params(2))*Output_per_unit_of_Labour^(1-M_.params(5))));
|
||||
SteadyStateConsumption=Consumption_per_unit_of_Labour*SteadyStateLabour;
|
||||
SteadyStateCapital=SteadyStateLabour/Labour_per_unit_of_Capital;
|
||||
SteadyStateOutput=Output_per_unit_of_Capital*SteadyStateCapital;
|
||||
|
||||
% Fill returned argument ys with steady state values.
|
||||
ys(2)=SteadyStateOutput;
|
||||
ys(4)=SteadyStateConsumption;
|
||||
ys(1)=SteadyStateCapital;
|
||||
ys(3)=SteadyStateLabour;
|
||||
ys(5)=M_.params(8);
|
||||
ys(6)=0;
|
Loading…
Reference in New Issue