Về một phương pháp mới điều khiển mượn, khóa kênh tần số mạng di động tế bào - 17



if nuysig<sigk

depck=sigk*(-2/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)/sigk+2/... pi^(1/2)*exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)/sigk)/nuysig/(erf(2^(1/2)*... (gam2-nuyc)/nuysig)-erf(2^(1/2)*(gam1-nuyc)/nuysig)+sigk*(erf(2^(1/2)*... (gam2-ck)/sigk)+erf(2^(1/2)*(gam1-ck)/sigk)))-(nuysig*(1+erf(2^(1/2)*... (gam1-nuyc)/nuysig)-erf(2^(1/2)*(gam2-

nuyc)/nuysig))+sigk*(erf(2^(1/2)*...

(gam2-ck)/sigk)-erf(2^(1/2)*(gam1-ck)/sigk)))/nuysig/(erf(2^(1/2)*... (gam2-nuyc)/nuysig)-erf(2^(1/2)*(gam1-nuyc)/nuysig)+sigk*(erf(2^(1/2)*... (gam2-ck)/sigk)+erf(2^(1/2)*(gam1-ck)/sigk)))^2*sigk*(-2/pi^(1/2)*... exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)/sigk-2/pi^(1/2)*exp(-2*(gam1-ck)^2/... sigk^2)*2^(1/2)/sigk);

end;

function depc=depnuyc(ck, sigk, nuyc, nuysig) gam1=(nuysig*ck-sigk*nuyc)/(nuysig-sigk); gam2=(nuysig*ck+sigk*nuyc)/(nuysig+sigk);

if nuyc==ck

depc=0;

Có thể bạn quan tâm!

Xem toàn bộ 149 trang tài liệu này.

end;

if nuyc>ck

Về một phương pháp mới điều khiển mượn, khóa kênh tần số mạng di động tế bào - 17

if nuysig==sigk

cr=nuysig*sqrt(3.14)*(erf(sqrt(2)*(gam2-nuyc)/nuysig)+1/2)+... sigk*sqrt(2)*(1/2-erf(sqrt(2)*(gam2-ck)/sigk));

dcrnuyc=-exp(-((gam2-nuyc)/nuysig)^2);


end;

if nuysig>sigk

cr=sigk*sqrt(3.14)*(1+erf((gam1-ck)/sigk)-erf((gam2-ck)/sigk))+... nuysig*sqrt(3.14)*(erf(sqrt(2)*(gam2-nuyc)/nuysig)-erf(sqrt(2)*... (gam1-nuyc)/nuysig));

dcrnuyc=exp(-((gam1-nuyc)/nuysig)^2)-exp(-((gam2-nuyc)/nuysig)^2); end;

if nuysig<sigk

cr=sigk*sqrt(3.14)*(erf((gam1-ck)/sigk)-erf((gam2-ck)/sigk))+... nuysig*sqrt(3.14)*(1+erf(sqrt(2)*(gam2-nuyc)/nuysig)-

erf(sqrt(2)*...

(gam1-nuyc)/nuysig));

dcrnuyc=exp(-((gam1-nuyc)/nuysig)^2)-exp(-((gam2-nuyc)/nuysig)^2); end;

depc=(dcrnuyc*(sqrt(3.14)*(nuysig+sigk)-cr)+dcrnuyc*cr)/... ((sqrt(3.14)*(nuysig+sigk)-cr)^2);

end;

if nuyc<ck

if nuysig==sigk

cr=nuysig*sqrt(3.14)*(erf(sqrt(2)*(gam2-nuyc)/nuysig)+1/2)+... sigk*sqrt(2)*(1/2-erf(sqrt(2)*(gam2-ck)/sigk));

dcrnuyc=exp(-((gam2-nuyc)/nuysig)^2); end;

if nuysig>sigk

cr=sigk*sqrt(3.14)*(erf((gam1-ck)/sigk)-erf((gam2-ck)/sigk))+... nuysig*sqrt(3.14)*(1+erf(sqrt(2)*(gam1-nuyc)/nuysig)-

erf(sqrt(2)*...

(gam2-nuyc)/nuysig));



dcrnuyc=exp(-((gam2-nuyc)/nuysig)^2)-exp(-((gam1-nuyc)/nuysig)^2); end;

