Page 1 of 1

Blanchard-Kahn conditions: indeterminacy

PostPosted: Sun Nov 08, 2015 12:53 am
by jimmyk
I'm running a relatively simple 'q' investment model, with an AR(1) shock in the log of TFP. The supply side is a bit complicated so there are 12 equations, but capital is the only endogenous state variable. I solve for the steady state, but then doing a stochastic simulation I get

Error using print_info (line 45)
Blanchard Kahn conditions are not satisfied: indeterminacy

Error in stoch_simul (line 98)
print_info(info, options_.noprint, options_);

Error in investment_Nov2015 (line 197)
info = stoch_simul(var_list_);

Error in dynare (line 180)
evalin('base',fname) ;

After looking at some related posts here, I tried running model_diagnostics(M_,options_,oo_), but that didn't return anything. I am relatively inexperienced with Dynare, so I can't rule out some really dumb mistake (hopefully not in the economics), but hoping for some insight. I've attached the code as a plain text file.

Re: Blanchard-Kahn conditions: indeterminacy

PostPosted: Sun Nov 08, 2015 9:46 am
by jpfeifer
It seems you are violating Dyare's timing convention for predetermined states like capital (see the manual). Try using
Code: Select all
predetermined_variables k;

Re: Blanchard-Kahn conditions: indeterminacy

PostPosted: Sun Nov 08, 2015 12:21 pm
by jimmyk
Thanks, that worked! Somehow had missed that in the manual. :oops:

Re: Blanchard-Kahn conditions: indeterminacy

PostPosted: Mon Nov 16, 2015 10:07 pm
by jimmyk
So I have a followup question, which may be more mathematical than Dynare, and since this thread is a couple weeks old I'm not sure if this will be seen, in which case I'll create a new topic. I am surprised that changing the timing affects the dynamic stability of the model. Specifically, I tried making a control variable pre-determined (either by using the "predetermined variables" statement or by changing the timing in the model) and I got the error

Error using print_info (line 42)
Blanchard Kahn conditions are not satisfied: no stable equilibrium

The intent of making the control variable pre-determined is simply to have it respond (essentially) to the expected value of the shock rather than to the actual realization of the shock. That would obviously change the IRF, but why would turn the model into one that has "no stable equilibrium"?

I suppose this is related to the original question, but I didn't care so much because changing the timing solved the problem. In this case a change in timing created a new problem. Thanks in advance.

Re: Blanchard-Kahn conditions: indeterminacy

PostPosted: Wed Nov 18, 2015 10:32 am
by jpfeifer
Your model needs as many stable roots as predetermined variables to have a saddle path solution. When you alter the timing, this balance gets destroyed. You will not be on the stable manifold anymore. The reason has to do with difference equations. See the attached slides from my lecture.

Re: Blanchard-Kahn conditions: indeterminacy

PostPosted: Wed Nov 18, 2015 8:36 pm
by jimmyk
Thanks, but I think I am talking about something slightly different. I am not changing a control variable into a state variable, just changing the information set. In a LQ model, for example, one can get a solution for the control variable as a function of the state variables and the current shock. If the control has to be chosen before the current shock is realized, the solution is essentially the same except the realized value of the shock is replaced by its expectation. So in the attached textbook LQ investment model, instead of I = (1/b)q as the solution for I, it would be I = (1/b)E_{t-1}(q), but the fundamental properties of the model are preserved. Somehow changing the timing in the dynare program does something different, though. (As I said, I tried both the "predetermined" statement and directly changing the timing in the model.) Thanks again.

Re: Blanchard-Kahn conditions: indeterminacy

PostPosted: Thu Nov 19, 2015 7:34 am
by jpfeifer
You seem to be confusing something. If a variable has to be chosen before the shock realizes, it becomes predetermined. There are cases like the one you attached where this change in timing does not sufficiently change the eigenvalues to change the uniqueness/determinacy properties. For example in the New Keynesian model, you often can have the central bank reacting to expected inflation instead of realized inflation without changing the determinacy. But this is not a general property of any model. For each case you have to check whether making a variable predetermined is problematic.

Re: Blanchard-Kahn conditions: indeterminacy

PostPosted: Thu Nov 19, 2015 4:47 pm
by jimmyk
I appreciate your responses, so I don't wish to seem argumentative, but I don't think this is not confusion on my part. It's not just that the eigenvalues don't change "sufficiently" in some models. In LQ models like the one I attached they do not change at all if the model timing changes, due to certainty equivalence. That is a mathematical fact. Yet if I change the timing in dynare, even for the simple LQ model such as the one I attached in my last post, I get the message

Error using print_info (line 42)
Blanchard Kahn conditions are not satisfied: no stable equilibrium

So I think this is an issue about dynare syntax (about which I will happily admit I may be confused), not about the mathematics of difference equations. I am hoping there is some trick that allows me to change the timing of what information the decision-maker has, that does not result in the above error.

Specifically, In the simple LQ model, the equations are

a*Y - k - q + bet*q(+1) = 0;
b*I - q = 0;
ln(Y)=rho*ln(Y(-1))+u;
k = k(-1)*(1-del)+I;

where u is the shock. This model solves correctly in dynare. My question is this: How would I code it to make "I" chosen before u and q are known? Declaring I predetermined or changing the timing in the equations results in the "no stable equilibrium" error, even though as I say the eigenvalues are unchanged. Thank you.

Re: Blanchard-Kahn conditions: indeterminacy

PostPosted: Fri Nov 20, 2015 7:29 am
by jpfeifer
Maybe I do not understand your question/the setup of your problem, but it is almost impossible that the eigenvalues do not change. After linearization, you can represent any problem that can be solved with stoch_simul in the generic matrix form
Code: Select all
AE_t{y_t+1}=By_t

By changing the timing in Dynare, you moved one entry of the left-hand side to the right-hand side. This will in general affect the eigenvalues of this linear difference equation. This has nothing to do with certainty equivalence.

Re: Blanchard-Kahn conditions: indeterminacy

PostPosted: Fri Nov 20, 2015 8:07 pm
by jimmyk
Thanks, I think we are talking about different things. I realize that for the simple LQ model I posted on 11/18, what I want is easy: Just replace

b*I - q = 0

with

b*I - EXPECTATION(-1)(q) = 0.

For some reason it wasn't quite so simple in the more complicated model I'm actually working with, but I think I understand the syntax better now and will take a stab at figuring it out. Sorry for any confusion and thanks for your efforts.

Re: Blanchard-Kahn conditions: indeterminacy

PostPosted: Sat Nov 21, 2015 2:41 pm
by jpfeifer
I think the most important thing is that you understand the timing structure in your model and how it maps into the typical timing convention in recursive linear solutions. What you outline in your solution is to introduce an auxiliary variable of the type often occuring in e.g. models with Epstein-Zin preferences.