I ran the following, but the system gave me err "unable to get the Minverse
property of the worksheet function class". Anyone know what happened with that?
Sub Solutions()
q = Range("e12").Value
'define array temprate
Dim temprate() As Double
ReDim temprate(q, q)
For k = 0 To q - 1
For h = 0 To q - 1
temprate(k, h) = Cells(13 + k, 27 + q + h).Value
Next h
Next k
'Define array extrate
Dim Extrate() As Double
ReDim Extrate(q)
For k = 0 To q - 1
Extrate(k) = Cells(12 + k + 1, 27 + 2 * q).Value
Next k
'calculation
Dim results() As Double
ReDim results(q) As Double
For k = 0 To q - 1
results(k) =
Application.WorksheetFunction.MMult(Application.WorksheetFunction.MInverse(tempr\
ate()), Extrate)
Next k
End Sub