Solving sets of linear equations

Several types of linear systems

exist:

- There may exist a unique vector
that solves (4.6). In that case, the system is called non-singular. An example of such a system is: (4.4)

which has a unique solution. - There may be an infinite number of possible vectors
that solve (4.6). In that case, the system is called underdetermined. For example, the system (4.5)

has solutions, and many others. - There may not be a vector
that solves (4.6). In that case, the system is called overdetermined. Examples of such systems are: (4.6)

and(4.7)

In MATLAB it is possible to determine the solution of a set of linear equations directly. For square or rectangular linear systems the method of first resort is the backslash operator. The solution of

`>> x = A\b`

You can find more information about this command with `help mldivide`

.

Sometimes MATLAB gives one of the following warnings after the command `A\b`

:

`>> Warning: Matrix is close to singular or badly scaled.`

` Results may be inaccurate. RCOND = ....`

or

`>> Warning: Matrix is singular to working precision.`

We will not go into the exact meaning of this warning. However, if this warning appears, you should not trust the result that appears on the screen.

If none of these error messages appears, this does not mean yet that the result that appears on the screen is the `real' solution of

Therefore, it is important to check the value of
`A*x`, and comparing the result to the value of

You can also use the command `A\b`

for symbolic matrices. A warning will be shown if the solution does not exist.

Esteur 2010-03-22