[Date Index]
[Thread Index]
[Author Index]
Re: Symbolic complex conjugation?
*To*: mathgroup at smc.vnet.net
*Subject*: [mg89947] Re: [mg89919] Symbolic complex conjugation?
*From*: Murray Eisenberg <murray at math.umass.edu>
*Date*: Wed, 25 Jun 2008 06:24:54 -0400 (EDT)
*Organization*: Mathematics & Statistics, Univ. of Mass./Amherst
*References*: <200806240731.DAA11098@smc.vnet.net>
*Reply-to*: murray at math.umass.edu
I'll just type I in output to denote what you called Isymbol, and I show
fractions in output as in-line, not 2D.
The equations and Solve expressions are distractions here. so are the
complicated names and extra structure in the solution of the second
Solve result.
You are asking, then, why the result of the second of the following is
not what you expect:
test=Ia; test/.I -> -I
-I a
actual=top/(-I something + else); actual/.I -> -I
top/(else - I something)
The explanation is in what you see if you look at the FullForms:
FullForm[test]
Times[Complex[0,1],a]
FullForm[actual]
Times[Power[Plus[else,Times[Complex[0,-1],something]],-1],top]
Or, look at this:
FreeQ[#, I] & /@ {test, actual}
{False,True}
What is I, really?
FullForm[I]
Complex[0,1]
In short, there is no I in the expression actual!
To accomplish what you want, you could do this:
actual/. -I -> I
top/(else + I something)
AES wrote:
> I'm sorry, but I just don't understand why the following test case works
> just fine:
>
> [In copying it, I've substituted "Isymbol" for the \[ImaginaryI] that
> actually appears in the Out[] cells.]
>
> In[202]:= eqna={a+I b==0};
> solna=Solve[eqna,b];
> b=b/.solna[[1]];
> bStar=b/.{I->-I};
> {b, Star}
>
> Out[205]={ -Isymbol a, Isymbol a }
>
> but the actual calculation that prompted the test case doesn't:
>
> In[206]:= eqnp={((dwa/2)+I(w-wa))p-I (kappa/(2 w))dN e==0};
> solnp=Solve[eqnp,p];
> p=p/.solnp[[1]];
> pStar=p/.{I->-I}
>
> Out[208]= { (dN e kappa)/(w (-Isymbol dwa+2 w-2 wa)),
> (dN e kappa)/(w (-Isymbol dwa+2 w-2 wa)) }
>
> And actually, I guess my real concern is not understanding "how it
> happens" -- but more "how it can happen" that Mathematica can do
> something this potentially damaging to some innocent user.
>
--
Murray Eisenberg murray at math.umass.edu
Mathematics & Statistics Dept.
Lederle Graduate Research Tower phone 413 549-1020 (H)
University of Massachusetts 413 545-2859 (W)
710 North Pleasant Street fax 413 545-1801
Amherst, MA 01003-9305
Prev by Date:
**Re: Re: How to add a title to a cell and then collapse it?**
Next by Date:
**Re: Making nice-looking Legend for Plot**
Previous by thread:
**Re: Symbolic complex conjugation?**
Next by thread:
**Re: Re: Symbolic complex conjugation?**
| |