MathGroup Archive 2002

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

Search the Archive

Re: Getting Symbolic Real and Imag Parts? (Once Again)

  • To: mathgroup at smc.vnet.net
  • Subject: [mg33504] Re: Getting Symbolic Real and Imag Parts? (Once Again)
  • From: adam.smith at hillsdale.edu (Adam Smith)
  • Date: Sun, 24 Mar 2002 01:43:58 -0500 (EST)
  • References: <a7cs6t$hv8$1@smc.vnet.net> <a7eu4h$mss$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

Try the following:

In[19]:=
zComplex = ComplexExpand[Sin[a + I*b], TargetFunctions -> {Re, Im}]
realz = ComplexExpand[Re[zComplex]]
imz = ComplexExpand[Im[zComplex]]

Out[19]=
Cosh[b]*Sin[a] + I*Cos[a]*Sinh[b]

Out[20]=
Cosh[b]*Sin[a]

Out[21]=
Cos[a]*Sinh[b]

In fact you can skip the first step:

In[16]:=
myz = Sin[a + I*b]
realmyz = ComplexExpand[Re[myz]]
imagmyz = ComplexExpand[Im[myz]]

Out[16]=
Sin[a + I*b]

Out[17]=
Cosh[b]*Sin[a]

Out[18]=
Cos[a]*Sinh[b]


Adam Smith


Rodney Sparapani <rsparapa at mcw.edu> wrote in message news:<a7eu4h$mss$1 at smc.vnet.net>...
> aes
> 
> Try Im[zComplex] which gives Im[Cosh[b] Sin[a]]+Re[Cos[a] Sinh[b]]
> 
> That looks a little strange until you realize that the Im[] portion
> 
> is 0 if a and b are real, i.e. Mathematica doesn't assume anything.


  • Prev by Date: Re: Sinh[y]/y as y->0?
  • Next by Date: re: finding functions based on input and output tables
  • Previous by thread: Re: Getting Symbolic Real and Imag Parts? (Once Again)
  • Next by thread: Re: Getting Symbolic Real and Imag Parts? (Once Again)