# Cramerâ€™s Rule for a 2Ã—2 System (with Two Variables)

**Cramer’s Rule** is another method that can solve systems of linear equations using determinants.

In terms of notations, a** matrix** is an array of numbers enclosed by square brackets while a **determinant** is an array of numbers enclosed by two vertical bars.

## Notations

The formula to find the **determinant of a 2 x 2 matrix** is very straightforward.

Let’s have a quick review:

## The Determinant of a 2 x 2 Matrix

## Quick Examples of How to Find the Determinants of a 2 x 2 Matrix

**Example 1**: Find the determinant of the matrix [latex]A[/latex] below.

**Example 2**: Find the determinant of the matrix [latex]B[/latex] below.

**Example 3**: Find the determinant of the matrix [latex]C[/latex] below.

After knowing how to find the determinant of a 2 x 2 matrix, you’re now ready to learn the procedures or steps on how to use Cramer’s Rule. Here we go!

## Cramer’s Rules for Systems of Linear Equations with Two Variables

- Given a linear system

- Assign names for each matrix

**coefficient matrix: **

**X – matrix: **

**Y – matrix: **

**To solve for the variable x:**

**To solve for the variable y:**

**Few points to consider when looking at the formula:**

1) The columns of [latex]\large{x}[/latex], [latex]\large{y}[/latex], and the constant terms [latex]\large{c}[/latex] are obtained as follows:

2) Both denominators in solving [latex]\large{x}[/latex] and [latex]\large{y}[/latex] are the same. They come from the columns of [latex]\large{x}[/latex] and [latex]\large{y}[/latex].

3) Looking at the numerator in solving for [latex]\large{x}[/latex], the coefficients of [latex]\large{x}[/latex]-column are replaced by the constant column (in red).

4) In the same manner, to solve for [latex]\large{y}[/latex], the coefficients of [latex]\large{y}[/latex]-column are replaced by the constant column (in red).

## Examples of How to Solve Systems of Linear Equations with Two Variables using Cramer’s Rule

**Example 1**: Solve the system with two variables by Cramer’s Rule

Start by extracting the three relevant matrices: coefficient, [latex]\large{x}[/latex], and [latex]\large{y}[/latex]. Then solve each corresponding determinant.

- For
**coefficient matrix**

- For
**X – matrix**

- For
**Y – matrix**

Once all three determinants are calculated, it’s time to solve for the values of [latex]\large{x}[/latex] and [latex]\large{y}[/latex] using the formula above.

I can write the final answer as [latex]\large{\left( {x,y} \right) = \left( {2, – 1} \right)}[/latex].

**Example 2**: Solve the system with two variables by Cramer’s Rule

Setup your coefficient, [latex]\large{x}[/latex], and [latex]\large{y}[/latex] matrices from the given system of linear equations. Then calculate their determinants accordingly.

Remember that we **always subtract** the products of the diagonal entries.

- For the
**coefficient matrix**(use the coefficients of both [latex]x[/latex] and [latex]y[/latex] variables)

- For the
**X – matrix**(replace the x-column by the constant column)

- For the
**Y – matrix**(replace the y-column by the constant column)

I hope you’re getting comfortable computing for the determinant of a 2-dimensional matrix. To finally solve the required variables, I get the following results.

Writing the final answer in point notation, I got [latex]\large{\left( {x,y} \right) = \left( {6, – 5} \right)}[/latex].

**Example 3**: Solve the system with two variables by Cramer’s Rule

This problem can actually be solved quite easily by the Elimination Method. This is because the coefficients of variable *x* are the “same” but only opposite in signs ( +1 and âˆ’1 ). To solve this using the elimination method, you add their corresponding columns and the *x*-variable goes away – leaving you with a one-step equation in [latex]\large{y}[/latex]. I am mentioning this because every technique has shortcomings and it is best to pick the most efficient. Always get clarification from your teacher if it is okay to use another approach when the method is not specified on a given problem.

Anyway, since we are learning how to solve by Cramer’s Rule, let’s go ahead and work it out with this method.

I will construct three matrices ( coefficient, [latex]\large{x}[/latex] and [latex]\large{y}[/latex]) and evaluate their corresponding determinants.

- For
**coefficient matrix**

- For
**X – matrix**( written as uppercase D with subscript x )

- For
**Y – matrix**(written as uppercase D with subscript y)

After obtaining the values of the three required determinants, I will calculate [latex]\large{x}[/latex] and [latex]\large{y}[/latex] as follows.

The final answer in the point form is [latex]\large{\left( {x,y} \right) = \left( { – 1,2} \right)}[/latex] .

**Example 4**: Solve by Cramer’s Rule the system with two variables

Since we have gone over a few examples already, I suggest that you try this problem on your own. Then, compare your answers to the solution below.

If you get it right the first time that means you’re becoming a “pro” with regards to Cramer’s Rule. If you didn’t, try to figure out what went wrong and learn to not commit the same error next time. This is how you become better at math. Study many kinds of problems and more importantly, do a lot of independent practice.

- For
**coefficient matrix**

- For
**X – matrix**

- For
**Y – matrix**

You should get the answer below…

**Example 5**: Solve the system with two variables by Cramer’s Rule

For our last example, I included a **zero** in the constant column. Every time you see the number zero in the constant column, I highly recommend using Cramer’s Rule to solve the system of linear equations. Why? Because the calculation of the determinants for [latex]\large{x}[/latex] and [latex]\large{y}[/latex] matrices drastically become super easy. Check it out yourself!

- For
**coefficient matrix**

- For
**X – matrix**

- For
**Y – matrix**

The final solution to this problem is

**You may also be interested in these related math lessons or tutorials:**