Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Multiplying multiple renamed matrices

  1. May 12, 2009 #1
    I have a problem multiplying 'n' number of matrices which are output from a for loop within a for loop.

    I am using the code "eval(['matrix' num2str(t) '= [A,B;C,D]')] to each matrix with their respective frequency number (t) on the end and then repeat the loop. i.e if there was frequency from 1-3 it would output
    matrix1=[values of A,B,C,D at that frequency]
    matrix2=[ ]
    matrix3=[ ] ect

    These matrix(t) then have to all be multiplied together to create a transfer matrix which is also 2X2 i.e matrix1*matrix2*matrix3.

    can anyone tell me how to word this so i can get the output after the loop to multiply from matrix(1) to matrix(t) together? The variables are not stored in numerical order meaning an array is not possible.
    Anyone got any ideas? if i'm not wording this clearly enough please say and i'll try to be mo precise.

  2. jcsd
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Can you offer guidance or do you also need help?
Draft saved Draft deleted

Similar Discussions: Multiplying multiple renamed matrices
  1. Orthogonal Matrices (Replies: 1)