if nuysig<sigk

cr=sigk*sqrt(3.14)*(erf((gam1-ck)/sigk)-erf((gam2-ck)/sigk))+... nuysig*sqrt(3.14)*(1+erf(sqrt(2)*(gam1-nuyc)/nuysig)-

erf(sqrt(2)*...

(gam2-nuyc)/nuysig));

dcrnuyc=exp(-((gam2-nuyc)/nuysig)^2)-exp(-((gam1-nuyc)/nuysig)^2); end;

depc=(dcrnuyc*(sqrt(3.14)*(nuysig+sigk)-cr)+dcrnuyc*cr)/... ((sqrt(3.14)*(nuysig+sigk)-cr)^2);

end; end;

function dnuysig=depnuysig(ck, sigk, nuyc, nuysig) gam1=(nuysig*ck-sigk*nuyc)/(nuysig-sigk); gam2=(nuysig*ck+sigk*nuyc)/(nuysig+sigk);

if nuyc==ck

if nuysig==sigk dnuysig=0;

end;

if nuysig>sigk

dnuysig=-sigk/((nuysig)^2); end;

if nuysig<sigk dnuysig=1/sigk;

end;

end;

if nuyc>ck

if nuysig==sigk

cr=nuysig*sqrt(3.14)*(erf(sqrt(2)*(gam2-nuyc)/nuysig)+1/2)+... sigk*sqrt(2)*(1/2-erf(sqrt(2)*(gam2-ck)/sigk));

dcrnuysig=sqrt(3.14)*(1/2+erf(sqrt(2)*((gam2-nuyc)/nuysig)^2)-... ((gam2-nuyc)/nuysig)*exp(-((gam2-nuyc)/nuysig)^2));

end;

if nuysig>sigk

cr=sigk*sqrt(3.14)*(1+erf((gam1-ck)/sigk)-erf((gam2-ck)/sigk))+... nuysig*sqrt(3.14)*(erf(sqrt(2)*(gam2-nuyc)/nuysig)-erf(sqrt(2)*... (gam1-nuyc)/nuysig));

dcrnuysig=((gam1-nuyc)/nuysig)*exp(-((gam1-nuyc)/nuysig)^2)-... ((gam2-nuyc)/nuysig)*exp(-((gam2-nuyc)/nuysig)^2);

end;

if nuysig<sigk

cr=sigk*sqrt(3.14)*(erf((gam1-ck)/sigk)-erf((gam2-ck)/sigk))+... nuysig*sqrt(3.14)*(1+erf(sqrt(2)*(gam2-nuyc)/nuysig)-

erf(sqrt(2)*...

(gam1-nuyc)/nuysig));

dcrnuysig=((gam1-nuyc)/nuysig)*exp(-((gam1-nuyc)/nuysig)^2)-... ((gam2-nuyc)/nuysig)*exp(-((gam2-nuyc)/nuysig)^2)+...

sqrt(3.14)*(1+erf(sqrt(2)*(gam2-nuyc)/nuysig)-... erf(sqrt(2)*(gam2-nuyc)/nuysig));

end;

dnuysig=(dcrnuysig*(sqrt(3.14)*(nuysig+sigk)-cr)+dcrnuysig*cr)/... ((sqrt(3.14)*(nuysig+sigk)-cr)^2);



end;

if nuyc<ck

if nuysig==sigk

cr=nuysig*sqrt(3.14)*(erf(sqrt(2)*(gam2-nuyc)/nuysig)+1/2)+... sigk*sqrt(2)*(1/2-erf(sqrt(2)*(gam2-ck)/sigk));

dcrnuysig=sqrt(3.14)*(1/2-erf(-(sqrt(2)*(gam2-nuyc)/nuysig)))+... ((gam2-nuyc)/nuysig)*exp(-((gam2-nuyc)/nuysig)^2);

end;

if nuysig>sigk

cr=sigk*sqrt(3.14)*(erf((gam1-ck)/sigk)-erf((gam2-ck)/sigk))+... nuysig*sqrt(3.14)*(1+erf(sqrt(2)*(gam1-nuyc)/nuysig)-

erf(sqrt(2)*...

(gam2-nuyc)/nuysig));

