definite integral in matlab
6 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I want definite integral of equations c2 and pout as-:
z = ((1/gamma(m))*((m/T).^m))*(1/log10(2))
f = (y.^(m-1))*(log10(1+y))*(exp((-m*y)/T))
c2=z*int(f,0,2);
pout=((1/gamma(m))*((m/T).^m))*int(f,0,yth);%outage probability
and please give me help for definite integral in matlab theoretically also if possible.
1 commentaire
Réponses (3)
Dev-iL
le 18 Mar 2012
Hello,
Generally, if you want to calculate some integral analytically, you can use symbolic math. Here's an example:
syms x y
z=2*x+y+4;
If you want to know the antiderivative use:
Z=int(z,x)
Z =
(2*x + y + 4)^2/4
Then you can evaluate this function at the limits using:
subs(Z,x,<value to put instead of 'x'>)
or if you want to just get the result without going through the antiderivative, simply use:
Z=int(z,x,<lower bound>,<upper bound>)
Alternatively, if you want to calculate the integral numerically, you can use the MATLAB function quad (you can read about it in the MATLAB help files).
.
I hope this helps you,
Iliya.
0 commentaires
Walter Roberson
le 18 Mar 2012
If your variable of integration is y, and m and T are to remain symbolic (no definite value given for them before the integration), then you will have trouble finding an analytic integral. You effectively have a y^m term as part of f, and the integral of that part can look very different depending on m (especially m=0 or m=-1)
There is a transform you can do (in Maple at least) that converts the integral into an infinite sum. Not that it does you much good as you end up having to evaluate the infinite sum numerically. And the transform turns out not to be valid if m is integral.
Matters become much easier if you are given m before you do the integration.
If your m are strictly positive integer, then you might be able to work out the pattern. I can see that there is a pattern, but the rule for the the coefficients of the polynomials involved are not obvious.
0 commentaires
Moses
le 1 Nov 2023
How can I plot the analytical results of outage probability vs SNR
0 commentaires
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!