Trouble solving Galì & Monacelli (2008)

Hi everyone!

I’m new to Dynare and I have a question regarding the Galì & Monacelli (2008) model on currency union. I saw an old post on the topic, but my issue seems a bit different.

I’m having trouble satisfying the Blanchard Kahn rank condition. I’m wondering if it’s a problem of unit root in the model. Since the model is based on the assumption of complete markets, it should not be the case (I think). I’m not interested in optimal policy. For now on, I’m just trying to run the model so I can add some new equations in it.

Is there a way to troubleshoot my mistake?

I attached a PDF with the equations and my .mod file.

Thanks a lot for your time,

Raphaël

g_m_2008_V1.mod (1.7 KB)
g_m_2008.pdf (371.2 KB)

What is the problem you are experiencing? I can run your file after commenting out the end of the commented out initval-block.

Thanks for your reply.

I realized that there is a typo in the file I sent. Sorry for that mistake. Basically, in the following file, the time subscript for inflation in the Euler equation is the right one. This change brings an error message about the rank condition of the Blanchard Kahn algorithm. I was wondering if there is a way to find out where it’s coming from.

Thanks a lot for your time,
Raphaël

g_m_2008_V2.mod (1.7 KB)

Could you please document your mod-file. Please add \LaTeX-names for the variables and add equation tags specifying to which equation in the paper the implemented equation corresponds. For an example, see e.g. https://github.com/JohannesPfeifer/DSGE_mod/blob/master/Gali_2015/Gali_2015_chapter_3.mod

Thanks for your answer Johannes Pfeifer,

I’ve document my previous .mod file based on your example. The new version is attached to this message.

Thanks a lot,
Raphaël

g_m_2008_V3.mod (4.5 KB)

A very minor point: when I run your Gali_2015_chapter_3 code under Dynare 4.5.4, the equation tags are not printed out by LaTex (via MiKTeX 2.9), even though they appear in the M_ structure of Dynare. The variable and parameter names come out OK, however. Have you had this problem?
Regards
Donihue

Did you use the write_equation_tags option?

Yes I did, as “write_latex_dynamic_model(write_equation_tags);”. All that comes out is “[name]”, not the actual name …

Further to my reply, it seems that for some reason the second column of M_equation_tags (which contains the word ‘nameimage’) is being picked up instead of the third column (which contains the actual equation name)

Which Dynare version are you using and where do you see a problem, i.e. what should I do to replicate your problem?

I am using Dynare 4.5.4

The part of your code which generates the LaTex output is

"stoch_simul(Tex,order = 1,irf=15,irf_plot_threshold=0) y_gap pi_ann y n w_real p i_ann r_real_ann m_nominal a;

//generate LaTeX-files with equations and parameterization
write_latex_dynamic_model(write_equation_tags);
write_latex_parameter_table;
write_latex_definitions;
collect_latex_files;"

As mentioned in my previous post, “M_equation_tags” contains three columns, of which the second is just the word ‘name’, which is what appears instead of the actual equation name in the pdf file produced by MiKTeX 2.9 following the completion of the Dynare programme

@HoutanBastani I can confirm that in 4.5.4 the output of

write_latex_dynamic_model(write_equation_tags);

is just name, while it is correct in master. Can you pinpoint the commit that fixed the issue?

Hi everyone, I’m using Dynare 4.5.6 and I faced the same problem with the option write_equation_tags in the command write_latex_dynamic_model. Has someone solved it?

Thanks for your help,

Filippo

Can you provide me with the mod-file?