dcrnuysig=((gam2-nuyc)/nuysig)*exp(-((gam2-nuyc)/nuysig)^2)-... ((gam2-nuyc)/nuysig)*exp(-((gam1-nuyc)/nuysig)^2)+...

sqrt(3.14)*(erf((gam1-ck)/sigk)-erf((gam2-ck)/sigk)); end;

if nuysig<sigk

cr=sigk*sqrt(3.14)*(erf((gam1-ck)/sigk)-erf((gam2-ck)/sigk))+... nuysig*sqrt(3.14)*(1+erf(sqrt(2)*(gam1-nuyc)/nuysig)-

erf(sqrt(2)*...

(gam2-nuyc)/nuysig));

dcrnuysig=((gam2-nuyc)/nuysig)*exp(-((gam2-nuyc)/nuysig)^2)-... ((gam2-nuyc)/nuysig)*exp(-((gam1-nuyc)/nuysig)^2)+...

sqrt(3.14)*(1+erf((gam1-ck)/sigk)-erf((gam2-ck)/sigk));



end;

end;

dnuysig=(dcrnuysig*(sqrt(3.14)*(nuysig+sigk)-cr)+dcrnuysig*cr)/... ((sqrt(3.14)*(nuysig+sigk)-cr)^2);

function depsigk=depsig3(nuyc, nuysig, ck,sigk) gam1=(nuysig*ck-sigk*nuyc)/(nuysig-sigk); gam2=(nuysig*ck+sigk*nuyc)/(nuysig+sigk); depsigk1=0;

if nuyc==ck depsigk=0;

end

if nuyc>ck

if nuysig==sigk

depsigk1=(1/2-erf(2^(1/2)*(gam2-ck)/sigk)+2/sigk/pi^(1/2)*... exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck))/(nuysig*(1/2-

erf(2^(1/2)*...

(gam2-nuyc)/nuysig))+sigk*(1/2+erf(2^(1/2)*(gam2-ck)/sigk)))-... (nuysig*(erf(2^(1/2)*(gam2-nuyc)/nuysig)+1/2)+sigk*(1/2-erf(2^(1/2)*... (gam2-ck)/sigk)))/(nuysig*(1/2-erf(2^(1/2)*(gam2-nuyc)/nuysig))+... sigk*(1/2+erf(2^(1/2)*(gam2-ck)/sigk)))^2*(1/2+erf(2^(1/2)*...

(gam2-ck)/sigk)-2/sigk/pi^(1/2)*exp(-2*(gam2- ck)^2/sigk^2)*2^(1/2)*(gam2-ck));

end;

if nuysig>sigk

depsigk1= (1+erf(2^(1/2)*(gam1-ck)/sigk)-erf(2^(1/2)*(gam2- ck)/sigk)+...



sigk*(-2/pi^(1/2)*exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)*(gam1- ck)/sigk^2+...

2/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck)/sigk^2))/... nuysig/(1-erf(2^(1/2)*(gam2-nuyc)/nuysig)-erf(2^(1/2)*(gam1-nuyc)/... nuysig)+sigk*(erf(2^(1/2)*(gam2-ck)/sigk)-erf(2^(1/2)*(gam1-ck)/... sigk)))-(nuysig*(erf(2^(1/2)*(gam2-nuyc)/nuysig)-erf(2^(1/2)*... (gam1-nuyc)/nuysig))+sigk*(1+erf(2^(1/2)*(gam1-ck)/sigk)-

erf(2^(1/2)*...

(gam2-ck)/sigk)))/nuysig/(1-erf(2^(1/2)*(gam2-nuyc)/nuysig)-... erf(2^(1/2)*(gam1-nuyc)/nuysig)+sigk*(erf(2^(1/2)*(gam2-ck)/sigk)-... erf(2^(1/2)*(gam1-ck)/sigk)))^2*(erf(2^(1/2)*(gam2-ck)/sigk)-... erf(2^(1/2)*(gam1-ck)/sigk)+sigk*(-2/pi^(1/2)*exp(-2*(gam2-ck)^2/... sigk^2)*2^(1/2)*(gam2-ck)/sigk^2+2/pi^(1/2)*exp(-2*(gam1-ck)^2/... sigk^2)*2^(1/2)*(gam1-ck)/sigk^2));

