$TITLE Dynamic Equilibrium Unemployment MPSGE Version

$ontext
This program defines the MPSGE version of the program 
that appears in Appendix B of:

E.J. Balistreri (2002) "Operationalizing equilibrium 
unemployment: a general equilibrium external economies 
approach," Journal of Economics Dynamics and Control
23/3: 347-374.

Edward J. Balistreri
Research Division
U.S. International Trade Commission
ebalistreri@usitc.gov
$offtext

*------------Original Social Accounts--------------*
Parameter
	y0	Benchmark Gross Output,
	ks0	Benchmark Capital Payments,
	ls0	Benchmark Labor Payments,
	i0	Benchmark Savings,
	c0	Benchmark Consumption;

y0	= 200;
ks0	=  50;
ls0	= 150;
i0	=  35;
c0	= 165;

*----------Setup the Dynamic Calibration-----------*
Set	T		Time Periods	/2000*2030/
	Tfirst(T)	First Period	/2000/
	Tlast(T)	Terminal Period /2030/;

Alias (T,TT,TTT);

Scalars
	r	Rate of Interest
	g	Growth Rate		/0.02/,
	d	Depreciation Rate	/0.07/;

Parameter
	k0	Benchmark Capital Stock,
	rk0	Benchmark Return on a Unit of K
	pk0	Benchmark Price of a Unit of K
	qref(T) Growth Path for Quantities
	pref(T) Present Value Price Paths;

* 1) Solve for the value of the initial Capital Stock:
* Investment must cover growth and depreciation.
* i0 = k0*(1+g) - k0*(1+d)	solve for k0

k0	= i0/(g+d);

* 2) Solve for the return to a unit of Capital

rk0	= ks0/k0;

* 3) Solve for the interest rate 

r	= (rk0 - d)/(1 + rk0 - d);

* 4) Find the price of a unit of Benchmark Capital

pk0	= 1/(1-r);

* 5) Set the steady-state Reference Paths

qref(t)	=	(1+g)**(ord(t)-1);
pref(t) =	(1-r)**(ord(t)-1);

Display k0,rk0,r,pk0,qref,pref;

*-----------Setup Equilibrium Unemployment---------*

Parameter 
	lvs	Leisures Value Share,
	sig	Exponent on LS in externality,	
	eta	Exponent on U in externality,
	u0	Benchmark Unemployment Rate,
	trn	Labor Turnover Rate,
	lsrv(T)	Labor Survival Share,
	nvl(T)	New Vintage Labor Supply,
	lsrv0	Initial Survival Portion,
	wref	Benchmark reservation wage
	s0	Benchmark leisure;

sig	= 0.5;
eta	= 0.1;  
u0	= 0.10;
lvs	= 0.2;
trn	= 0.2;
lsrv0	= 1-(u0+trn);
lsrv(T)	= lsrv0*((1 - trn)**(ord(T)-1));
nvl(T)	= (ls0*(((1/(1-lvs))-u0)*qref(T)
		/(1-u0)-lsrv(T)));
wref	= 1/(1-u0);
s0	= (ls0*(lvs/(1-lvs)));

Display lsrv;
*------------------Tax Experiments-----------------*

Parameters
	kit(T)	Capital Input Tax,
	prt(T)	Payroll TAX;

kit(T)=0;prt(T)=0;

*-------------------MPS/GE Model-------------------*

$ONTEXT

$MODEL:DYN2

$Sectors:
	W	! Welfare
	Y(T)	! Production
	I(T)	! Investment
	K(T)	! Capital Stock
	C(T)	! Consumption Index
	LS(T)	! Labor Supply Activity 

$Commodities:
	PW	! Price index on Welfare
	PY(T)	! Price index on output
	PC(T)	! Price index on consumption
	RK(T)	! Present Value Return to capital
	PL(T)	! Present Value Return to labor
	WAGE(T)	! Present Value Wage Received
	PK(T)	! Price index on Capital
	PKT	! Price of Terminal Capital

$Consumers:
	RA	! Representative agent

$Auxiliary:
	TCAP	! Terminal Capital Demand
	E(T)	! Employment Index Benchmark is (1-u0)*qref
	NVE(T)	! New Vintage Employment
	U(T)	! Unemployment Rate
	W_ADJ(T)! Wage Adjustment
	L_ADJ(T)! Labor Adjustment

