// Numbas version: finer_feedback_settings {"name": "LM06 Inverse of a 2x2 matrix", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "LM06 Inverse of a 2x2 matrix", "tags": [], "metadata": {"description": "", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

The inverse of a 2x2 matrix

", "advice": "

Can the inverse of a 2X2 Matrix be found?

\n

The inverse of a matrix can be found if the matrix is a square matrix and has a non-zero determinant. In the first part of this question all the matruces are 2X2 square matrices. The detrminant can be calculated by doing:

\n

$$
\\begin{vmatrix}
a & b \\\\
c & d \\\\
\\end{vmatrix} = ad-bc
$$

\n

If this comes out to be non-zero then the determinant can be found.

\n

Finding the Inverse of a 2x2 Matrix

\n

If there are two 2x2 matrices $A$ and $B$ such that:

\n

$$
AB=BA=
\\left( \\begin{matrix}
1 & 0 \\\\
0 & 1 \\\\
\\end{matrix}\\right)
$$

\n

then we can say that $A$ and $B$ are inverses of each other. The notation for this is that the inverse of a matrix $C$ is written as $C^{-1}$.

\n

If,

\n

$$
C=
\\left(\\begin{matrix}
a & b \\\\
c & d \\\\
\\end{matrix}\\right),
$$

\n

then, the inverse of $C$ is given by the formula:

\n

$$
C^{-1}=\\frac{1}{ad-bc}
\\left(\\begin{matrix}
d & -b \\\\
-c & a \\\\
\\end{matrix}\\right),
$$

\n

So for part 2) of this question let's call the given matrix $D$:

\n

$D=\\var{nonzerodet1}.$

\n

The inverse of $D$ is calculated as follows:

\n

$$
D^{-1} = \\frac{1}{(\\var{nonzerodet1[0][0]})(\\var{nonzerodet1[1][1]})-(\\var{nonzerodet1[1][0]})(\\var{nonzerodet1[0][1]})}\\left(\\begin{matrix}
\\var{nonzerodet1[1][1]} & \\var{-nonzerodet1[0][1]} \\\\
\\var{-nonzerodet1[1][0]} & \\var{nonzerodet1[0][0]} \\\\
\\end{matrix}\\right)
= \\var{inversenonzerodet1}
$$

\n

\n

Use this link to find some resources which will help you revise this topic.

", "rulesets": {}, "extensions": [], "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true, "j": false}, "constants": [], "variables": {"nonzerodet1": {"name": "nonzerodet1", "group": "Ungrouped variables", "definition": "matrix([a[0],a[1]],[a[2],ceil(a[1]*a[2]/a[0]+random(1..4))])", "description": "", "templateType": "anything", "can_override": false}, "nonzerodet2": {"name": "nonzerodet2", "group": "Ungrouped variables", "definition": "matrix([b[0],b[1]],[b[2],ceil(b[1]*b[2]/b[0]+random(1..4))])", "description": "", "templateType": "anything", "can_override": false}, "zerodet1": {"name": "zerodet1", "group": "Ungrouped variables", "definition": "matrix([c[0],c[1]],[3*c[0],3*c[1]])", "description": "", "templateType": "anything", "can_override": false}, "zerodet2": {"name": "zerodet2", "group": "Ungrouped variables", "definition": "Matrix([2*c[0],5*c[0]],[2*c[1],5*c[1]])", "description": "", "templateType": "anything", "can_override": false}, "inversenonzerodet1": {"name": "inversenonzerodet1", "group": "Ungrouped variables", "definition": "inverse(nonzerodet1)", "description": "", "templateType": "anything", "can_override": false}, "a": {"name": "a", "group": "Ungrouped variables", "definition": "repeat(random(-9..9 except 0),3)", "description": "", "templateType": "anything", "can_override": false}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "repeat(random(-9..9 except 0),3)", "description": "", "templateType": "anything", "can_override": false}, "c": {"name": "c", "group": "Ungrouped variables", "definition": "repeat(random(-9..9 except 0),2)", "description": "", "templateType": "anything", "can_override": false}, "precision": {"name": "precision", "group": "Ungrouped variables", "definition": "max(max(abs(inversenonzerodet1[0][0]-siground(inversenonzerodet1[0][0],3)),abs(inversenonzerodet1[0][1]-siground(inversenonzerodet1[0][1],3))),max(abs(inversenonzerodet1[1][0]-siground(inversenonzerodet1[1][0],3)),abs(inversenonzerodet1[1][1]-siground(inversenonzerodet1[1][1],3))))", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["a", "nonzerodet1", "b", "nonzerodet2", "c", "zerodet1", "zerodet2", "inversenonzerodet1", "precision"], "variable_groups": [{"name": "matrix notation", "variables": []}], "functions": {"Latexcodebits": {"parameters": [["m", "number"], ["n", "number"]], "type": "list", "language": "jme", "definition": "repeat(repeat('&',n-1)+['\\\\\\\\'],m-1)+[repeat('&',n-1)+['']]"}, "stringify": {"parameters": [["input", "list"]], "type": "string", "language": "javascript", "definition": "var output = '';\nvar i;\nfor (i = 0; i < input.length; i++) {\n output += input[i];\n} \nreturn output;"}, "Latexcodebitsproductcalc": {"parameters": [["m", "number"], ["k", "number"], ["n", "number"]], "type": "anything", "language": "jme", "definition": "repeat(repeat(repeat('+',k-1)+['&'],n-1)+[repeat('+',k-1)+['\\\\\\\\']],m-1)+[repeat(repeat('+',k-1)+['&'],n-1)+[repeat('+',k-1)+['']]]"}}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "m_n_2", "useCustomName": true, "customName": "1)", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

For which of the following matrices can the inverse be calculated?

", "minMarks": 0, "maxMarks": "2", "shuffleChoices": true, "displayType": "checkbox", "displayColumns": 0, "minAnswers": 0, "maxAnswers": "2", "warningType": "none", "showCellAnswerState": true, "markingMethod": "sum ticked cells", "choices": ["$\\var{nonzerodet1}$", "$\\var{nonzerodet2}$", "$\\var{zerodet1}$", "$\\var{zerodet2}$"], "matrix": ["1", "1", 0, 0], "distractors": ["", "", "", ""]}, {"type": "matrix", "useCustomName": true, "customName": "2)", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

What is the inverses of the following matrix?

\n

(Enter your answers as fractions or decimals to 3 significant figures).

\n

\n

$\\var{nonzerodet1}$

", "correctAnswer": "{inversenonzerodet1}", "correctAnswerFractions": false, "numRows": "2", "numColumns": "2", "allowResize": false, "tolerance": "{precision}", "markPerCell": false, "allowFractions": true, "minColumns": 1, "maxColumns": 0, "minRows": 1, "maxRows": 0, "prefilledCells": ""}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always", "contributors": [{"name": "Mash Sheffield", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4679/"}, {"name": "Poppy Jeffries", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21275/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "resources": []}]}], "contributors": [{"name": "Mash Sheffield", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4679/"}, {"name": "Poppy Jeffries", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21275/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}]}