end;

if nuysig<sigk

depsigk1=(erf(2^(1/2)*(gam1-ck)/sigk)-erf(2^(1/2)*(gam2- ck)/sigk)+sigk*...

(-2/pi^(1/2)*exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)*(gam1-ck)/sigk^2+... 2/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck)/sigk^2))/... nuysig/(erf(2^(1/2)*(gam1-nuyc)/nuysig)-erf(2^(1/2)*...

(gam2-nuyc)/nuysig)+sigk*(1-erf(2^(1/2)*(gam1-ck)/sigk)-... erf(2^(1/2)*(gam2-ck)/sigk)))-(nuysig*(1+erf(2^(1/2)*(gam2-nuyc)/... nuysig)-erf(2^(1/2)*(gam1-nuyc)/nuysig))+sigk*(erf(2^(1/2)*(gam1-ck)/... sigk)-erf(2^(1/2)*(gam2-ck)/sigk)))/nuysig/(erf(2^(1/2)*(gam1-nuyc)/... nuysig)-erf(2^(1/2)*(gam2-nuyc)/nuysig)+sigk*(1-erf(2^(1/2)*(gam1-

ck)/...

sigk)-erf(2^(1/2)*(gam2-ck)/sigk)))^2*(1-erf(2^(1/2)*...

(gam1-ck)/sigk)-erf(2^(1/2)*(gam2-ck)/sigk)+sigk*(2/pi^(1/2)*... exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)*(gam1-ck)/sigk^2+2/pi^(1/2)*... exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck)/sigk^2));

end; end;

if nuyc<ck

if nuysig==sigk

depsigk1=(1/2+erf(2^(1/2)*(gam2-ck)/sigk)-2/sigk/pi^(1/2)*exp(-2*... (gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck))/(nuysig*(1/2+erf(2^(1/2)*... (gam2-nuyc)/nuysig))+sigk*(1/2-erf(2^(1/2)*(gam2-ck)/sigk)))-... (nuysig*(1/2-erf(2^(1/2)*(gam2-

nuyc)/nuysig))+sigk*(1/2+erf(2^(1/2)*...

(gam2-ck)/sigk)))/(nuysig*(1/2+erf(2^(1/2)*(gam2-nuyc)/nuysig))+... sigk*(1/2-erf(2^(1/2)*(gam2-ck)/sigk)))^2*(1/2-erf(2^(1/2)*... (gam2-ck)/sigk)+2/sigk/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*...

2^(1/2)*(gam2-ck)); end;

if nuysig>sigk

depsigk1=sigk*(-2/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)/sigk+... 2/pi^(1/2)*exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)/sigk)/nuysig/(1+... erf(2^(1/2)*(gam2-nuyc)/nuysig)-erf(2^(1/2)*(gam1-nuyc)/nuysig)+sigk*... (erf(2^(1/2)*(gam1-ck)/sigk)-erf(2^(1/2)*(gam2-ck)/sigk)))-(nuysig*... (erf(2^(1/2)*(gam1-nuyc)/nuysig)-erf(2^(1/2)*(gam2-nuyc)/nuysig))+... sigk*(1+erf(2^(1/2)*(gam2-ck)/sigk)-erf(2^(1/2)*(gam1-ck)/sigk)))/... nuysig/(1+erf(2^(1/2)*(gam2-nuyc)/nuysig)-erf(2^(1/2)*(gam1-nuyc)/...



nuysig)+sigk*(erf(2^(1/2)*(gam1-ck)/sigk)-erf(2^(1/2)*(gam2-ck)/... sigk)))^2*sigk*(-2/pi^(1/2)*exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)/sigk+... 2/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)/sigk);

end;

if nuysig<sigk

depsigk1=(erf(2^(1/2)*(gam2-ck)/sigk)-erf(2^(1/2)*(gam1-ck)/sigk)+sigk*... (-2/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck)/sigk^2+...

2/pi^(1/2)*exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)*(gam1- ck)/sigk^2))/nuysig/...

