// Numbas version: finer_feedback_settings {"name": "LM03 Subtracting matrices", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "LM03 Subtracting matrices", "tags": [], "metadata": {"description": "
Generates two sets of matrices that can be added and asks the student to add them. Will ensure that the dimensions in part a) are different to the dimensions in part b) to offer some variety.
", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "Subtracting Matrices
\nCalculate the following:
", "advice": "Matrix subtraction is fairly straightforward in that each entry is calculated by subtracting the corresponding entries. For example the top left entry of the answer to part a) can be calculated as $\\var{A[0][0]} - \\var{Apair[0][0]} = \\var{A[0][0] - Apair[0][0]}$. So for this question:
\na) $\\var{A}-\\var{Apair} = \\var{A-Apair}$
\nb) $\\var{B}-\\var{Bpair} = \\var{B-Bpair}$
\nUse 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": {"A": {"name": "A", "group": "Ungrouped variables", "definition": "matrix(repeat(repeat(random(-9..9),col[0]),row[0]))", "description": "", "templateType": "anything", "can_override": false}, "col": {"name": "col", "group": "Ungrouped variables", "definition": "repeat(random(2..3),3)", "description": "", "templateType": "anything", "can_override": false}, "row": {"name": "row", "group": "Ungrouped variables", "definition": "repeat(random(2..3),3)", "description": "", "templateType": "anything", "can_override": false}, "B": {"name": "B", "group": "Ungrouped variables", "definition": "matrix(repeat(repeat(random(-9..9),col[1]),row[1]))", "description": "", "templateType": "anything", "can_override": false}, "C": {"name": "C", "group": "Ungrouped variables", "definition": "matrix(repeat(repeat(random(-9..9),col[2]),row[2]))", "description": "", "templateType": "anything", "can_override": false}, "Apair": {"name": "Apair", "group": "Ungrouped variables", "definition": "matrix(repeat(repeat(random(-9..9),col[0]),row[0]))", "description": "", "templateType": "anything", "can_override": false}, "Bpair": {"name": "Bpair", "group": "Ungrouped variables", "definition": "matrix(repeat(repeat(random(-9..9),col[1]),row[1]))", "description": "", "templateType": "anything", "can_override": false}, "Cpair": {"name": "Cpair", "group": "Ungrouped variables", "definition": "matrix(repeat(repeat(random(-9..9),col[2]),row[2]))", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "col[0]<>row[0] AND col[0]<>col[1]", "maxRuns": 100}, "ungrouped_variables": ["col", "row", "A", "Apair", "B", "Bpair", "C", "Cpair"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "matrix", "useCustomName": true, "customName": "a)", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "$\\var{A} - \\var{Apair}=$
", "correctAnswer": "{A}-{Apair}", "correctAnswerFractions": false, "numRows": "{row[0]}", "numColumns": "{col[0]}", "allowResize": false, "tolerance": 0, "markPerCell": false, "allowFractions": false, "minColumns": 1, "maxColumns": 0, "minRows": 1, "maxRows": 0, "prefilledCells": ""}, {"type": "matrix", "useCustomName": true, "customName": "b)", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "$\\var{B} -\\var{Bpair}$
", "correctAnswer": "{B}-{Bpair}", "correctAnswerFractions": false, "numRows": "{row[1]}", "numColumns": "{col[1]}", "allowResize": false, "tolerance": 0, "markPerCell": false, "allowFractions": false, "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": "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": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}]}