MathGroup Archive 1994

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

Search the Archive

Re: matrix of coefficients?

  • To: mathgroup at christensen.cybernetics.net
  • Subject: Re: matrix of coefficients?
  • From: olness at phyvms.physics.smu.edu (Fredrick Olness (214) 768-2500 or -2495, Fax -4095)
  • Date: Tue, 25 Oct 1994 11:56:20 -0500

RE: matrix of coefficients?
Martin McClain, WRITES: 

If  varsN = a list of N variables,  and if
exprsN = a list of of N expressions, each one linear in the variables of varsN,
Is there some operator (that I haven't found yet), or some clever way to
use a nonobvious operator, to get the matrix of coefficients? 
======================
If I interpret the question properly, I believe an answer is: 

varsN=Array[v,3]
{v[1], v[2], v[3]}

exprsN=Table[Sum[a[i,j] varsN[[i]],{i,3}],{j,3}];
exprsN //TableForm
a[1, 1] v[1] + a[2, 1] v[2] + a[3, 1] v[3]
a[1, 2] v[1] + a[2, 2] v[2] + a[3, 2] v[3]
a[1, 3] v[1] + a[2, 3] v[2] + a[3, 3] v[3]

table=Table[ Coefficient[exprsN[[i]],varsN[[j]] ],{i,3},{j,3}];
table //TableForm
a[1, 1]   a[2, 1]   a[3, 1]
a[1, 2]   a[2, 2]   a[3, 2]
a[1, 3]   a[2, 3]   a[3, 3]

======================
Fredrick I. Olness

SMU  Mail:  Department of Physics 
            Fondren Science Bldg.
            Southern Methodist University
            Dallas, TX 75275

Phone:      (214) 768-2500 (SMU Office)
            (214) 768-2495 (SMU Secretary)
            (214) 768-4095 (SMU FAX)

Internet:   Olness at phyvms.physics.smu.edu (129.119.200.74)
            Olness at mail.physics.smu.edu





  • Prev by Date: Re: matrix of coefficients?
  • Next by Date: Help with conditional rules
  • Previous by thread: Re: matrix of coefficients?
  • Next by thread: matrix of coefficients?