Hi,
I have 30 different matrices and I want a function that chain links them by multiplication. To do this with MMult quickly becomes a very long formula.
I have already a matrix power function which raises a particular matrix to a certain power, n
Function MPower(Matrix, n)
If n = 1 Then
MPower = Matrix
Else: MPower = Application.MMult(MPower(Matrix, n - 1), Matrix)
End If
End Function
Now I need a similar function that multiplies different matrices together
I.e. Matrix 1 x Matrix 2 x Matrix 3....Matrix n
so
if n=3, then the function returns Matrix 1 x Marrix 2 x Matrix 3.
if n=2, function returns Matrix 1 x Matrix 2 etc
Can anyone help?
thanks
toby
Bookmarks