function [Kunr] = KModulunrelaxed(Kf,K0,betai,betac,theta,Ku)

if Kf==0 && theta~=0
    Kunr = (betai+betac)/theta^-1;
elseif theta==0
    Kunr = 0;
else
    Kunr = (((1/Kf)-(1/K0))*(betai+betac))/(1+theta^-1*((1/Kf)-(1/Ku)));
end

if isnan(Kunr) || isinf(Kunr)
    disp('K_UNRELAXED IS NAN OR INF -> SETTING TO ZERO!')
    Kunr = 0;
end
