how to calculate the integral int (sin(a*x))​^2*exp(-b*​x^2)/(x^2)

10 views (last 30 days)
f=(sin(a*x))^2*exp(-b*x^2)/(x^2);
s=int(f,x,0,inf)
a>0,b>0
syms x;
syms a b positive;
f1=(sin(a*x))^2*exp(-b*x^2)/(x^2);
s1=int(f1,x,0,inf);
s2=simple(s1)
I have tried to caltulate with the function "int" but failed. The results were "Warning: Explicit integral could not be found. s2=inf"
Thanks!
  8 Comments
Walter Roberson
Walter Roberson on 9 Oct 2012
In Maple, it is
simplify( int((sin(a*x))^2*exp(-b*x^2)/(x^2), x=0..infinity), size) assuming positive
I do not have the MATLAB Symbolic toolkit so I do not know if MATLAB can handle this particular integral.
Henry Liu
Henry Liu on 9 Oct 2012
Edited: Henry Liu on 9 Oct 2012
Thanks! Now I know how to do the integral with the Maple software, However, I want to show the course of the integreal to others, so can you tell me how to arrive at that particular solution to the integral by hand, not by any software such as Maple?

Sign in to comment.

Accepted Answer

Andrei Bobrov
Andrei Bobrov on 9 Oct 2012
Edited: Andrei Bobrov on 9 Oct 2012
>> fun = @(a,b)quadgk(@(x)sin(a.*x).^2.*exp(-b.*x.^2)./x.^2,0,inf);
>> fun(1,1)
ans =
0.76351
  4 Comments
Henry Liu
Henry Liu on 9 Oct 2012
I have got symbolic form with the software Maple with the help of Walter Roberson. It is really kind of you and Walter Roberson. What's more, I want to show the course of the integreal to others, so can you tell me how to arrive at that particular solution to the integral by hand not by any software such as Maple?

Sign in to comment.

More Answers (0)

Community Treasure Hunt

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

Start Hunting!