1103 MrG What's an Augmented Matrix

2625 days ago by MATH4R2013

#1) check that (2,1) is the solution to: #1) 4*x+3*y==11,x-3*y==-1 var('y') solve([4*x+3*y==11,x-3*y==-1],x,y) 
       
equ1=solve(4*x+3*y==11,y) equ2=solve(x-3*y==-1,y) show(equ1) show(equ2) show(equ1[0].rhs()) show(equ2[0].rhs()) plot([equ1[0].rhs(),equ2[0].rhs()],0,4,aspect_ratio=true) 
       




#2) check that (4,-3,1) is the solution to: #2) x-y+z==8,2*x+3*y-z==-2,3*x-2*y-9*z==9 var('z') solve([x-y+z==8,2*x+3*y-z==-2,3*x-2*y-9*z==9],x,y,z) 
       
#3) solve for (x,y): 2*x-y==2,6*x+8*y==39 a=matrix(QQ,2,2,[(2,-1),(6,8)]);show(a) b=matrix(QQ,2,1,[2,39]);show(b) c=a.augment(b,subdivide=True);show(c) c.rescale_row(0,1/2);show(c) c.add_multiple_of_row(1,0,-6);show(c) c.rescale_row(1,1/11);show(c) c.add_multiple_of_row(0,1,1/2);show(c) 
       






solve([2*x-y==2,6*x+8*y==39],x,y)