Commit 133e51e6 authored by Stéphane Adjemian's avatar Stéphane Adjemian
Browse files

Changed the test files conformably to the latest commits related to the...

Changed the test files conformably to the latest commits related to the (stochastic) extended path approach.
parent 87f4dad5
......@@ -15,7 +15,7 @@ sigma2 = 0.0001;
external_function(name=mean_preserving_spread);
model(block,bytecode);
model;
// Eq. n°1:
efficiency = rho*efficiency(-1) + EfficiencyInnovation;
......
......@@ -11,8 +11,8 @@ sigma = -0.06;
gamma1 = 1.5;
gamma2 = 0.5;
model(block,bytecode,cutoff=0);
y = delta * y(-1) + (1-delta)*y(+1)+sigma *(r - pie(+1)) + e_y;
model(use_dll);
y = delta * y(-1) + (1-delta)*y(+1)+sigma *(r - pie(+1)) + e_y;
pie = alpha * pie(-1) + (1-alpha) * pie(+1) + kappa*y + e_pie;
r = gamma1*pie+gamma2*y;
end;
......
......@@ -21,7 +21,7 @@ sigma2 = 0.0001;
external_function(name=mean_preserving_spread);
model(block,bytecode);
model(use_dll);
// Eq. n°1:
efficiency = rho*efficiency(-1) + EfficiencyInnovation;
......
@#define extended_path_version = 0
@#define extended_path_version = 1
var Capital, Output, Labour, Consumption, Efficiency, efficiency, ExpectedTerm, LM, LagrangeMultiplier;
var Capital, Output, Labour, Consumption, Investment, Efficiency, efficiency, ExpectedTerm;
varexo EfficiencyInnovation;
......@@ -28,7 +28,7 @@ sigma2 = 0.001;
external_function(name=mean_preserving_spread);
model(block,bytecode,cutoff=0);
model(use_dll);
// Eq. n°1:
efficiency = rho*efficiency(-1) + EfficiencyInnovation;
......@@ -40,22 +40,19 @@ model(block,bytecode,cutoff=0);
Output = Efficiency*(alpha*(Capital(-1)^psi)+(1-alpha)*(Labour^psi))^(1/psi);
// Eq. n°4:
Capital = max(Output-Consumption + (1-delta)*Capital(-1),(1-delta)*Capital(-1));
Capital = max(Output-Consumption,0) + (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 - LagrangeMultiplier - ExpectedTerm(1);
ExpectedTerm = beta*((((Consumption^theta)*((1-Labour)^(1-theta)))^(1-tau))/Consumption)*(alpha*((Output/Capital(-1))^(1-psi))+1-delta);
// Eq. n°7:
(Capital==(1-delta)*Capital(-1))*(Output-Consumption) + (1-(Capital==(1-delta)*Capital(-1)))*LM = 0;
Investment = Capital - (1-delta)*Capital(-1);
// Eq. n°8:
(LM<0)*(LM+LagrangeMultiplier) + (1-(LM<0))*(LM-LagrangeMultiplier) = 0;
// Eq. n°9:
ExpectedTerm = beta*(((((Consumption^theta)*((1-Labour)^(1-theta)))^(1-tau))/Consumption)*(alpha*((Output/Capital(-1))^(1-psi))+(1-delta))-(1-delta)*LagrangeMultiplier);
// Eq. n°8: (Euler equation, to be skipped if investment is on its lower bound)
(Investment>0)*((((Consumption^theta)*((1-Labour)^(1-theta)))^(1-tau))/Consumption - ExpectedTerm(1)) + (1-(Investment>0))*(Output-Consumption);
end;
......@@ -98,7 +95,6 @@ end;
steady;
options_.maxit_ = 100;
options_.stack_solve_algo = 4;
simul(periods=4000);
......
......@@ -2,9 +2,9 @@ function [ys, info] = rbcii_steadystate(ys, exogenous)
% Steady state routine for rbc.mod (Business Cycle model with endogenous labour and CES production function)
% AUTHOR(S)
% AUTHOR(S)
% stephane DOT adjemian AT univ DASH lemans DOT fr
% frederic DOT karame AT univ DASH evry 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;
......@@ -16,9 +16,9 @@ function [ys, info] = rbcii_steadystate(ys, exogenous)
% 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.
......@@ -43,6 +43,7 @@ ys(1)=SteadyStateCapital;
ys(2)=SteadyStateOutput;
ys(3)=SteadyStateLabour;
ys(4)=SteadyStateConsumption;
ys(5)=M_.params(8);
ys(7)=M_.params(1)*((((SteadyStateConsumption^M_.params(2))*((1-SteadyStateLabour)^(1-M_.params(2))))^(1-M_.params(3)))/SteadyStateConsumption)* ...
ys(5)=ys(2)-ys(4);
ys(6)=M_.params(8);
ys(8)=M_.params(1)*((((SteadyStateConsumption^M_.params(2))*((1-SteadyStateLabour)^(1-M_.params(2))))^(1-M_.params(3)))/SteadyStateConsumption)* ...
(M_.params(4)*((SteadyStateOutput/SteadyStateCapital)^(1-M_.params(5)))+1-M_.params(6));
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment