## Homeworks for Econ 8185 Quantitative Macro, Fall of 2010

There may be preliminary versions of future homeworks in this page. I may change them until the day I state in the course homepage that the relevant homework batch is ready.
• First Homework batch. Due Tuesday September 15th. Name them sept_15_h1, sept_15_h2 and so on.
1. Data manipulation.

1.A Fetch and plot US quarterly GDP Investment plus durables plus net exports, non-durables plus services, and aggregate hours both from CPS and from the firm survey (see Cooley chapter 1, page 30). Store it in pdf, eps, and emf or wmf formats.

1.B HP filter and plot US quarterly (log) GDP. Store it in postcript or pdf. Compute the same table as in the Cooley book for those 4 variables using data up to 2003:4 or later.

1.C Calculate a linear trend and decompose log GDP in the linear trend the hp trend and the hp residual.

1.D Plot the growth rates together with the hp residual and comment the differences.

1.E Compute a VAR of those 4 variables and plot the impulse responses. Make sure that you explicitly state what are the identifying assumptions that you make.

2. Interpolation.

Write a routine that linearly interpolates. Apply it by storing the value of exp (x) between 0 and 1. in intervals of .1 and assessing the value by interpolation in intervals of .05. Plot the function and what results from using approximation.

3. Solving Equations of one unknown.

(Parts of Homework 1 of Chapter 5 of Judd's book.) Solve sin 2

x- 2x=0 using bisection between x 0 =-5 and x 1 =5 (If this interval is a bad one change it).

4. Production Function manipulation.

Compute labor factor shares with a CES production function

Y=[ q K r +(1- q )N r )] 1/ r

when K=N=1, and K=2, N=1. Are they the same?

What about with Cobb-Douglas ( r =1).

Note that Labor share = w*N/Y, and that under competition w=(dY/dN).

5. Using symbolic software to obtain derivatives.

Write in two equations in the capital-labor ratio and total labor the steady state conditions of the growth model with log utility and constant Frisch elasticity of labor (look up what this means if necessary). Use the CES production function with depreciation. Use mathematica or maple or matlab with the symbolic toolbox or even sciword if this does the job.

• Second Homework batch. Business Cycles Questions. Due Wed September 22th.
1. Computation of the Solow Residual.

6.A Use NIPA and the logic of the imputation of income to either labor or capital found in Cooley and Prescott (1996) to compute an updated series of the Solow residual.

6.B Estimate a univariate process for the Solow residual. Make sure that you argue forcefully for your specification.

6.C Compute a bivariate VAR with the Solow residual and output and a trivariate VAR with the Solow residual, output and hours worked.

• Third Homework batch. Business Cycles Questions. Due Wed September 29.
1. Using a growth model suitable to measure the contribution of productivity shocks as represented by the Solow residual to movements in output and hours worked between 1954-2010.

7.B Solve for the steady state. Be lazy and use software to get the derivatives and dynare to get the steady state.

7.C Answer the question using dynare.

7.D Reassess your answer with data since 82. Get labor data from Manovskii, here and described here of labor in the CPS and reestimate your answer.

7.E Redo your answer posing TFP shocks and shocks to the relative price of investment.

• Fourth Homework batch. Data Sets Questions. Due Wed October 6.
1. Read data sets: I. The Cross-Section data set Problem. Denote by i,g your own age plus 12 and your gender. Now take the CPS or the CEX and find out the average number of hours worked by people of type g, i plus/minus 2. Sort this group into quartiles by education, and report the average time worked and the average wage for those that work, the average time worked per person, the fraction that work, the fraction married, the number of children among those married and the number of children per parent. This for the years 1980 and the latest available. Report an additional feature of this group that you may find interesting.

As an added bonus go back to 1970 through 1979.

2. Read data sets: II. The Panel-Data data sets question. Use now either the NLSY or the PSID. Get again your own group of people the {i,g}. See how many of them were married in the initial period and 10 years later and build a transition matrix with the number of children in the household. Again separate them by education groups. Four this time. Report an additional feature of this group that you may find interesting.

3. Read data sets: III. A new data Sets. The IPUM or Census Recent news reported that most Americans now do not live in traditional families. Using the most recent wave of Census data (find out what this is) the proportions of people in age-sex group living in each type of household. Find out what the census uses as partitions for types of households. Report an additional feature that you may find interesting.

• Fifth Homework batch. More Business Cycles and Global Approximation. Due Wed Oct 13.
1. Comparison of calibration and estimation.

8.A Rewrite (only if necessary) your answers to 7.C and 7.D under the light of the Oct 6th class.

8.B Pose a version of the model with the same steady state calibration than in Question 7 but now estimate processes for three independent shocks to hours worked in the utility to patience and to productivity by ML (or by Bayesian methods).

8.C Redo the estimation adding labor share and the Frisch elasticity of labor to the parameters that govern the three shocks (there are 6 of those as we assume them to be independent).

8.D Compare the answers obtained in 8.A, 8.B, and 8.C.

1. Global approximation.

9.A Take a deterministic version of the growth model without leisure. Find the steady state and construct a 21 point grid from half to two times the steady state of capital. Do it in logs.

9.B Write a f90 or f95 code that computes a piecewise linear approximation to the decision rule of capital for the optimal capital accumulation function. Use collocation (or the Dirac measures at the grid points) to weigh the errors. Plot it.

9.C Compare it with one that results from doing the same approximation with only 7 grid points over the same range. Was it worth to go from 7 to 21 grid points?

• Sixth Homework batch. The Aiyagari Economy Due Wed Oct 27.
1. The household problem

10.A Write fortran (or C, but better f95) code for the problem that a household solves in an Aiyagari economy with leisure and a Markov shock to earnings. Use the calibration of say my paper with Ana Casta~neda and Javier Diaz-Gimenez (or another is you prefer it). Make sure that in your parameterization of the problem you choose an arbitrary value for the wage and a value for the interest rate that is small (smaller than (1/beta)-1). Use either Chebyshev or piecewise linear in the Euler equations or splines in the value functions. Use only proportional labor taxes that pay for social security transfers. Use arbitrary values for this.

10.B Compute the steady state of this economy. Use both an approximation to the cdf. And a huge sample.

10.C Compute and plot the Lorenz curve for earnings.

• Seventh Homework batch. General equilibrium issues in the Aiyagari Economy Due Wed Nov 3.
1. General equilibrium, Calibration and Transition.

11.A Compute the interest rate and wage that constitute a stationary equilibrium of a close economy.

11.B Set risk aversion to 2, the Frisch elasticity of labor to .7, labor share to 2/3, and depreciation to .1. Then find parameters for the discount rate, the coefficient of labor in the utility and the constant that multiplies the production funtion that yield a closed economy equilibrium with a wealth to output ratio of 4, a value of output of 1 and average fraction of time working of .3.

• Eigth Homework batch. Transition in a Growth Economy Due Wed Nov 3.
1. General equilibrium, Calibration and Transition.

12.A Take your favorite version of the neclassical growth model. Calculate its steady state.

12.B Now suppose that by surprise, TFP doubles. Compute the new steady state and the transition from the old to the new, assuming that it has completed in 200 periods. Compute such transition three ways and specify how long it takes to solve it each way. The first way is a system of 200 equations and unknowns, the second by guessing first period capital and hoping that the system gets the right capital in period 201, and by guessing capital in the period 200 hoping that if you moved backward you obtain the right initial capital.