(erf(2^(1/2)*(gam2-nuyc)/nuysig)-erf(2^(1/2)*(gam1-nuyc)/nuysig)+sigk*... (erf(2^(1/2)*(gam2-ck)/sigk)+erf(2^(1/2)*(gam1-ck)/sigk)))-(nuysig*... (1+erf(2^(1/2)*(gam1-nuyc)/nuysig)-erf(2^(1/2)*(gam2-nuyc)/nuysig))+... sigk*(erf(2^(1/2)*(gam2-ck)/sigk)-erf(2^(1/2)*(gam1-ck)/sigk)))/nuysig/... (erf(2^(1/2)*(gam2-nuyc)/nuysig)-erf(2^(1/2)*(gam1-nuyc)/nuysig)+sigk*... (erf(2^(1/2)*(gam2-ck)/sigk)+erf(2^(1/2)*(gam1-ck)/sigk)))^2*... (erf(2^(1/2)*(gam2-ck)/sigk)+erf(2^(1/2)*(gam1-ck)/sigk)+sigk*(-2/... pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck)/sigk^2-

2/pi^(1/2)*...

exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)*(gam1-ck)/sigk^2)); end;

end; depsigk=depsigk1;


function depsigk=depsig3(nuyc, nuysig, ck,sigk) if nuyc==ck

depsigk=0;

end

if nuyc>ck

if nuysig==sigk

depsigk=(1/2-erf(2^(1/2)*(gam2-ck)/sigk)+2/sigk/pi^(1/2)*... exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck))/(nuysig*(1/2-

erf(2^(1/2)*...

(gam2-nuyc)/nuysig))+sigk*(1/2+erf(2^(1/2)*(gam2-ck)/sigk)))-... (nuysig*(erf(2^(1/2)*(gam2-nuyc)/nuysig)+1/2)+sigk*(1/2-erf(2^(1/2)*... (gam2-ck)/sigk)))/(nuysig*(1/2-erf(2^(1/2)*(gam2-nuyc)/nuysig))+... sigk*(1/2+erf(2^(1/2)*(gam2-ck)/sigk)))^2*(1/2+erf(2^(1/2)*...

(gam2-ck)/sigk)-2/sigk/pi^(1/2)*exp(-2*(gam2- ck)^2/sigk^2)*2^(1/2)*(gam2-ck));

end;

if nuysig>sigk

depsigk= (1+erf(2^(1/2)*(gam1-ck)/sigk)-erf(2^(1/2)*(gam2-ck)/sigk)+... sigk*(-2/pi^(1/2)*exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)*(gam1-

ck)/sigk^2+...

2/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck)/sigk^2))/... nuysig/(1-erf(2^(1/2)*(gam2-nuyc)/nuysig)-erf(2^(1/2)*(gam1-nuyc)/... nuysig)+sigk*(erf(2^(1/2)*(gam2-ck)/sigk)-erf(2^(1/2)*(gam1-ck)/... sigk)))-(nuysig*(erf(2^(1/2)*(gam2-nuyc)/nuysig)-erf(2^(1/2)*... (gam1-nuyc)/nuysig))+sigk*(1+erf(2^(1/2)*(gam1-ck)/sigk)-

erf(2^(1/2)*...

(gam2-ck)/sigk)))/nuysig/(1-erf(2^(1/2)*(gam2-nuyc)/nuysig)-... erf(2^(1/2)*(gam1-nuyc)/nuysig)+sigk*(erf(2^(1/2)*(gam2-ck)/sigk)-... erf(2^(1/2)*(gam1-ck)/sigk)))^2*(erf(2^(1/2)*(gam2-ck)/sigk)-... erf(2^(1/2)*(gam1-ck)/sigk)+sigk*(-2/pi^(1/2)*exp(-2*(gam2-ck)^2/...



sigk^2)*2^(1/2)*(gam2-ck)/sigk^2+2/pi^(1/2)*exp(-2*(gam1-ck)^2/... sigk^2)*2^(1/2)*(gam1-ck)/sigk^2));

end;

if nuysig<sigk

