RE: Re: Output of left-hand side of expression
- To: mathgroup at smc.vnet.net
- Subject: [mg35578] RE: [mg35541] Re: [mg35509] Output of left-hand side of expression
- From: "DrBob" <majort at cox-internet.com>
- Date: Fri, 19 Jul 2002 06:09:21 -0400 (EDT)
- Reply-to: <drbob at bigfoot.com>
- Sender: owner-wri-mathgroup at wolfram.com
Note that Literal has been renamed HoldPattern. (In case you try to decipher Jonathan's code.) Bobby -----Original Message----- From: Jonathan Rockmann [mailto:MTheory at msn.com] To: mathgroup at smc.vnet.net Subject: [mg35578] [mg35541] Re: [mg35509] Output of left-hand side of expression Hi JM, You can copy and paste the following expression into your notebook and if you evaluate it at the very beginning you will get polynomials in their standard book form including your c+1. Unprotect[Plus]; Format[Literal[Plus[p__]]]:=Module[{s1,s2},s1=Hold[p];s2=Reverse[s1]; ReplacePart[HoldForm[Evaluate[s2]],Plus,{1,0}]/; OrderedQ[s1]&& s1=!=s2] Jonathan Rockmann mtheory at msn.com ----- Original Message ----- From: news.eircom.net To: mathgroup at smc.vnet.net Subject: [mg35578] [mg35541] [mg35509] Output of left-hand side of expression Hello This is really simple but I cannot find in manuals. (Honestly!) Q. How do I display the left-hand side of an expression currently I do In[148]:= M=C+1 Out[148]= 1+C but I want Out[xxx]= M=1+C I need this so that I can copy/paste the entire expression into a doc. so that it is complete - not just the right hand side or result. Is there some magic command that can do this? or system default? Thankyou.