Recovering oo_.dr.ghx in third-order approximation

Dear Sébastien,

this is not completely true and has been discussed in [Bug in k_order_solver? ghx changes from order 1/2 to 3). The uncertainty corrections at second order result from the second partial derivative of the policy function w.r.t. the perturbation parameter. This term is saved into g_0 as it does not depend on the state variable. However, at third order, you get an additional term from differentiating twice w.r.t. to the perturbation parameter and once w.r.t. the state variables. This term, which only appears at third order is then added by Dynare to g_1 as it is linear in the state variable. Similary, if you would use Dynare++ to go to fourth order, there is a correction term added to g_2 (of course in addition to the lower order correction terms already contained in g_0 and g_1).

Back to the original question, I am not aware of a way to trace out this correction term without running Dynare twice at different orders and computing the difference.