MathGroup Archive 2005

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

Search the Archive

Related quastions. Question 2

  • To: mathgroup at
  • Subject: [mg57499] Related quastions. Question 2
  • From: kazimir04 at (Kazimir)
  • Date: Sun, 29 May 2005 21:00:18 -0400 (EDT)
  • Sender: owner-wri-mathgroup at

Dear Bob,

you gave the example 

Print["Equation to solve for x"]
a x + b == c
Print["Subtract b from each side"]
# - b & /@ %%
Print["Divide each side by a"]
#/a & /@ %%

It works but i do not like very much expressions with  %%, as I should
not insert more lines before it or I have to modify this symbol. I
would like to start with

expr= (a x + b == c)

and then make a transform like expr1 =  expr - b. It clearly does not
work. Could you advise me a mathematical operartion over expression
which would return a x == c - b .

The best thing I found was 
expr = (a x + b == c)
Distribute[#1 - b &@expr, Equal]
however, it does not work in all cases that I need.


  • Prev by Date: Re: Solve question
  • Next by Date: Re: Complex Oddity
  • Previous by thread: Re: sum the elements of a list
  • Next by thread: Re: Related quastions. Question 2