Matrix and simulation

simulation

I came across a simulation software called MATLAB. I got to know it takes inputs in the form of matrices, provides output in terms of matrices , all in all it operates using matrices. But it seems pretty weird to me that it uses matrices. Why does it use matrices? How does usage of matrices makes it efficient ?

Best Answer

Key point: Matlab is not a simulation tool that uses matrices. It is a matrix math tool that is often used to simulate things.

It is or can be also used for all kinds of other calculations that can be done in terms of matrices --- this includes statistics, linear programming (systems optimization), curve fitting, etc.

The reason we use matrices to do simulations (and lots of other kinds of calculations) is because it provides a very compact way to write down large sets of equations in linear algebra. A single matrix equation like

\$ \mathbb{A}\bar{x} = \bar{b}\$

can, in a single line, represent an arbitrary number of algebraic equations with an arbitrary number of terms each, as long as those equations meet some simple requirements.

Also, these linear algebra equations can be solved by simple but repetitive operations, which is exactly what computers are good out.

Luckily we were able to figure out how to simulate physical systems using linear algebra, so that we can use this notation and computer processes to predict the behavior of different things we want to build (circuits, buildings, chemical plant control systems, ...)

Related Topic