for ii=1:mm
for t=1:24
ex(ii,t)=-1*(c(t)*((log(1-(1./(Uu(1,t,mm)+Cc(1,t,mm)))))+(log(1-(1./(Uu(2,t,mm)+Cc(2,t,mm)))))+...
(log(1-(1./(Uu(2,t,mm)+Cc(2,t,mm)))))));
end
end
expp=p*ex;
eexp=exp(expp);
F_m_p_c=(1/p)*log(sum(sum(eexp)));