MathGroup Archive 2010

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Show left hand side

  • To: mathgroup at
  • Subject: [mg111054] Re: Show left hand side
  • From: "Nasser M. Abbasi" <nma at>
  • Date: Sun, 18 Jul 2010 01:05:53 -0400 (EDT)
  • References: <i1s6vd$a2u$>
  • Reply-to: nma at

On 7/17/2010 5:16 AM, Sam Takoy wrote:
> Hi,
> When Mathematica prints an expression not terminated by a semicolon, I
> find it hard to match up the output with what I was trying output when a
> block of commands has many commands not terminated by a semicolon. Is
> there a way to get Mathematica to output the LHS so when I have R=1+1 it
> outputs R = 2 or something like that.
> Thanks!

I think You are trying to find a solution to the not best way of using 
Mathematica. Better to change the method you are using.

I would put each command in a separate cell. This way, you will have one 
command followed by its output below it. I like to also use the Report 
style sheet, this makes output cells more clear.

But if you want to have more than one command in the same cell, you 
could always use Print[] to print the output of the command, and this 
way you can add a string label to the Print command to help you 
determine which command it was.

Something like

Print["x=", x = Pi/2];
Print["a=", a = Sin[x]];
Print["c=", c = Sin[x]];



x = Pi/2;

a = Sin[x]];
Print["a=", %];



  • Prev by Date: Re: Avoid the use of certain functions
  • Next by Date: Re: Percentage Formating
  • Previous by thread: Re: Show left hand side
  • Next by thread: Re: Show left hand side