# How Dynare computes IRFs

In Dynare, at order 1, we don't need to care about the possible values of shocks except for the impulsion, because in a linear model the average effect of symmetric shocks is always 0. This is not true for orders of approximation 2 and above. In that case, we compute the IRF for shock e in the following manner:

- draw a series of random shocks for 140 periods
- Perform simulation Y1
- Add one standard deviation to the simulated series for shock e in period 101
- Perform simuluation Y2
- The IRF for this experiment is equal to Y2-Y1
- Results obtained in 5) is affected by idiosyncratic shocks other than the one impulse in period 101. In order to average over the effect of these idiosyncratic shocks, we perform 50 replications of steps 1) to 5) and report the average.
- Initial 100 warming periods is the default value of option DROP
- 40 periods for the IRF is the default value of option IRF
- 50 replications is the default value of option REPLIC

By following this procedure, we average over the influence of the state point at which the impulse occurs and of future shocks in periods after the impulse. So, we report indeed an average IRF.