# Problems with changing time lag

thanks for jpfeifer’s help and after adjust parameters and some linear equations,the machine can run the dynare code.however i am puzzled that the code works only after some linear equations changing their time lag,e.x changing the original equation"phai*(Q(-1)+ku-nu)-S(-1) = 0;" to “phai*(Q+ku(+1)-nu(+1))-S = 0;”,i think the two equations should be the same but the fact is only the second one can make dyanre code work. could somebody tell me the reason for it?
the original(BGGNPC3) and adjusted(BGGNPC4) mod files are as follows.
BGGNPC4.mod (1.63 KB)
BGGNPC3.mod (1.51 KB)

I am not sure what you mean with “make Dynare run”, but I guess it relates to eigenvalues. I am not 100% sure, what’s the answer to your question, but I have a guess. Although the both equations look similar as one is the other shifted by one time lag, there is an important difference, considering that we are taking expectations conditional on time t. The equation shifted by one lag is then deterministic as all variables involved are known at time t when we take expectations (similar to a law of motion for capital, where k_t+1 is already predetermined at time t). In contrast, the second equation involves ku(+1) and nu(+1) which are not known at time t.

1 Like

This is correct. Dynare puts an implicit conditional expectation at time t in front of an equation member containing variables with leads. So the first equation is indeed

phai*(Q_(t-1)+ku_t-nu_t)-S_(t-1) = 0

but the second one is

E_t{phai*(Q_t+ku_(t+1)-nu_(t+1))-S_t} = 0

and is not equivalent to the first one.

Best

Michel

thanks for both of you,now i know the difference between the two equations,thank you