Is it possible to solve the equation in matlab without rearranging it??

Equation: 4X+2X-Y=2X+2, find the value of Y at X=2.
We can solve the equation after rearranging it as, Y=4X-2;
Is it possible to solve the equation in matlab without rearranging??

 Accepted Answer

Although I don't see why you would even bother to do it without rearranging, it is easily possible if you have the symbolic toolbox:
y = sym('y');
x = 2;
y = solve(4*x+2*x-y == 2*x+2, y);

1 Comment

Thanks for your answer. Acctually I have a very big equation to solve, so I thought of solving it without rearranging.

Sign in to comment.

More Answers (0)

Categories

Asked:

on 30 Jan 2015

Commented:

on 30 Jan 2015

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!