Re: Re: Simplification of definite integral?
- To: mathgroup at smc.vnet.net
- Subject: [mg40765] Re: [mg40720] Re: Simplification of definite integral?
- From: Andrzej Kozlowski <akoz at mimuw.edu.pl>
- Date: Wed, 16 Apr 2003 01:38:45 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
Here is another way to get the right answer for the case when d is real and without using the PrincipalValue option: FullSimplify[Integrate[ComplexExpand[ TrigToExp[(Sin[x - d]/(x - d))*(Sin[x + d]/(x + d))]], {x, -Infinity, Infinity}]] (Pi*Cos[d]*Sin[d])/d In the non-real case the following: FullSimplify[Integrate[TrigReduce[(Sin[x - d]/(x - d))* (Sin[x + d]/(x + d))], {x, -Infinity, Infinity}, Assumptions -> Arg[d^2] != 0]] (Sqrt[-(1/d^2)]*Sqrt[-d]*Pi*Cos[d]*Sin[d])/Sqrt[d] also seems to be correct while the same thing without TrigReduce appears wrong. Andrzej Kozlowski Yokohama, Japan http://www.mimuw.edu.pl/~akoz/ http://platon.c.u-tokyo.ac.jp/andrzej/ On Tuesday, April 15, 2003, at 04:56 pm, Dr. Wolfgang Hintze wrote: > Andrzej, > > thanks for your hint. The final answer is what I expected from > mathematica (and know to be correct). > > Best regards, > Wolfgang > > > Andrzej Kozlowski wrote: > >> Mathematica has difficulties dealing with the (apparent) singularities >> at x==d and x == -d so if you try straight forward Integrate it want's >> you to assume that d non-real. However, you can get an answer probably >> closer to what you desire by setting the PrincipalValue option to >> True: >> >> >> Integrate[Sin[x-d]/( >> x-d) Sin[x+d]/(x+ >> >> d),{x,-Infinity,Infinity},PrincipalValue->True,Assumptions->{d>0}] >> >> >> (Pi*Cos[d]*Sin[d])/d >> >> For example for d =1 we get: >> >> >> %/.d->1. >> >> >> 1.42832 >> >> This is probably right, particularly that >> >> >> NIntegrate[(Sin[x - 1]/(x - 1))*(Sin[x + 1]/(x + 1)), >> {x, -Infinity, 1, Infinity}] >> >> >> NIntegrate::slwcon:Numerical integration converging too slowly; >> suspect >> one \ >> of the following: singularity, value of the integration being 0, >> oscillatory \ >> integrand, or insufficient WorkingPrecision. If your integrand is >> oscillatory \ >> try using the option Method->Oscillatory in NIntegrate. >> >> >> NIntegrate::ncvb:NIntegrate failed to converge to prescribed accuracy >> after 7 \ >> recursive bisections in x near x = 187.1757811919331`. >> >> >> 1.4283406894658994 >> >> Andrzej Kozlowski Yokohama, Japan http://www.mimuw.edu.pl/~akoz/ http://platon.c.u-tokyo.ac.jp/andrzej/ >> >> >> >> >> >> On Sunday, April 13, 2003, at 03:17 pm, Dr. Wolfgang Hintze wrote: >> >> >>> How do I get a satisfactory result from mathematica for this function >>> >>> f[d]:=Integrate[Sin[x-d]/(x-d) Sin[x+d]/(x+d),{x,-Infinity,Infinity}] >>> >>> I tried >>> >>> f[d]//ComplexExpand >>> >>> and several assumptions but I didn't succeed. Any hints? >>> >>> Wolfgang >>> >>> >>> >>> >>> >> >> > > > >