# A simple question on how to put equations in Dynare

Hi,

I am new of Dynare and I have a doubt that is disturbing me in the last days I am trying to write a RBC model and I was wondering which are the right equations to put in.

My question is simple, often we derive first order conditions from a Lagrangian and then we manipulate it to give economic meaning. As an example Lagrangian multipliers (lambda, mu;…) normally disappear in order to have “nice” Euler equations. Now my question is, when a model is complex, do I always need to rearrange the FOC or can I put it directly in dynare? I saw many paper that declare in the appendix only the FOC as they are after the maximization, and i was wondering if I can use these equations directly in dynare to replicate a model. Moreover i saw paper in which the log linearization is done on the “non rearranged” form and still I was thinking if it is possible to use it to write a linear model in dynare.

Thanks!

1 Like

Hi,
firstly, F.O.C are not enough. Additionally you need incorporate the equilibrium conditions (feasibility constraint) and also you need to define the exogenous stochastic processes (shocks or endowment/money or any other markov process).
For different versions of them (linear or loglinear) I recommend you “Stochastic simulations with DYNARE. A practical guide” by Collard et al. For me it was a very useful guide.

I want to add that you do not need to substitute out additional variables like the Langrange multiplier. Dynare will take their relationship to other variables into account and solve for them as for any other variable.
You can enter the equilibrium conditions directly into Dynare. You only need to consider that Dynare typically perform linearizations and not log-linearizations. See section “4.4 Linearization vs. Log-linearization” of Pfeifer (2013): “A Guide to Specifying Observation Equations for the Estimation of DSGE Models” on my homepage.

Thank you very much! I know that FOCs are not enough but I was wondering if was necessary to perform the substitution that we normally find on macroeconomics textbook after the FOCs (euler equation, etc.). Thank you again, I will read the guides you suggested me.