Re: Those Pesky Minus Signs
- To: mathgroup at smc.vnet.net
- Subject: [mg43302] Re: [mg43275] Those Pesky Minus Signs
- From: Selwyn Hollis <selwynh at earthlink.net>
- Date: Sun, 24 Aug 2003 04:54:58 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
David, Here's a rule that may be useful: pullMinus := HoldPattern[(c_.)*Plus[x:Times[_?Negative, _] ..] ] :> With[{r = Plus @@ {x}[[All,2]]}, HoldForm[-(c*r)]] -1/2(a + b + c) 1/2(-a - b - c) % /. pullMinus -1/2(a + b + c) ----- Selwyn Hollis http://www.math.armstrong.edu/faculty/hollis On Saturday, August 23, 2003, at 08:09 AM, David Park wrote: > Dear MathGroup, > > How would one simplify > > (-1/2)(a + b + c) > 1/2(-a - b - c) > > so the minus sign was in front? Why does it get pulled within in the > first > place? > > David Park > djmp at earthlink.net > http://home.earthlink.net/~djmp/ > >