Understanding Deterministic (Perfect Foresight) Simulations in Dynare
Channel: Willi Mutschler
Date: 2023-05-14

Slides and Codes: https://mutschler.eu/dynare/deterministic/perfect-foresight-algorithm/

We cover deterministic simulations in DSGE models also known as perfect foresight simulations and how one can do this in Dynare.
1) We will cover very briefly the intuition behind this method.
2) We are going to illustrate several scenarios which you can analyze using a two-country New Keynesian DSGE model as an example.
3) We will go through the Dynare specific commands that you need know.
4) We will go under the hood and derive the Newton type algorithm that Dynare uses and discuss some numerical issues we need to deal with.
5) To make sure that we really understand the algorithm and the way Dynare computes deterministic simulations, we are going to re-implement it manually in MATLAB and then see that the results are exactly the same.


**Timestamps**
00:09 - Introduction
01:15 - Recap Deterministic Simulations under Perfect Foresight
05:08 - Example Two-Country NK model with ZLB: overview
08:15 - Example Two-Country NK model with ZLB: Temporary Monetary Policy Shock
11:56 - Example Two-Country NK model with ZLB: Pre-Announced Temporary Monetary Policy Shock
13:42 - Example Two-Country NK model with ZLB: Permanent Increase Inflation Target (Surprise)
15:39 - Example Two-Country NK model with ZLB: Pre-Announced Permanent Increase in future tax rates
18:45 - Dynare Specifics: Commands and Under the Hood
21:59 - General DSGE Framework under Perfect Foresight
23:50 - Two-Boundary Value Problem
25:25 - Newton Method
27:21 - The Perfect Foresight Algorithm
29:14 - Controlling Newton Algorithm in Dynare
30:04 - Initial Guess for Newton Algorithm
31:13 - Infinite Horizon Problems
32:40 - Jacobian
39:14 - Re-Implementation of Perfect Foresight Algorithm in MATLAB
54:47 - Outro and References