Positive Hessian when starting non-linear estimation

Dear All,

I am trying to estimate a non-linear small new-Keynesian model using cubature Kalman filter.

I have written a code and tested it with linear estimation. It went through.
When moving to non-linear filters, the following message pops up.
(measurement errors have been included in the block for prior definition)

What would you do to overecome it?

Here, please, find attached code, data and results for the linear and non-linear case.

NK_test.zip (824.1 KB)

Many thanks in advance.

Error using chol
Matrix must be positive definite.

Error in nonlinear_kalman_filter (line 116)
StateVectorVarianceSquareRoot =

Error in non_linear_dsge_likelihood (line 334)

Error in initial_estimation_checks (line 137)
    [fval,info] =
Error in dynare_estimation_1 (line 165)
    oo_ =
Error in dynare_estimation (line 105)

Error in NKt_estYPIR (line 301)

Error in dynare (line 235)
evalin('base',fname) ;

Just as additional information, I have also tried using the following options:


New option nonlinear_filter_initialization for the estimation command. Controls the initial covariance matrix of the state variables in nonlinear filters. Default value is 1, the initial covariance matrix is the unconditional covariance matrix of the reduced form solution of the model approximated at order one. If the model has unit roots, the user must set this option equal to 3, the initial covariance matrix is then an identity matrix.


Best regards, DB

I would carefully check identification. I get

    [sigma_g,Sg_STEADY] are PAIRWISE collinear (with tol = 1.e-10) !

Also, some of the likelihood graphs at the mode are extremely flat, suggesting no identification or weak identification. I don’t see how you can estimate A_STEADY