MathGroup Archive 1998

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Can I get ComplexExpand to really work?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg14634] Re: Can I get ComplexExpand to really work?
  • From: "Kevin J. McCann" <kevinmccann at Home.com>
  • Date: Wed, 4 Nov 1998 13:47:03 -0500
  • Organization: @Home Network
  • References: <719f5p$lc6@smc.vnet.net> <71ee5p$7to$1@dragonfly.wolfram.com>
  • Sender: owner-wri-mathgroup at wolfram.com

You can also try using Upset to tell Mathematica that a is real:

Im[a]^=0;Re[a]^=a;

Do a Help on Upset or on ^=

Then


Integrate[E^(I*a*x^2), {x, -Infinity, Infinity}]

produces what you expect (I think)

(Sqrt[Pi/2]*(1 + I*Sign[a]))/(a^2)^(1/4)


If you know that a is positive, then an additional Upset:

Sign[a]^=1;

Gives the following answer

((1/2 + I/2)*Sqrt[2*Pi])/(a^2)^(1/4)


Cheers,

Kevin


Hans Staugaard Nielsen wrote in message
<71ee5p$7to$1 at dragonfly.wolfram.com>...
>Try this
>
>    Integrate[E^(I a
>x^2),{x,-Infinity,Infinity},Assumptions->{Im[a]==0,a>0}]
>
>
>Hans
>
>
>Topher Cawlfield wrote:
>
>> Hi,
>>
>> I'm having lots of problems getting Mathematica to make simplifying
>> assumptions.  It always seems to want to produce horribly complex
>> results because it assumes every variable is complex.  I wish I had
>> better control of that.  In fact, it would also be nice if I could
>> assure Mathematica that certain variables were positive as well.
>>
>> It sounds like the function ComplexExpand should do the trick, at least
>> by assuming that variables are real unless otherwise specified.  But it
>> doesn't really seem to work for me.  Here's an example:
>>
>> ComplexExpand[Integrate[E^(I a x^2), {x, -Infinity, Infinity}]]
>>
>> produces:
>>
>> If[Im[a] == 0, Sqrt[Pi/2] (1 + I Sign[a]) / (a^2)^(1/4), Integrate[E^(I
>> a x^2), {x, -Infinity, Infinity}]]
>>
>> But if it really was assuming that 'a' was real, then it should know
>> that Im[a] == 0!  If I could also tell it that 'a' was positive, the
>> answer would be:
>>
>> (1 + I) Sqrt[Pi/a]  or better still, Sqrt[2 Pi I / a]
>>
>> This is much simpler, and is the answer I want.
>>
>> Of course, my real application of this problem is much more complicated,
>> but ultimately comes down to doing that integral (several times over).
>> The right answer should be just about that simple, but instead
>> Mathematica gives me about 5 pages of output.
>>
>> Is there any hope of getting reasonable symbolic results here?
>>
>>  - Topher Cawlfield
>
>
>
>



  • Prev by Date: Re: Re: Re: Corrupted NB
  • Next by Date: Re: Multinormal CDF and Mathematica
  • Previous by thread: Re: Can I get ComplexExpand to really work?
  • Next by thread: Re: Can I get ComplexExpand to really work?