Solving 2 × 2 systems of equations, MATLAB in Engineering

Solving 2 × 2 systems of equations:

However this may be easy in a MATLAB, in normal finding solutions to the systems of equations is not. The systems which are 2 × 2 are, though, fairly clear-cut, and there are many methods of solution for such systems for which the MATLAB has built-in functions.

Consider the 2×2 system of equations which is as shown below:

1031_Solving 2 × 2 systems of equations.png

At first, to visualize the solution, it will be simpler to change both the equations to equation of a straight line by writing each in the form y = mx + b (by altering x1 to x and x2 to y):

2130_Solving 2 × 2 systems of equations1.png

In MATLAB we can plot these lines by using a script; the answers are shown in figure.

778_Solving 2 × 2 systems of equations2.png

2016_Solving 2 × 2 systems of equations3.png

The intersection of the lines is the point (4, -1). In another words, x = 4 and y = -1. Altering back to x1 and x2, we hold x1 = 4 and x2 = -1. This permits us to visualize the solution.

This system of equations in a matrix form is as shown below:

1793_Solving 2 × 2 systems of equations4.png

We know that the solution is x = A-1 b, therefore we solve this when we can find the inverse of A. The one technique of finding the inverse for a 2 × 2 matrix includes computing the determinant D.


´ For a 2× 2matrix A=

719_Solving 2 × 2 systems of equations5.png

The determinant D is defined as follows:


1027_Solving 2 × 2 systems of equations6.png

It is written by using vertical lines around the coefficients of the matrix, and is defined as the product of the values on the diagonal minus the product of the other two numbers.

For a 2 × 2 matrix, the matrix inverse is defined in terms of D as shown below:

1377_Solving 2 × 2 systems of equations7.png

Posted Date: 10/22/2012 3:07:57 AM | Location : United States

Related Discussions:- Solving 2 × 2 systems of equations, Assignment Help, Ask Question on Solving 2 × 2 systems of equations, Get Answer, Expert's Help, Solving 2 × 2 systems of equations Discussions

Write discussion on Solving 2 × 2 systems of equations
Your posts are moderated
Related Questions
str2num function - String: The function str2num does the opposite; it takes the string in which a number is stored and converts it to the type double: >> num = str2num('123.

Matrix solutions to systems of the linear algebraic equations: The linear algebraic equation is an equation of the form a 1 x 1 + a 2 x 2 + a 3 x 3    .  .  .  .  a n x n

Indexing into Vectors of structures: Frequently, when the data structure is a vector of structures, it is essential to iterate through the vector in order by various fields. F

Defined a variable in work space: The variables defined in the script will become a part of the workspace: >> clear >> who >> mysummfile    15 >> who

Function used in binary search: The function below implements this binary search algorithm. It receives two arguments: the sorted vector and a key (on the other hand, the func

Algorithm for expfn function: The algorithm for expfn function is as shown:  receives the value of x as the input argument.  Prints the value of exp(x).  assigns a

. Generate the following signal, x(n)=1+cos((25*pi*n)/100),0 Compute the DTFT of x[n] for w=0:0.01:2*pi Plot the Real part, imaginary part, the amplitude and phas

Image Processing: The Images are represented as grids, or matrices, of picture elements (known as pixels). In MATLAB an image usually is represented as a matrix in which each

Gauss Elimination: The Gauss elimination technique consists of:    Generating the augmented matrix [A b]    Applying EROs to augmented matrix to obtain an upper trian

Expanding a function: The expand function will multiply out terms, and factor will do the opposite: >> expand((x+2)*(x-1)) ans = x^2 x-2 >> factor(ans)