MathGroup Archive 2001

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

Search the Archive

Re: complex coefficients and rules...

  • To: mathgroup at smc.vnet.net
  • Subject: [mg28261] Re: [mg28203] complex coefficients and rules...
  • From: "Mark Harder" <harderm at ucs.orst.edu>
  • Date: Fri, 6 Apr 2001 01:53:09 -0400 (EDT)
  • Sender: owner-wri-mathgroup at wolfram.com

Richard,
    In[194]:= FullForm[Exp[-4 I y] /. I -> -I ]
Out[194]//FullForm=  Power[E, Times[Complex[0, -4], y]]

In[191]:=conj = Exp[-4 I y] /. Complex[a_, b_] -> Complex[a, -b]
                        4 I y
Out[191]=   E

In[193]:= FullForm[conj]
Out[193]//FullForm= Power[E, Times[Complex[0, 4], y]]

-mark harder


-----Original Message-----
From: Richard Easther <easther at physics.columbia.edu>
To: mathgroup at smc.vnet.net
Subject: [mg28261] [mg28203] complex coefficients and rules...


>
>Hi, 
>
>I am having some trouble applying some simple rules to complex
>expressions. 
>
>For instance,
>
> Exp[-4 I y] /. I-> -I
>
>yields
>
> Exp[-4 I y]
>
>This seemed a bit odd, so I looked at the "full form" and found,
>
>Power[E, Times[Complex[0, -4], y]]
>
>However, trying the match 
>
> Exp[-4 I y] /. a_ I -> -a I
>
>doesn't work either, since FullForm[a I ]  is Times[Complex[0, -1], a]
>and so the patterns do not match.  
>
>All I want is a simple complex conjugate (the Conjugate function does
>not assume that y is real), that maps I->-I. The more tricky 
>
> Exp[-4 I y] /. Complex[a_ ,b_] -> Complex[a,-b] 
>
>does work, but it is seems a little cumbersome.
>
>In any case my question is: is there a general way to avoid having to do
>this, or is Mathematica always going to assume that any algebraic
>constant is potentially complex?
>
>Richard
>



  • Prev by Date: A universal simulation interface: database, input/output, plotting and visualization
  • Next by Date: Re: Re: Automatic expansion of Log[a^n] for a,n explicit positive integers?
  • Previous by thread: Re: complex coefficients and rules...
  • Next by thread: Re:complex coefficients and rules...