depsigk=(erf(2^(1/2)*(gam1-ck)/sigk)-erf(2^(1/2)*(gam2-ck)/sigk)+sigk*... (-2/pi^(1/2)*exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)*(gam1-ck)/sigk^2+...

2/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck)/sigk^2))/... nuysig/(erf(2^(1/2)*(gam1-nuyc)/nuysig)-erf(2^(1/2)*...

(gam2-nuyc)/nuysig)+sigk*(1-erf(2^(1/2)*(gam1-ck)/sigk)-... erf(2^(1/2)*(gam2-ck)/sigk)))-(nuysig*(1+erf(2^(1/2)*(gam2-nuyc)/... nuysig)-erf(2^(1/2)*(gam1-nuyc)/nuysig))+sigk*(erf(2^(1/2)*(gam1-ck)/... sigk)-erf(2^(1/2)*(gam2-ck)/sigk)))/nuysig/(erf(2^(1/2)*(gam1-nuyc)/... nuysig)-erf(2^(1/2)*(gam2-nuyc)/nuysig)+sigk*(1-erf(2^(1/2)*(gam1-

ck)/...

sigk)-erf(2^(1/2)*(gam2-ck)/sigk)))^2*(1-erf(2^(1/2)*...

(gam1-ck)/sigk)-erf(2^(1/2)*(gam2-ck)/sigk)+sigk*(2/pi^(1/2)*... exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)*(gam1-ck)/sigk^2+2/pi^(1/2)*... exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck)/sigk^2));

end; end;

if nuyc<ck

if nuysig==sigk

depsigk=(1/2+erf(2^(1/2)*(gam2-ck)/sigk)-2/sigk/pi^(1/2)*exp(-2*... (gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck))/(nuysig*(1/2+erf(2^(1/2)*... (gam2-nuyc)/nuysig))+sigk*(1/2-erf(2^(1/2)*(gam2-ck)/sigk)))-... (nuysig*(1/2-erf(2^(1/2)*(gam2-

nuyc)/nuysig))+sigk*(1/2+erf(2^(1/2)*...

(gam2-ck)/sigk)))/(nuysig*(1/2+erf(2^(1/2)*(gam2-nuyc)/nuysig))+... sigk*(1/2-erf(2^(1/2)*(gam2-ck)/sigk)))^2*(1/2-erf(2^(1/2)*... (gam2-ck)/sigk)+2/sigk/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*...

2^(1/2)*(gam2-ck)); end;

if nuysig>sig

depsigk=sigk*(-2/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)/sigk+... 2/pi^(1/2)*exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)/sigk)/nuysig/(1+... erf(2^(1/2)*(gam2-nuyc)/nuysig)-erf(2^(1/2)*(gam1-nuyc)/nuysig)+sigk*... (erf(2^(1/2)*(gam1-ck)/sigk)-erf(2^(1/2)*(gam2-ck)/sigk)))-(nuysig*... (erf(2^(1/2)*(gam1-nuyc)/nuysig)-erf(2^(1/2)*(gam2-nuyc)/nuysig))+... sigk*(1+erf(2^(1/2)*(gam2-ck)/sigk)-erf(2^(1/2)*(gam1-ck)/sigk)))/... nuysig/(1+erf(2^(1/2)*(gam2-nuyc)/nuysig)-erf(2^(1/2)*(gam1-nuyc)/... nuysig)+sigk*(erf(2^(1/2)*(gam1-ck)/sigk)-erf(2^(1/2)*(gam2-ck)/... sigk)))^2*sigk*(-2/pi^(1/2)*exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)/sigk+... 2/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)/sigk);

end;

if nuysig<sig

depsigk=(erf(2^(1/2)*(gam2-ck)/sigk)-erf(2^(1/2)*(gam1-ck)/sigk)+sigk*... (-2/pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck)/sigk^2+...

2/pi^(1/2)*exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)*(gam1- ck)/sigk^2))/nuysig/...

(erf(2^(1/2)*(gam2-nuyc)/nuysig)-erf(2^(1/2)*(gam1-nuyc)/nuysig)+sigk*... (erf(2^(1/2)*(gam2-ck)/sigk)+erf(2^(1/2)*(gam1-ck)/sigk)))-(nuysig*... (1+erf(2^(1/2)*(gam1-nuyc)/nuysig)-erf(2^(1/2)*(gam2-nuyc)/nuysig))+... sigk*(erf(2^(1/2)*(gam2-ck)/sigk)-erf(2^(1/2)*(gam1-ck)/sigk)))/nuysig/...



