- #1

deema_master

- 13

- 0

\int_0^{\infty}\exp(-z*v(1+1.5/v))z^{\eta+N-.5} \frac{1}{(z+1)^{A+Q+Nrkr/2} (z+.5)^{M+i+j+Nsks/2}} dz$$

where:

$$C=0.25*\exp \left(-\frac{\lambda_1}{2}\right)*\left(\frac{\lambda_1^2}{4}\right)^{\alpha/2}*\left(\frac{\lambda_2^2}{4}\right)^{\beta/2}*\exp \left(-\frac{\lambda_2}{2}\right)*\left(\frac{\lambda_1}{4 *em *v}\right)^{\eta}*\left(\frac{\lambda_2}{4 *em* v}\right)^N*\exp (-\frac{\lambda_r*Nr}{2})*0.25^{Ns*ks/4-0.5}*\exp (-\frac{\lambda_s*Ns}{2})*0.25^{Nr*kr/4-0.5}*(Ns*\lambda_s/4)^M*(Nr*\lambda_r/4)^Q*\frac{1}{\eta! M! N! Q! \Gamma (M+Ks*Ns/2) \Gamma (Q+Nr*kr/2) \Gamma (\beta+N+1) \Gamma (\eta+\alpha+1)}*{em}^A {\eta\choose{i}}{N\choose{j}}{{N-j}\choose{A}}(em+1)^{N-j-A} \Gamma (A+Q+Nr*kr/2) \Gamma (i+j+M+Ns*ks/2)*\left(2^{A+Q+Nr*kr/2)}\right.$$And here is my Matlab code:

Code:

```
close all; clear;clc;
Nr=2;Ns=2;
lmda1=.3; lmda2=.3;
lmdas=.1; lmdar=.1;
z= 0.0001:1:40;
k1=2;k2=2;
kr=2.*Nr;ks=2.*Ns;
ax=0;
avg=0.0001:1:40;
em=1;
ch=2;
for alp=1-k1.*.5:ch
for beta=1-k2.*.5:ch
for eta=0:ch
for N=0:ch
for M=0:ch
for Q=0:ch
for id=0:eta
for jd=0:N
for A=0:N-jd
%
up=.25.*exp(-lmda1./2).*(lmda1./2).^(alp).*(lmda2.^2./(4)).^(beta./2).*exp(-lmda2./2).*(lmda1./(4.*em.*avg)).^eta.*(lmda2./(4.*em.*avg)).^N.*exp(-lmdas.*Ns.*.5).*.25.^(ks.*.25-.5).*exp(-lmdar.*Nr.*.5).*.25.^(kr.*.25-.5).*(Ns.*lmdas.*.25).^M.*(Nr.*lmdar.*.25).^Q;
cy=up.*(1./(factorial(eta).*factorial(N).*factorial(M).*factorial(Q).*gamma(eta+alp+1).*gamma(N+beta+1).*gamma(M+ks.*.5).*gamma(Q+kr.*.5)));
cj=cy.*(factorial(eta)./(factorial(id).*factorial(eta-id))).*(factorial(N)./(factorial(jd).*factorial(N-jd))).*gamma(M+id+jd+ks.*.5);
f1=(cj.*(factorial(N-jd)./(factorial(A).*factorial(N-jd-A))).*em.^A.*(((em+1).^(N-jd-A))).*gamma(kr.*.5+Q+A));
f2=f1.*(2.^(kr.*.5+Q+A)).*avg.^(eta+N);
ax=ax+f2;
end
end
end
end
end
end
end
end
end
q2=2;n2=2;N2=1;eta2=1;
fun2 = exp(-z.*avg.*(1+1.5./avg)).*z.^(eta2+N2-1./2).*(1./((1+z).^(q2).*(1./2+z).^(n2)));
out= trapz(z,fun2);
b=.5.*(1-ax.*(1./sqrt(pi)).*out.*avg.^(1./2));
plot(avg,b);grid;
```