function [ys, params, check] = KN_steadystate(ys, exo, M_, options_)

for i = 1:M_.param_nbr
    params.(M_.param_names{i}) = M_.params(i);
    eval([M_.param_names{i} '= M_.params(i);']) ;
end
%B = 0;
eta=eta_ss;
N = N_ss;
alpha = aalpha;
beta = betta;
gamma=ggamma;
Pm=Pm_ss;
Omega = Omega_ss;
R = R_ss;
I = delta*K_ss;
Y = Y_ss;
Rk =Rk_ss;
Bb =Bb_ss;
Sb= Sb_ss;
phi=phi_ss;
C=C_ss;
mu = mu_ss;
S = K_ss;
Sp = K_ss;
Q = 1;
Lambda = Lambda_ss;
D = 1;
lambda = lambda_ss;
Rb=Rb_ss;
exp_prem = log(Rk_ss) - log(R_ss);
exp_prem_g = log(Rb_ss) - log(R_ss);
Bh = B-Bb_ss;
nu = nu_ss;
q = Xi/(Rb-varrho);
G = g_ss*Y;
Ne = N_ss-omega_ss;
Z = Z_ss;
X = 1;
ir = R;
infl= 0;
Bg= 0;
omega= omega_ss;
size_QE=  0;
xi= 0;
CmhCm1 =  (1-hh)*C;
Loss  = -log(CmhCm1)+chi*L_ss^(1+varphi)/(1+varphi);
F   =  F_ss;
H   =  H_ss;
Dir= 0;
inflstar= 0;
lambda_star=  1-nu/(theta*phi);
credit_GDP=Q*Sb_ss/(4*Y) ;
phi_acc = phi;
DEP = DEP_ss;
Ym = Y;
shk_B = 0;
shk_omega= 0;
ksi= 0;
shk_Gamma= 0;
shk_beta= 0;
shk_nu= 0;
zlb=0;
%epsilon = epsilon_ss;
tau = tau_ss ;
MU=1;
TFP = 1;
g=g_ss;
junk=0;
X=1/Pm_ss;
qf= Xif/(R - varrho);
YTMf=(Xif/qf + varrho);
YTM= (Xi/q + varrho);
Prem_YTM=YTM-YTMf;
K=K_ss;
L=L_ss;
xi=xi_ss;
nu=nu_ss;
Ne=N_ss - omega_ss;
F = F_ss;
H=H_ss;
Q = Q_ss;
MU=MU_ss;


Sb = Sb_ss;
Sh= Sh_ss;
Sb_run=Sb_ss;
Sb_lag=Sb_ss;
Sh_run=Sh_ss;
Sh_lag=Sh_ss;

Bb = Bb_ss;
Bh= Bh_ss;
Bb_run=Bb_ss;
Bb_lag=Bb_ss;
Bh_run=Bh_ss;
Bh_lag=Bh_ss;

DEP_lag=DEP_ss;
N_run_prices=N_ss;

N_lag=N_ss;
run_ind=0;
Run=0;
R_lag=R_ss;

D_lag = D_ss;
q_lag = Q_ss;
Q_lag = Q_ss;
phi_lag = phi;
N_run=N_ss;

for i = 1:M_.orig_endo_nbr
        ys(i) = eval(M_.endo_names{i});
end

updt = {'Y' 'DEP', 'q', 'Q'} ;

for i = 1 : size(updt, 2)
    
    id = strcmp(M_.param_names, updt{i} + "_ss") ;
    M_.params(id) = eval(updt{i}) ;
    
end


params = M_.params;

check = 0;

end



