Unique solution of a system of linear equations

The GMAT sample question in quant given below is a Linear Equations question and tests concepts related to types of solutions for a system of linear equations. This concept is usually tested in the GMAT as a data sufficiency question rather than as a problem solving question. A sub 600 level GMAT practice question in system of linear equations.

Question 3: For what values of 'k' will the pair of equations 3x + 4y = 12 and kx + 12y = 30 NOT have a unique solution?

  1. 9
  2. 12
  3. 3
  4. 7.5
  5. 2.5

Get to Q51 in GMAT Quant


Online GMAT Course
From INR 2500


Video Explanation


GMAT Live Online Classes


Starts Thu, September 29, 2022


Explanatory Answer

Condition for Unique Solution to Linear Equations

A system of linear equations ax + by + c = 0 and dx + ey + g = 0 will have a unique solution if the two lines represented by the equations ax + by + c = 0 and dx + ey + g = 0 intersect at a point.
i.e., if the two lines are neither parallel nor coincident.
Essentially, the slopes of the two lines should be different.

What does that translate into?

ax + by + c = 0 and dx + ey + g = 0 will intersect at one point if their slopes are different.
Express both the equations in the standardized y = mx + c format, where 'm' is the slope of the line and 'c' is the y-intercept.

ax + by + c = 0 can be written as y = \-\frac{a}{b}x -\frac{c}{a} )
And dx + ey + g = 0 can be written as y = \-\frac{d}{e}x -\frac{g}{e} )
Slope of the first line is \-\frac{a}{b} ) and that of the second line is \-\frac{d}{e} )
For a unique solution, the slopes of the lines should be different.
∴ \-\frac{a}{b} \neq -\frac{d}{e} )
Or \\frac{a}{d} \neq \frac{b}{e} )

Condition for the equations to NOT have a unique solution

The slopes should be equal
Or \\frac{a}{d} = \frac{b}{e} )

Apply the condition in the given equations to find k

In the question given above, a = 3, b = 4, d = k and e = 12.
Therefore, \\frac{3}{k} = \frac{4}{12} )
Or 'k' should be equal to 9 for the system of linear equations to NOT have a unique solution.

The question is "What is the value of k?
When k = 9, the system of equations will represent a pair of parallel lines (their y-intercepts are different). So, there will be NO solution to this system of linear equations in two variables.

Choice A is the correct answer.

What is Unique Solution in Linear Equation?

Solution

Linear equation: An equation in which the highest power of the variable is one is known as a linear equation.Unique solution:A unique solution means only one solution.If a linear equation has a unique solution means only one solution set exists for the equation.A system of linear equations a1x+b1y=0a2x+b2y=0has a unique solution, if a 1a2≠b1b2.


Learning Objectives¶

By the end of this section you should be able to:

  1. Understand the diffrence between unique solutions, no solutions, and infinitely many solutions.
  2. Reconize when a matrix has a unique solutions, no solutions, or infinitely many solutions.
  3. Reconize when a matrix has a unique solutions, no solutions, or infinitely many solutions using python.

Unique Solution¶

The example shown previously in this module had a unique solution. The structure of the row reduced matrix was

\[\begin{split}\begin{vmatrix} 1 & 1 & -1 & | & 5 \\ 0 & 1 & -5 & | & 8 \\ 0 & 0 & 1 & | & -1 \end{vmatrix}\end{split}\]

and the solution was

\[x = 1\]

\[y = 3\]

\[z = -1\]

As you can see, each variable in the matrix can have only one possible value, and this is how you know that this matrix has one unique solution


No solution¶

Let’s suppose you have a system of linear equations that consist of:

\[x + y + z = 2\]

\[y - 3z = 1\]

\[2x + y + 5z = 0\]

The augmented matrix is

\[\begin{split}\begin{vmatrix} 1 & 1 & 1 & | & 2 \\ 0 & 1 & -3 & | & 1 \\ 2 & 1 & 5 & | & 0 \end{vmatrix}\end{split}\]

and the row reduced matrix is

\[\begin{split}\begin{vmatrix} 1 & 0 & 4 & | & 1 \\ 0 & 1 & -3 & | & 1 \\ 0 & 0 & 0 & | & -3 \end{vmatrix}\end{split}\]

As you can see, the final row states that

\[0x + 0y + 0z = -3\]

which impossible, 0 cannot equal -3. Therefore this system of linear equations has no solution.

Let’s use python and see what answer we get.

import numpy as py
from scipy.linalg import solve

A = [[1, 1, 1], [0, 1, -3], [2, 1, 5]]
b = [[2], [1], [0]]

x = solve(A,b)
x

---------------------------------------------------------------------------
LinAlgError                               Traceback (most recent call last)
<ipython-input-1-afc47691740d> in <module>()
      5 b = [[2], [1], [0]]
      6
----> 7 x = solve(A,b)
      8 x

C:\Users\Said Zaid-Alkailani\Anaconda3\lib\site-packages\scipy\linalg\basic.py in solve(a, b, sym_pos, lower, overwrite_a, overwrite_b, debug, check_finite, assume_a, transposed)
    217         return x
    218     elif 0 < info <= n:
--> 219         raise LinAlgError('Matrix is singular.')
    220     elif info > n:
    221         warnings.warn('scipy.linalg.solve\nIll-conditioned matrix detected.'

LinAlgError: Matrix is singular.

As you can see the code gives us an error suggesting there is no solution to the matrix.


Infinite Solutions¶

Let’s suppose you have a system of linear equations that consist of:

\[-3x - 5y + 36z = 10\]

\[-x + 7z = 5\]

\[x + y - 10z = -4\]

The augmented matrix is

\[\begin{split}\begin{vmatrix} -3 & -5 & 36 & | & 10 \\ -1 & 0 & 7 & | & 5 \\ 1 & 1 & -10 & | & -4 \end{vmatrix}\end{split}\]

and the row reduced matrix is

\[\begin{split}\begin{vmatrix} 1 & 0 & -7 & | & -5 \\ 0 & 2 & -3 & | & 1 \\ 0 & 0 & 0 & | & 0 \end{vmatrix}\end{split}\]

As you can see, the final row of the row reduced matrix consists of 0. This means that for any value of Z, there will be a unique solution of x and y, therefore this system of linear equations has infinite solutions.

Let’s use python and see what answer we get.

import numpy as py
from scipy.linalg import solve

A = [[-3, -5, 36], [-1, 0, 7], [1, 1, -10]]
b = [[10], [5], [-4]]

x = solve(A,b)
x

C:\Users\Said Zaid-Alkailani\Anaconda3\lib\site-packages\scipy\linalg\basic.py:223: RuntimeWarning: scipy.linalg.solve
Ill-conditioned matrix detected. Result is not guaranteed to be accurate.
Reciprocal condition number: 3.808655316038273e-19
  ' condition number: {}'.format(rcond), RuntimeWarning)

array([[-12.],
       [ -2.],
       [ -1.]])

As you can see we get a different type of error from this code. It states that the matrix is ill-conditioned and that there is a RuntimeWarning. This means that the computer took to long to find a unique solution so it spat out a random answer. When RuntimeWarings occur, the matrix is likely to have infinite solutions.

What is a unique solution in linear equations?

In a set of linear simultaneous equations, a unique solution exists if and only if, (a) the number of unknowns and the number of equations are equal, (b) all equations are consistent, and (c) there is no linear dependence between any two or more equations, that is, all equations are independent.

In which case a linear equation has a unique solution?

For the given linear equations in two variables, the solution will be unique for both the equations, if and only if they intersect at a single point.