Numerical Integration at different point

2 visualizzazioni (ultimi 30 giorni)
syms g;
I0_dBm=-12:22;
for jj=1:length(I0_dBm)
var_ni(jj)=(6.09*10^-10*(10^(I0_dBm(jj)/10))*g)+(8.28*10^-14);
fun(jj)=(1/4)*(2.02*10^7)*1.3844*(g^(2.1417))*exp(-(10* (10^(I0_dBm(jj)/10))*(10^-3)*g/(2*sqrt(var_ni(jj))))^2)*erfc((log(g/(0.0068))+0.1821)/sqrt(0.1));
ber(jj)=sym(int(fun(jj),g, 0, Inf));
end
figure
semilogy(I0_dBm,ber,'g-d','LineWidth',2);
I tried this integration but the error is-
  • Error using semilogyConversion to double from sym is not possible.*

Risposta accettata

Torsten
Torsten il 5 Lug 2018
I0_dBm=-12:22;
for jj=1:length(I0_dBm)
var_ni=@(g)(6.09*10^-10*(10^(I0_dBm(jj)/10))*g)+(8.28*10^-14);
fun=@(g)(1/4)*(2.02*10^7)*1.3844*(g.^(2.1417)).*exp(-(10* (10^(I0_dBm(jj)/10))*(10^-3)*g./(2*sqrt(var_ni(g)))).^2).*erfc((log(g/(0.0068))+0.1821)/sqrt(0.1));
ber(jj)=integral(fun, 0, Inf);
end
figure
semilogy(I0_dBm,ber,'g-d','LineWidth',2);
  5 Commenti
Torsten
Torsten il 5 Lug 2018
That's very good of you, but not necessary.
Best wishes
Torsten.

Accedi per commentare.

Più risposte (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by