clear;clc;
para_0=0.68;
x(1)=para_0;
target_moments=3.71;
cp=fsolve(@moment_distance,para_0)
function V = moment_distance(x)
if exist('para.mat','file')
    delete para.mat
end
eta=x(1);
save para eta;
dynare zzz;
V(1)=(oo_.var(1,1))-3.71^2;
end

% [calibrated_params FFinal] = fsolve(@(x) moment_distance(x, target_moments, M, oo, var_list), param_0, options);
% function V = moment_distance(x,target_moments)
%     dynare('model.mod')
%     param = x(1);
%     [info, oo_, options_] = stoch_simul(M_, options_, oo_, var_list_);
%     % Say model target moment is located at oo_.var(1,1)
%     V(1) = target_moments(1) - oo_.var(1,1);
% end