function [LLF,llk,penalty,sigma_e,K0Q_cP, K1Q_cP] = ...
    jsz_like_L_macro_d(parameters,yields, W, mats, dt,L)
% if max(parameters(1:3))>1
    %parameter restrictions
    lb=[-0.6+1];
ub=[-.000001+1];
A = [[1 -1; 0 1]];
b = [0;0];
if any(parameters>ub)||any(parameters<lb)
    LLF=inf;
 
else
    tmp=[1;parameters(1);parameters(1)];
    K1Q_X = diag(tmp-1);
  
    [llk, penalty,~, ~, ~, ~, sigma_e,K0Q_cP, K1Q_cP, rho0_cP, rho1_cP, cP, llkP, llkQ] = ...
        jszLLK_L_macro_d(yields, W, K1Q_X, 0, mats, dt,L);
 
    LLF = sum(llk);
end