Re: Problem with collect
- To: mathgroup at smc.vnet.net
- Subject: [mg6489] Re: Problem with collect
- From: Paul Abbott <paul at physics.uwa.edu.au>
- Date: Mon, 24 Mar 1997 21:38:42 -0500 (EST)
- Organization: University of Western Australia
- Sender: owner-wri-mathgroup at wolfram.com
Hans Steffani wrote: > Take > > blah1 vv ss + blah2 vv ss + > blah3 vv aa + blah4 vv aa + > blah5 ss aa + blah6 ss aa > Collect[%,{ss vv,vv aa,ss aa}] > > this produces > > aa blah5 ss + aa blah6 ss + aa blah3 vv + aa blah4 vv + > blah1 ss vv + blah2 ss vv > > although I want > > aa vv(blah3+blah4) + ss vv(blah1+blah2) + ss aa(blah5+blah6) In version 3.0, FullSimplify does what you want. In[1]:= FullSimplify[blah1 vv ss + blah2 vv ss + blah3 vv aa + blah4 vv aa + blah5 ss aa + blah6 ss aa] Out[5]= aa (blah5+blah6) ss+aa (blah3+blah4) vv+(blah1+blah2) ss vv Cheers, Paul _________________________________________________________________ Paul Abbott Department of Physics Phone: +61-9-380-2734 The University of Western Australia Fax: +61-9-380-1014 Nedlands WA 6907 paul at physics.uwa.edu.au AUSTRALIA http://www.pd.uwa.edu.au/Paul God IS a weakly left-handed dice player _________________________________________________________________