12.07.2015 Views

Learning Guide Learning Guide

Learning Guide Learning Guide

Learning Guide Learning Guide

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

3.1 Simple solve • 47Enclose soln in square brackets to convert it to a list.> [soln];[{x = −1, y = 2}, {x = 2, y = 1 2 }]Now use the following command to substitute each of the solutionssimultaneously into the original equations, eqns.> map(subs, [soln], eqns);[{1 = 1, 3 = 3}, {1 = 1, 3 = 3}]This method can be valuable if your equation has many solutions, orif you are unsure of the number of solutions that a certain command willproduce.Restricting SolutionsYou can limit solutions by specifying inequalities with the solve command.> solve({x^2=y^2},{x,y});{x = −y, y = y}, {x = y, y = y}> solve({x^2=y^2, xy},{x,y});{x = −y, y = y}Consider this system of five equations in five unknowns.> eqn1 := x+2*y+3*z+4*t+5*u=41:> eqn2 := 5*x+5*y+4*z+3*t+2*u=20:> eqn3 := 3*y+4*z-8*t+2*u=125:> eqn4 := x+y+z+t+u=9:> eqn5 := 8*x+4*z+3*t+2*u=11:Now solve the system for all variables.> s1 := solve({eqn1,eqn2,eqn3,eqn4,eqn5}, {x,y,z,t,u});s1 := {x = 2, t = −11, z = −1, y = 3, u = 16}

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!