function [LLF,llk,penalty,K0Q_cP, K1Q_cP] =...
    get_Qlik_1(parameters,yields, W, mats, dt,L,sigma_cP,sigma_e)
% if max(parameters(1:3))>1
    %parameter restrictions
    lb=[-0.6+1;-0.6+1;-0.6+1;0];
ub=[-.0001+1;-.0001+1;-.0001+1;0.4];
A = [[1 -1 0; 0 1 -1] zeros(2,1)];
b = [0;0];

if any(parameters>ub)||any(parameters<lb)||any(A*parameters<b)
    LLF=-inf;
 
else
    K1Q_X = diag(parameters(1:3)-1);
    rinfQ = parameters(4);
  
  Sigma_cP=sigma_cP*sigma_cP';
    [llk,penalty,AcP, BcP, AX, BX, K0Q_cP, K1Q_cP, rho0_cP, rho1_cP, cP,llkQ] = ....
        Q_likelihood(yields, W, K1Q_X, rinfQ, Sigma_cP, mats, dt,L,sigma_e);
 
    LLF = -sum(llk);
   
end