(erf(2^(1/2)*(gam2-nuyc)/nuysig)-erf(2^(1/2)*(gam1-nuyc)/nuysig)+sigk*... (erf(2^(1/2)*(gam2-ck)/sigk)+erf(2^(1/2)*(gam1-ck)/sigk)))^2*... (erf(2^(1/2)*(gam2-ck)/sigk)+erf(2^(1/2)*(gam1-ck)/sigk)+sigk*(-2/... pi^(1/2)*exp(-2*(gam2-ck)^2/sigk^2)*2^(1/2)*(gam2-ck)/sigk^2-

2/pi^(1/2)*...

exp(-2*(gam1-ck)^2/sigk^2)*2^(1/2)*(gam1-ck)/sigk^2)); end;

end;

function f=ff11(sig11,c11,x) f11=-((x-c11(1))/sig11(1))^2;

f12=-((x-c11(2))/sig11(2))^2;

f13=-((x-c11(3))/sig11(3))^2;

f14=-((x-c11(4))/sig11(4))^2;

f15=-((x-c11(5))/sig11(5))^2; f=[f11 f12 f13 f14 f15]; function y=layer11(ff11) y11=exp(ff11(1)); y12=exp(ff11(2)); y13=exp(ff11(3)); y14=exp(ff11(4)); y15=exp(ff11(5));

y=[y11 y12 y13 y14 y15]; function f=ff12(sig12,c12,x) f11=-((x-c12(1))/sig12(1))^2;

f12=-((x-c12(2))/sig12(2))^2;

f13=-((x-c12(3))/sig12(3))^2;

f14=-((x-c12(4))/sig12(4))^2;

f15=-((x-c12(5))/sig12(5))^2; f=[f11 f12 f13 f14 f15]; function y=layer12(f2) y21=exp(f2(1));

y22=exp(f2(2));

y23=exp(f2(3));

y24=exp(f2(4));

y25=exp(f2(5));

y=[y21 y22 y23 y24 y25]; function y=layer21(ff11) y11=exp(ff11(1)); y12=exp(ff11(2)); y13=exp(ff11(3)); y14=exp(ff11(4)); y15=exp(ff11(5));

y=[y11 y12 y13 y14 y15];


function y=layer22(ff11) y11=exp(ff11(1)); y12=exp(ff11(2)); y13=exp(ff11(3)); y14=exp(ff11(4)); y15=exp(ff11(5));

y=[y11 y12 y13 y14 y15];


function f=ff3(ome1,ome2,x21,x22)



ff=zeros(1,5); for k=1:5

ff(k)=ome1(k)*x21(k)+ome2(k)*x22(k);

end;

f=ff;

function y3=layer3(f3,c3,sig3) y=zeros(1,5);

for k=1:5

y(k)=gaussmf(f3(k),[sig3(k) c3(k)]);

end;


y3=y;

function f4=ff4(eps,x3) f=zeros(9,5);

for i=1:9

for k=1:5

f(i,k)=x3(k)*eps(i,k); end;

end; f4=f;


function y4=layer4(f4,nuyc,nuysig) y4=zeros(1,9);

for i=1:9

ts=0; ms=0;

for k=1:5

ts=ts+f4(i,k)*nuyc(i,k)*nuysig(i,k); ms=ms+f4(i,k)*nuysig(i,k);

end; y4(i)=ts/ms; end;


function y5=layer5(x4,muy) f5=0;

for i=1:9

f5=f5+muy(i)*x4(i);

end; y5=f5;


function muynew=BP5(d,y5,muyold,eta,x4) de5=zeros(1,9);

muynew=zeros(1,9); for i=1:9

de5(i)=-(d-y5)*x4(i); muynew(i)=muyold(i)+eta*de5(i); end


function nuysig42=BP42(d,y5,muy,f4,nuyc,nuysig,x3,eps,depnuysig,eta) nuysig42=zeros(9,5);

..... Xem trang tiếp theo?
⇦ Trang trước - Trang tiếp theo ⇨

Ngày đăng: 02/11/2022