Re: Distributing square-root (1/2) power through
- To: mathgroup at smc.vnet.net
- Subject: [mg101332] Re: [mg101296] Distributing square-root (1/2) power through
- From: Leonid Shifrin <lshifr at gmail.com>
- Date: Wed, 1 Jul 2009 06:36:43 -0400 (EDT)
- References: <200906301035.GAA10672@smc.vnet.net>
Hi Steven, Mathematica can not simplify your expression further since it does not know what your parameters Mu, Sy , Y1 ,Y2 are: if they are general complex numbers, square root can not be taken unambiguously without indicating which branch you want. This will do what you probably want: In = result = Assuming[Mu > 0 && Sy > 0 && Y1 > 0 && Y2 > 0, Simplify[Dist]]; result // InputForm Out = Abs[E^((Mu - Y1)^2/(2*Sy^2)) - E^((Mu - Y2)^2/(2*Sy^2))]/ (E^(((Mu - Y1)^2 + (Mu - Y2)^2)/(2*Sy^2))*Sqrt[2*Pi]*Sy) Regards, Leonid On Tue, Jun 30, 2009 at 3:35 AM, Steven Matthew Anderson <AdAstra69 at mac.com>wrote: > I'm playing with normal distributions, Two random points 1 and 2 with x and > y coordinates given by: > > px1=PDF[NormalDistribution[Mu,Sx],X1] > px2=PDF[NormalDistribution[Mu,Sx],X1] > py1=PDF[NormalDistribution[Mu,Sy],Y1] > py2=PDF[NormalDistribution[Mu,Sy],Y2] > > The square of the Euclidean Distance between them is > > SqD = (px2-px1)^2+(py2-py1)^2 > > Take the square root and expand of that to get > > Dist = Sqrt[Expand[SqD]] > > Now the question: > > How do I get the square root to act just like another power so I can > simplify this mess? I have tried PowerExpand, FullSimplify, Expand, > Simplify, and various combinations. Not sure what I'm missing here. > >