$PROD:Y(T) s:1
	O:PY(T)		Q:y0
	I:RK(T)		Q:ks0			A:RA T:kit(T)
	I:WAGE(T)	Q:(ls0*(1-u0))	P:wref	A:RA T:prt(T)

$PROD:LS(T) 
	O:WAGE(T)	Q:ls0  A:RA N:W_ADJ(T) M:-1
	I:PL(T)		Q:ls0

$PROD:I(T)
	O:PKT$Tlast(T)	Q:i0
	O:PK(T+1)	Q:i0
	I:PY(T)		Q:i0

$PROD:K(T)
	O:PKT$Tlast(T)	Q:(k0*(1-d))
	O:PK(T+1)	Q:(k0*(1-d))
	O:RK(T)		Q:ks0
	I:PK(T)		Q:k0

$PROD:C(T) s:0.5
	O:PC(T)		Q:(c0+s0)
	I:PY(T)		Q:c0
	I:PL(T)		Q:s0

$REPORT:
	V:CONS(T)	I:PY(T)	PROD:C(T)

$PROD:W s:0.5
	O:PW		Q:(sum(T,(c0+s0)*qref(T)*pref(T)))
	I:PC(T)		Q:((c0+s0)*qref(T)) P:pref(T)

$Demand:RA
	D:PW		Q:(sum(T,(c0+s0)*qref(T)*pref(T)))
	E:PK(Tfirst)	Q:k0
*Labor used in production
	E:PL(T)		Q:(ls0*qref(T))
*Labor used for Leisure
	E:PL(T)		Q:(s0*qref(T))
	E:WAGE(T)	Q:(ls0*qref(T))	 R:L_ADJ(T)
	E:PL(T)		Q:(-lsrv(T)*ls0)
	E:WAGE(T)	Q:( lsrv(T)*ls0)
	E:PKT		Q:(-1)		R:TCAP

$Constraint:TCAP
	sum(T$Tlast(T+1),C(T)*I(T+1) - I(T)*C(T+1)) =E= 0;

$Constraint:E(T)
	E(T) =e= (LS(T)+lsrv(T)+L_ADJ(T)*qref(T));

$Constraint:NVE(T)
	NVE(T) =e= (LS(T)+L_ADJ(T)*qref(T));

$Constraint:U(T)
	U(T) =e= 1-(LS(T)+L_ADJ(T)*qref(T)+lsrv(T))
	         /(LS(T)+lsrv(T));

$Constraint:L_ADJ(T)
	L_ADJ(T)*(qref(T)-lsrv(T)) =e=	
	LS(T)*
	(1-u0)*((NVE(T)/((1-u0)*qref(T)-lsrv(T)))**(sig)
	      * (u(T)/    u0          )**(eta))
	-LS(T);

$Constraint:W_ADJ(T)
	W_ADJ(T)*LS(T) =e= L_ADJ(T)*(qref(T)-lsrv(T));

$offtext
$sysinclude mpsgeset dyn2

*-Set Steady State Level Values and Replicate Benchmark-*

*	Activities grow at Q-ref
Y.L(T)=qref(T);I.L(T)=qref(T);K.L(T)=qref(T);C.L(T)=qref(T);

*	Prices decline at P-ref
PY.L(T)=pref(T);PC.L(T)  =pref(T);RK.L(T)=pref(T);
PL.L(T)=pref(T);WAGE.L(T)=pref(T)/(1-u0);PK.L(T)=pref(T)*pk0;

*	Terminal levels
PKT.L= (1-R)*sum(Tlast, PK.L(Tlast));
TCAP.L = sum(Tlast, i0*qref(Tlast)+k0*(1-d)*qref(Tlast));

*	Labor Supply is Q-ref less Survival Share
LS.l(T)=qref(T)-lsrv(T);

*	Free the bounds on Auxiliaries
W_ADJ.LO(T)=-INF;L_ADJ.LO(T)=-INF;W_ADJ.UP(T)=0;L_ADJ.UP(T)=0;

*	Benchmark equilibrium unemployment
E.l(T)=(1-u0)*qref(T);U.L(T)=u0;W_ADJ.L(T)=-u0;L_ADJ.L(T)=-u0;
NVE.l(T)=(1-u0)*qref(T)-lsrv(T);

dyn2.ITERLIM = 0;
$include dyn2.gen
solve dyn2 using mcp;