Re: Matrices with Mathematica 5.1

*To*: mathgroup at smc.vnet.net*Subject*: [mg63333] Re: [mg63315] Matrices with Mathematica 5.1*From*: gardyloo at mail.wsu.edu*Date*: Sat, 24 Dec 2005 07:18:58 -0500 (EST)*References*: <200512231008.FAA25936@smc.vnet.net>*Sender*: owner-wri-mathgroup at wolfram.com

Hi, I'd try extracting the last column and then using LinearSolve on it: m = {{1, 7, -2, 0, 8, -3}, {0, 0, 1, 1, 6, 5}, {0, 0, 0, 1, 3, 9}, {0, 0, 0, 0, 0, 0}}; Needs["Statistics`DataManipulation`"] In[9]:= Column[m, -1] Out[9]= {-3, 5, 9, 0} In[10]:= s = Module[{}, v = Column[m, -1]; LinearSolve[m, v]] Out[10]= {-11, 0, -4, 9, 0, 0} In[11]:= m . s == v Out[11]= True In[12]:= $Version Out[12]= 5.2 for Linux (June 20, 2005) Good luck, C.O. > I would like to solve the system given by: > > [1 7 -2 0 -8 -3] > [0 0 1 1 6 5] > [0 0 0 1 3 9] > [0 0 0 0 0 0] > > Where the matrix is a typical matrix in the form x1+x2+...+xn = b where > b is the last item in the row. For example, row 1 could be written as > x1 + 7x2 - 2x3 -8x4 = -3. How could I get mathematica to solve this > matrix? I understand how to build a matrix, I just need to know the > operation to run on it. I tried to use LinearSolve but I did something > wrong. Is there a built-in operation to solve these matrices? If so, > please tell. Thanks. >

**References**:**Matrices with Mathematica 5.1***From:*"drizkol" <drizkol@gmail.com>