HP Forums
How to solve this improper integral? - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Calculators (and very old HP Computers) (/forum-3.html)
+--- Forum: HP Prime (/forum-5.html)
+--- Thread: How to solve this improper integral? (/thread-3036.html)



How to solve this improper integral? - salvomic - 02-08-2015 11:29 AM

hi,
I need to solve this improper integral
\[ \int_{0}^{\infty}{\frac{x^{a}}{x^{2}+1} dx} \]
with -1 < a < 1
I try to use limit r->\infty and bound integral from 0 to r, but it give the symbolic form of the integral, without calculation...
The integral should be \( \frac{\frac{pi}{2}}{cos(\frac{pi*a}{2})} \)

Is it possible in Prime?

Thanks!

Salvo


RE: How to solve this improper integral? - parisse - 02-08-2015 02:58 PM

No (at least not yet!).


RE: How to solve this improper integral? - salvomic - 02-08-2015 03:48 PM

(02-08-2015 02:58 PM)parisse Wrote:  No (at least not yet!).

thank you for info!

I tried to solve it giving some arbitrary values:
ex.:
a=½ I get in Terminal "Rational unvariate representation is not certified, set proba_epsilon:=0 to certify...", then "Unable to handle singularities..."
If I put epsilon to 0 Terminal says "warning, solution does not seem to cancel c_4^2-taylorx1", then the same error...
a=1/9 I get infinity
a=¼ Terminal says "Warning Algebraic extension not implemented yet for poly [-1,0,2312,39304,167042]" (repeated with other values), then the result (½)*pi*\sqrt(-\sqrt(2)*2+4)
a=⅓ the result is pi/\sqrt(3)

and in fact those are not the solution Smile

Ok, I mustn't oblige the Prime to give more ;-)

Salvo


RE: How to solve this improper integral? - parisse - 02-09-2015 08:10 AM

I get errors with Xcas:
for 1/2 "Unable to handle singularities of 2*((sqrt(2)*ln(x-sqrt(2)*sqrt(x)+1))/8+(sqrt(2)*atan((sqrt(x)-(sqrt(2))/2)/sqrt(2)*2))/4-(sqrt(2)*ln(x+sqrt(2)*sqrt(x)+1))/8+(sqrt(2)*atan((sqrt(x)+(sqrt(2))/2)/sqrt(2)*2))/4) at [undef]"
I did not try on the emulator, but error handling is poor on the Prime, perhaps it is not returned to the user.
You can get the value of the integral by adding int(x^a/(1+x^2),x,-inf,0), replace -inf and inf by R large, add the upper half-circle integral of radius R and apply residue theorem, then take the limit as R->inf.
You can check for a=1/2 or a=1/3 like this
assume(t>0); simplify(eval(subst('int(x^(1/3)/(x^2+1),x,0,inf)',x=t^3)))


RE: How to solve this improper integral? - salvomic - 02-09-2015 08:33 AM

(02-09-2015 08:10 AM)parisse Wrote:  ...
You can get the value of the integral by adding int(x^a/(1+x^2),x,-inf,0), replace -inf and inf by R large, add the upper half-circle integral of radius R and apply residue theorem, then take the limit as R->inf.
You can check for a=1/2 or a=1/3 like this
assume(t>0); simplify(eval(subst('int(x^(1/3)/(x^2+1),x,0,inf)',x=t^3)))

yes, thank you!
ir works well.
I'm trying to memorize this method, it's so useful.

Have a nice day