// Numbas version: exam_results_page_options {"name": "Skills Audit for Maths and Stats - Accounting and Financial Management (and duals) (MGT 143)", "metadata": {"description": "

Skills Audit for Maths and Stats for MGTU12 Students.

", "licence": "Creative Commons Attribution-NonCommercial-NoDerivs 4.0 International"}, "duration": 0, "percentPass": 0, "showQuestionGroupNames": false, "shuffleQuestionGroups": false, "showstudentname": true, "question_groups": [{"name": "Questions", "pickingStrategy": "all-ordered", "pickQuestions": 1, "questionNames": ["", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""], "variable_overrides": [[], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], []], "questions": [{"name": "NA7 - Convert Units - volume - ml to l", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

Metric Unit conversion - division by 1000. 

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Express {liquid} millilitres ($ml$) in litres ($l$). Give your answer to 3 decimal places. 

", "advice": "

There are $1000ml$ in $1l$. To work out the conversion: $\\frac{\\var{liquid}}{1000} = \\var{answer}$.

\n

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"liquid": {"name": "liquid", "group": "Ungrouped variables", "definition": "random(100 .. 5200#1)", "description": "", "templateType": "randrange", "can_override": false}, "answer": {"name": "answer", "group": "Ungrouped variables", "definition": "liquid/1000", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["liquid", "answer"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

[[0]]$l$

", "gaps": [{"type": "numberentry", "useCustomName": true, "customName": "answer", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "answer", "maxValue": "answer", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "answer", "precisionType": "dp", "precision": "3", "precisionPartialCredit": 0, "precisionMessage": "You have not given your answer to the correct precision.", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NA12 - Convert Units - Length - Inches to cm", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

convert from inches to cm.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Given that $1$ $inch$ is approximately $2.54$ $cm$. How long is a $\\var{x}$ inch ruler in $cm$?

", "advice": "

The information given in the question tells you to use a conversion factor of $2.54$. So you must multiply $\\var{x}$ by $2.54$ to find the length of the ruler in $cm$. 

\n

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"x": {"name": "x", "group": "Ungrouped variables", "definition": "random(5 .. 20#1)", "description": "", "templateType": "randrange", "can_override": false}, "answer": {"name": "answer", "group": "Ungrouped variables", "definition": "x*2.54", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["x", "answer"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

[[0]]$cm$.

\n

Give your answer to 2 decimal places.

", "gaps": [{"type": "numberentry", "useCustomName": true, "customName": "answer", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "answer", "maxValue": "answer", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "answer", "precisionType": "dp", "precision": "2", "precisionPartialCredit": 0, "precisionMessage": "You have not given your answer to the correct precision.", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NB5 - LCM", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Simon Thomas", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3148/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "Calculating the LCM and HCF of numbers by using prime factorisation.", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

By considering the prime factorisation of $\\var{x}$ and $\\var{y}$, or otherwise, find the lowest common multiple (LCM) of $\\var{x}$ and $\\var{y}$.

", "advice": "

We can write $\\var{x}$ and $\\var{y}$ as a product of prime factors as follows:

\n

$\\var{x}=\\var{show_factors(x)}$

\n

$\\var{y}=\\var{show_factors(y)}$.

\n

\n

For LCM of $\\var{x}$ and $\\var{y}$ we need to multiply each factor the greatest number of times it occurs in either $\\var{x}$ or $\\var{y}$.

\n

i.e. LCM$(x,y) = \\var{show_factors(lcm_xy)}=\\var{lcm_xy}$.

\n

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"x_powers": {"name": "x_powers", "group": "Ungrouped variables", "definition": "[random(1..4),random(0..4),random(0..3),random(0..3)]", "description": "", "templateType": "anything", "can_override": false}, "y_powers": {"name": "y_powers", "group": "Ungrouped variables", "definition": "[random(0..4),random(1..4),random(0..3),random(0..2)]", "description": "", "templateType": "anything", "can_override": false}, "x": {"name": "x", "group": "Ungrouped variables", "definition": "2^x_powers[0]*3^x_powers[1]*5^x_powers[2]*7^x_powers[3]", "description": "", "templateType": "anything", "can_override": false}, "y": {"name": "y", "group": "Ungrouped variables", "definition": "2^y_powers[0]*3^y_powers[1]*5^y_powers[2]*7^y_powers[3]", "description": "", "templateType": "anything", "can_override": false}, "hcf_xy": {"name": "hcf_xy", "group": "Ungrouped variables", "definition": "2^min(x_powers[0],y_powers[0])*3^min(x_powers[1],y_powers[1])*5^min(x_powers[2],y_powers[2])*7^min(x_powers[3],y_powers[3])", "description": "", "templateType": "anything", "can_override": false}, "lcm_xy": {"name": "lcm_xy", "group": "Ungrouped variables", "definition": "2^max(x_powers[0],y_powers[0])*3^max(x_powers[1],y_powers[1])*5^max(x_powers[2],y_powers[2])*7^max(x_powers[3],y_powers[3])", "description": "", "templateType": "anything", "can_override": false}, "primes": {"name": "primes", "group": "Ungrouped variables", "definition": "[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47]", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "x_powers[0]+x_powers[1]+x_powers[2]+x_powers[3]<5\nand\nx_powers[0]+x_powers[1]+x_powers[2]+x_powers[3]>2\nand\ny_powers[0]+y_powers[1]+y_powers[2]+y_powers[3]<5\nand\ny_powers[0]+y_powers[1]+y_powers[2]+y_powers[3]>2\nand (x-y)<>0\nand hcf_xy>6", "maxRuns": "500"}, "ungrouped_variables": ["x_powers", "y_powers", "x", "y", "hcf_xy", "lcm_xy", "primes"], "variable_groups": [], "functions": {"show_factors": {"parameters": [["n", "number"]], "type": "string", "language": "jme", "definition": "latex( // mark the output as a string of raw LaTeX\n join(\n map(\n if(a=1,p,p+'^{'+a+'}'), // when the exponent is 1, return p, otherwise return p^{exponent}\n [p,a],\n filter(x[1]>0,x,zip(primes,factorise(n))) // for all the primes p which are factors of n, return p and its exponent\n ),\n ' \\\\times ' // join all the prime powers up with \\times symbols\n )\n)"}}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "lcm_xy", "maxValue": "lcm_xy", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NC2 BIDMAS with a division", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Newcastle University Mathematics and Statistics", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/697/"}, {"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

Questions testing understanding of the precedence of operators using BIDMAS, applied to integers. These questions only test DMAS. That is, only Division/Multiplcation and Addition/Subtraction.

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

Evaluate the following expression:

", "advice": "

BIDMAS stands for:

\n

Brackets

\n

Indices

\n

Division

\n

Multiplication

\n

Addition

\n

Subtraction

\n

\n

And is a way for us to remember guidance about the order in which calculations are carried out to ensure that everyone doing teh same sum gets the same answer. In this case the first thing that is in the question is Division.

\n

First work through the expression from left to right, evaluating any division as you come to it. You should be left with an expression involving only pluses and minuses. Evaluate this expression, again working from left to right. Thus:

\n

\n

\\[\\var{h}-\\var{a2*b2} \\div \\var{b2}\\]

\n

\\[=\\var{h}-\\var{a2}\\]

\n

\\[=\\var{h-a2}\\]

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"b2": {"name": "b2", "group": "Ungrouped variables", "definition": "random(2..9 except a2)", "description": "", "templateType": "anything", "can_override": false}, "h": {"name": "h", "group": "Ungrouped variables", "definition": "random(7..15)", "description": "", "templateType": "anything", "can_override": false}, "a2": {"name": "a2", "group": "Ungrouped variables", "definition": "random(2..9)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["h", "a2", "b2"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

$\\var{h}-\\var{a2*b2} \\div \\var{b2}$

", "minValue": "{h-a2}", "maxValue": "{h-a2}", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "ND3 Rounding SF (decimal)", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Stanislav Duris", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1590/"}, {"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}, {"name": "Oliver Spenceley", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23557/"}], "tags": ["rounding"], "metadata": {"description": "

Round numbers to a given number of significant figures.

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "", "advice": "

The first thing to do when we are rounding numbers is to identify the last digit we are keeping.

\n

When you're asked to round your answer to a number of significant figures, you need to decide whether to keep the last digit same (rounding down) or increase it by 1 (rounding up). If the following digit is less than 5 we round down and we round up when the next digit is 5 or more.

\n

To write it down in steps:

\n
    \n
      \n
        \n
          \n
        1. Identify the last digit we need to keep.
        2. \n
        3. Look at the following digit.
        4. \n
        5. If it's 5 or more, increase the previous digit by one.
        6. \n
        7. If it's 4 or less, keep the previous digit the same.
        8. \n
        9. Fill any spaces to the right of the digit with zeros if needed.
        10. \n
        \n
      \n
    \n
\n

It is important to keep in mind that if the digit we are increasing is 9, it becomes zero and we increase the previous digit instead. If this digit is 9 as well, we move along to the left side until we find a digit less than 9.

\n

The last digit we need to keep will depend on how many zeros there are.  We don't consider leading zeros to be significant,
i.e. 0.03 and 0.3 both have 1 significant figure (but 0.30 has two significant figures, since the second zero isn't a 'leading' zero).

\n

i)

\n

We round $\\var{e1}$ to 1 significant figure. The first non-zero digit is $\\var{edig[4]}$, followed by $\\var{edig[3]}$. This is lower than 5 so we round downmore than 5 so we round up to get $\\var{sigformat(e1,1)}$.

\n

ii)

\n

We round $\\var{e1}$ to {sf} significant figures. The first non-zero digit is $\\var{edig[4]}$. The second following digit is $\\var{edig[3]}$, the third following digit is $\\var{edig[2]}$ and the fourth following digit is $\\var{edig[1]}$. The digit following the last digit we are keeping is $\\var{edig[2]}$$\\var{edig[1]}$$\\var{edig[0]}$, so we round to get $\\var{sigformat(e1, sf)}$. These are our {sf} significant figures. 

\n

\n

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

\n

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"edig": {"name": "edig", "group": "Ungrouped variables", "definition": "repeat(random(1..9), 5)", "description": "", "templateType": "anything", "can_override": false}, "d1": {"name": "d1", "group": "Ungrouped variables", "definition": "n_from_digits(ddig)", "description": "

Random integer.

", "templateType": "anything", "can_override": false}, "e1": {"name": "e1", "group": "Ungrouped variables", "definition": "n_from_digits(edig)*10^(random(-6,-7,-8))", "description": "

Random number with 7 decimal places.

", "templateType": "anything", "can_override": false}, "ddig": {"name": "ddig", "group": "Ungrouped variables", "definition": "repeat(random(1..9), 6)", "description": "", "templateType": "anything", "can_override": false}, "sf": {"name": "sf", "group": "Ungrouped variables", "definition": "3", "description": "

Number of significant figures to round.

", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": "100"}, "ungrouped_variables": ["sf", "ddig", "edig", "d1", "e1"], "variable_groups": [], "functions": {"n_from_digits": {"parameters": [["digits", "list"]], "type": "number", "language": "jme", "definition": "if(\n len(digits)=0,\n 0,\n digits[0]+10*n_from_digits(digits[1..len(digits)])\n)"}}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Round $\\var{e1}$

\n

iii) $\\var{e1}$ rounded to 1 significant figure is:  [[0]]

\n

iv) $\\var{e1}$ rounded to {sf} significant figures is:  [[1]]

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "siground(e1, 1)", "maxValue": "siground(e1, 1)", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "siground(e1, sf)", "maxValue": "siground(e1, sf)", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "ND4 - Upper/Lower bounds", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

State the Upper and lower bound of a distance that has been rounded to either the nearest 10 or 100 miles.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

The distance between two towns had been rounded to the nearest {x} miles in an aticle in the newspaper. If they reported that the distance was {y} miles, what are the upper and lower bound for the reported number?

", "advice": "

If a number like {y} has been rounded to the nearest {x} then {y} would have been rounded down if it was less than {y+x/2} because {y} is the nearest multiple of {x}.

\n

Similarly {y} would have been rounded up if it was larger than or equal to {y-x/2}. This means the lower bound is {y-x/2} and the upper bound is {y+x/2}.

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"x": {"name": "x", "group": "Ungrouped variables", "definition": "10^random(1,2)", "description": "", "templateType": "anything", "can_override": false}, "y": {"name": "y", "group": "Ungrouped variables", "definition": "random(1000..10000 # x)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["x", "y"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Upper bound:

\n

[[0]]

\n

Lower bound:

\n

[[1]]

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "x/2+y", "maxValue": "x/2+y", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "y-x/2", "maxValue": "y-x/2", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NE2 - Negatives (add/subtract) 2", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

Calculations with negative numbers.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Calculate $\\var{x}-(\\var{y})$.

", "advice": "

When you subtract a negative number that is the same as adding the number so

\n

\\[\\var{x}-(\\var{y})=\\var{x}+\\var{-y}=\\var{x-y}\\]

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"x": {"name": "x", "group": "Ungrouped variables", "definition": "random(1..50)", "description": "", "templateType": "anything", "can_override": false}, "y": {"name": "y", "group": "Ungrouped variables", "definition": "random(-50..-1)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["x", "y"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "{x}-{y}", "maxValue": "{x}-{y}", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NE5 - Dividing Negatives", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

Calculations with negative numbers.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Calculate $(\\var{x})\\div(\\var{y})$.

", "advice": "

When we divide two numbers the rule is,

\n\n

In this calculation we have

\n

\\[(\\var{x})\\div(\\var{y})=\\var{x/y}.\\]

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"x": {"name": "x", "group": "Ungrouped variables", "definition": "random(-10..10)*y", "description": "", "templateType": "anything", "can_override": false}, "y": {"name": "y", "group": "Ungrouped variables", "definition": "random(-10..10 except 0)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["x", "y"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "{x/y}", "maxValue": "{x/y}", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NF1 Percentage increase", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

Calculate the percentage increase (as a percentage) given a number and the size of the increase.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

What is the percentage increase in a class of {total} if {additional} more are added to it?

\n

Give your answer to 2 decimal places.

", "advice": "

To calculate a percentage increase you need to find how much the increase is as a percentage of the original number. In this question the increase is {additional} and the original number is {total} so the percentage is

\n

\\[ \\frac{\\var{additional}}{\\var{total}}\\times100\\%=\\var{dpformat(additional/total,4)}\\times 100\\%=\\var{dpformat(percentage,2)}\\%\\]

\n

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"total": {"name": "total", "group": "Ungrouped variables", "definition": "random(15..60)", "description": "", "templateType": "anything", "can_override": false}, "additional": {"name": "additional", "group": "Ungrouped variables", "definition": "random(2..10)", "description": "", "templateType": "anything", "can_override": false}, "percentage": {"name": "percentage", "group": "Ungrouped variables", "definition": "additional/total*100", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["total", "additional", "percentage"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

[[0]]%

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "percentage", "maxValue": "percentage", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "2", "precisionPartialCredit": 0, "precisionMessage": "You have not given your answer to the correct precision.", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NF2 Percentage decrease", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Stanislav Duris", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1590/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": ["decrease", "discount", "percentages", "taxonomy"], "metadata": {"description": "

Given a student discount, calculate a discounted price.

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

{pname} is buying a new {item}. The price of the model he picked is £{price}. On a website with discounts for students, he found a voucher for a discount of {percentage}%.

", "advice": "

There are multiple methods to approach this problem. The first method involves working out the discounted price as a percentage of the original, while the second method calculates the value of the discount and subtracts that from the listed price.

\n

Method 1

\n

There is a {percentage}% decrease in price. This means that the new price will be {100-percentage}% of the old price.

\n

\\[\\begin{align} \\frac{\\var{100-percentage}}{100} \\times \\var{price} &= \\var{dpformat((100-percentage)/100*price,4)} \\\\&= \\var{dpformat((100-percentage)/100*price, 2)}\\text{.} \\end{align}\\]

\n

Or, using the multiplier method,

\n

\\[\\begin{align} \\var{(100-percentage)/100} \\times \\var{price} &= \\var{dpformat((100-percentage)/100*price,4)}\\\\&= \\var{dpformat((100-percentage)/100*price, 2)}\\text{.} \\end{align}\\]

\n

When we are talking about money, it is usually assumed that we will round the answer to 2 decimal places.

\n

Method 2

\n

We find the discount first. This is

\n

\\[\\frac{\\var{percentage}}{100} \\times \\var{price} = \\var{dpformat((percentage)/100*price,4)}\\text{.}\\]

\n

Or using a decimal multiplier,

\n

\\[\\var{(percentage)/100} \\times \\var{price} = \\var{dpformat((percentage)/100*price,4)}\\text{.}\\]

\n

Then we subtract the discount from the original price to get the new price:

\n

\\[ \\var{price} - \\var{dpformat(discount,2)} = \\var{dpformat(price - discount, 2)}\\text{.} \\]

\n

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"discount": {"name": "discount", "group": "Ungrouped variables", "definition": "percentage*price/100", "description": "", "templateType": "anything", "can_override": false}, "pname": {"name": "pname", "group": "Ungrouped variables", "definition": "random(\"Adair\",\"Aya\",\"Bergen\",\"Dua\",\"Fadhili\",\"Harper\",\"Kaden\",\"Ola\",\"Pat\",\"Skylar\",\"Wren\",\"Zendaya\")", "description": "

Names.

", "templateType": "anything", "can_override": false}, "discountrounded": {"name": "discountrounded", "group": "Ungrouped variables", "definition": "precround(discount,2)", "description": "", "templateType": "anything", "can_override": false}, "price": {"name": "price", "group": "Ungrouped variables", "definition": "switch(\n item = \"TV\", random(170.99..1199.99), \n item = \"laptop\", random(200.99..799.99),\n item = \"smartphone\", random(100.99..799.99),\n item = \"PC\", random(200.99..969.99),\n item = \"gaming console\", random(80.99..349.99),\n random(110.99..649.99))\n", "description": "

Price of an item.

", "templateType": "anything", "can_override": false}, "item": {"name": "item", "group": "Ungrouped variables", "definition": "random(\"TV\", \"laptop\", \"smartphone\", \"PC\", \"gaming console\", \"fridge\")", "description": "

The bought item.

", "templateType": "anything", "can_override": false}, "percentage": {"name": "percentage", "group": "Ungrouped variables", "definition": "random(5..40 #5)", "description": "

Discount percentage.

", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": "1000"}, "ungrouped_variables": ["item", "pname", "price", "percentage", "discount", "discountrounded"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

What will the discounted price of the {item} be?

\n

Round your answer to the nearest penny.

\n

£ [[0]]

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "(100-percentage)/100*price", "maxValue": "(100-percentage)/100*price", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "2", "precisionPartialCredit": "0", "precisionMessage": "

Your answer does not make sense in real life, we cannot divide a penny any further. Shops always round their prices for items. That is why you should have rounded your answer to $\\var{precround((100-percentage)/100*price, 2)}$.

", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NF3 - Percentage change (decrease then increase)", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

Compound percentage change.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

The value of a car is initially {StartingPrice}. If the value decreases by {dec}%, and then increases by {inc}%, what is the final value?

\n

Give your answer correct to two decimal places.

", "advice": "

There is a {dec}% decrease in price. This means that price after the decrease will be {100-dec}% of the old price.

\n

\\[\\frac{\\var{100-dec}}{100} \\times \\var{StartingPrice} = \\var{(100-dec)/100*StartingPrice}\\]

\n

Then there is a {inc}% increase in price. This means the final price will be {100+inc}% of the price after the decrease.

\n

\\[\\frac{\\var{100+inc}}{100} \\times \\var{(100-dec)/100*StartingPrice} = £\\var{dpformat((100+inc)/100*(100-dec)/100*StartingPrice,2)}\\]

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"dec": {"name": "dec", "group": "Ungrouped variables", "definition": "random(1..50)", "description": "", "templateType": "anything", "can_override": false}, "inc": {"name": "inc", "group": "Ungrouped variables", "definition": "random(1..50)", "description": "", "templateType": "anything", "can_override": false}, "FinalPrice": {"name": "FinalPrice", "group": "Ungrouped variables", "definition": "StartingPrice*(1-dec/100)*(1+inc/100)", "description": "", "templateType": "anything", "can_override": false}, "StartingPrice": {"name": "StartingPrice", "group": "Ungrouped variables", "definition": "random(600..8000 # 10)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["dec", "inc", "FinalPrice", "StartingPrice"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

\n

£[[0]]

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "FinalPrice", "maxValue": "FinalPrice", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "2", "precisionPartialCredit": 0, "precisionMessage": "You have not given your answer to the correct precision.", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NF4 Reverse percentages", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Stanislav Duris", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1590/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": ["decrease", "percentages", "taxonomy"], "metadata": {"description": "

Find the original price before a discount by dividing the new price by the percentage discount.

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

{name1} and {name2} are friends. {name1} noticed {name2}'s new {item} when he came over to visit her house. He immediately knew he wanted to buy the same model. When he got home, he bought the {item} online for £{newprice}.

", "advice": "

We need to find the original price paid by {name2}. This value represents 100%.

\n

By the time {name1} bought the {item}, the price had decreased by {percentage}%.

\n

{name1} therefore paid {100-percentage}% of the price {name2} paid.

\n

\n

We use the unitary method to find the original price. We know the price paid by {name1}.

\n

\\[\\var{100-percentage}\\text{%} = \\var{newprice} \\text{.}\\]

\n

Divide both sides by {100-percentage} to get

\n

\\[\\begin{align} 1\\text{%} &= \\var{newprice} \\div \\var{100-percentage} \\\\&= \\var{newprice/(100-percentage)} \\text{.} \\end{align}\\]

\n

Multiply both sides by 100 to get

\n

\\[\\begin{align} 100\\text{%} &= \\var{newprice/(100-percentage)} \\times 100 \\\\&= \\var{newprice/(100-percentage)*100} \\\\&= \\var{oldprice}\\text{.} \\end{align}\\]

\n

This is the original price paid by {name2} before the {percentage}% decrease.

\n

We can check our answer with a different method.

\n

\\[\\begin{align} \\var{100-percentage}\\text{% of } \\var{oldprice} &= \\var{(100-percentage)/100} \\times \\var{oldprice} \\\\&=  \\var{(100-percentage)/100*oldprice} \\\\&= \\var{precround((100-percentage)/100*oldprice, 2)}  \\text{.} \\end{align}\\]

\n

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"newprice": {"name": "newprice", "group": "Ungrouped variables", "definition": "precround(oldprice*(100-percentage)/100,2)", "description": "", "templateType": "anything", "can_override": false}, "name2": {"name": "name2", "group": "Ungrouped variables", "definition": "random(\"Kaden\",\"Ola\",\"Pat\",\"Skylar\",\"Wren\",\"Zendaya\")", "description": "", "templateType": "anything", "can_override": false}, "name1": {"name": "name1", "group": "Ungrouped variables", "definition": "random(\"Adair\",\"Aya\",\"Bergen\",\"Dua\",\"Fadhili\",\"Harper\")", "description": "", "templateType": "anything", "can_override": false}, "oldprice": {"name": "oldprice", "group": "Ungrouped variables", "definition": "switch(\n item = \"TV\", random(179.99..1199.99 #10), \n item = \"laptop\", random(209.99..799.99 #10),\n item = \"smartphone\", random(109.99..799.99 #10),\n item = \"PC\", random(209.99..969.99 #10),\n item = \"gaming console\", random(89.99..349.99 #10),\n 399.99)", "description": "", "templateType": "anything", "can_override": false}, "percentage": {"name": "percentage", "group": "Ungrouped variables", "definition": "random(5..30)", "description": "

Discount percentage.

", "templateType": "anything", "can_override": false}, "item": {"name": "item", "group": "Ungrouped variables", "definition": "random(\"TV\", \"laptop\", \"smartphone\", \"PC\", \"gaming console\")", "description": "

The bought item.

", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "precround(precround(oldprice*(100-percentage)/100,2)*100/(100-percentage),2) = oldprice", "maxRuns": "1000"}, "ungrouped_variables": ["item", "name1", "percentage", "name2", "oldprice", "newprice"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

When {name1} told {name2} how much he had paid for the {item}, {name2} said the price had decreased by {percentage}% since she bought it.

\n

How much did {name2} pay for the {item}?

\n

£  [[0]]

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": "1", "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "oldprice", "maxValue": "oldprice", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "2", "precisionPartialCredit": 0, "precisionMessage": "You have not given your answer to the correct precision.", "strictPrecision": false, "showPrecisionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NG4 Subtract fractions", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Lauren Richards", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1589/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}], "tags": ["adding and subtracting fractions", "adding fractions", "converting between decimals and fractions", "converting integers to fractions", "Fractions", "fractions", "integers", "manipulation of fractions", "subtracting fractions", "taxonomy"], "metadata": {"description": "

Manipulate fractions in order to add and subtract them. The difficulty escalates through the inclusion of a whole integer and a decimal, which both need to be converted into a fraction before the addition/subtraction can take place. 

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

Evaluate the following additions and subtractions, giving each fraction in its simplest form. Write the numerator (the top number) as negative if the fraction is negative.

", "advice": "

$\\displaystyle\\frac{\\var{f_coprime}}{\\var{g_coprime}}-\\frac{\\var{h_coprime}}{\\var{j_coprime}}+2.$

\n

\n

The two fractions can be individually multiplied to achieve a common denominator of the lowest common multiple, $\\var{lcm2}.$

\n

$\\displaystyle\\frac{\\var{f_coprime}}{\\var{g_coprime}}$ becomes $\\displaystyle\\frac{\\var{flcm2_g}}{\\var{lcm2}}$ and $\\displaystyle\\frac{\\var{h_coprime}}{\\var{j_coprime}}$ becomes $\\displaystyle\\frac{\\var{hlcm2_j}}{\\var{lcm2}}.$

\n

We can now subtract the second fraction from the first.

\n

$\\displaystyle\\frac{\\var{flcm2_g}}{\\var{lcm2}}-\\frac{\\var{hlcm2_j}}{\\var{lcm2}}=\\frac{\\var{flcmhlcm}}{\\var{lcm2}}.$

\n

\n

Find out more about this topic using our resource.

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"hlcm2_j": {"name": "hlcm2_j", "group": "Part b", "definition": "h_coprime*lcm2_j", "description": "

PART B

", "templateType": "anything", "can_override": false}, "lcm2": {"name": "lcm2", "group": "Part b", "definition": "lcm(g_coprime,j_coprime)", "description": "

PART B

", "templateType": "anything", "can_override": false}, "gcd_fg": {"name": "gcd_fg", "group": "Part b", "definition": "gcd(f,g)", "description": "

PART B gcd of first fraction num and denom

", "templateType": "anything", "can_override": false}, "j": {"name": "j", "group": "Part b", "definition": "random(2..10 except h)", "description": "

PART B

", "templateType": "anything", "can_override": false}, "h": {"name": "h", "group": "Part b", "definition": "random(1..10)", "description": "

PART B

", "templateType": "anything", "can_override": false}, "f": {"name": "f", "group": "Part b", "definition": "random(1..10)", "description": "

PART B

", "templateType": "anything", "can_override": false}, "h_coprime": {"name": "h_coprime", "group": "Part b", "definition": "h/gcd_hj", "description": "

PART B

", "templateType": "anything", "can_override": false}, "lcm2_j": {"name": "lcm2_j", "group": "Part b", "definition": "lcm2/j_coprime", "description": "

PART B

", "templateType": "anything", "can_override": false}, "j_coprime": {"name": "j_coprime", "group": "Part b", "definition": "j/gcd_hj", "description": "

PART B

", "templateType": "anything", "can_override": false}, "flcmhlcm": {"name": "flcmhlcm", "group": "Part b", "definition": "flcm2_g-hlcm2_j", "description": "

PART B

", "templateType": "anything", "can_override": false}, "g_coprime": {"name": "g_coprime", "group": "Part b", "definition": "g/gcd_fg", "description": "

PART B g_coprime

", "templateType": "anything", "can_override": false}, "gcd_hj": {"name": "gcd_hj", "group": "Part b", "definition": "gcd(h,j)", "description": "

PART B

", "templateType": "anything", "can_override": false}, "g": {"name": "g", "group": "Part b", "definition": "random(2..10 except f except j)", "description": "

PART B

", "templateType": "anything", "can_override": false}, "flcm2_g": {"name": "flcm2_g", "group": "Part b", "definition": "f_coprime*lcm2_g", "description": "

PART B

", "templateType": "anything", "can_override": false}, "lcm2_g": {"name": "lcm2_g", "group": "Part b", "definition": "lcm2/g_coprime", "description": "

PART B

", "templateType": "anything", "can_override": false}, "f_coprime": {"name": "f_coprime", "group": "Part b", "definition": "f/gcd_fg", "description": "

PART B

", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": [], "variable_groups": [{"name": "Part b", "variables": ["f", "f_coprime", "g", "g_coprime", "gcd_fg", "h", "h_coprime", "j", "j_coprime", "gcd_hj", "lcm2", "lcm2_g", "flcm2_g", "lcm2_j", "hlcm2_j", "flcmhlcm"]}], "functions": {}, "preamble": {"js": "", "css": "fraction {\n display: inline-block;\n vertical-align: middle;\n}\nfraction > numerator, fraction > denominator {\n float: left;\n width: 100%;\n text-align: center;\n line-height: 2.5em;\n}\nfraction > numerator {\n border-bottom: 1px solid;\n padding-bottom: 5px;\n}\nfraction > denominator {\n padding-top: 5px;\n}\nfraction input {\n line-height: 1em;\n}\n\nfraction .part {\n margin: 0;\n}\n\n.table-responsive, .fractiontable {\n display:inline-block;\n}\n.fractiontable {\n padding: 0; \n border: 0;\n}\n\n.fractiontable .tddenom \n{\n text-align: center;\n}\n\n.fractiontable .tdnum \n{\n border-bottom: 1px solid black; \n text-align: center;\n}\n\n\n.fractiontable tr {\n height: 3em;\n}\n"}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

$\\displaystyle\\frac{\\var{f_coprime}}{\\var{g_coprime}}-\\frac{\\var{h_coprime}}{\\var{j_coprime}}=$  [[0]] [[1]]

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": "2", "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "flcmhlcm", "maxValue": "flcmhlcm", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "lcm2", "maxValue": "lcm2", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NG7 - Simplify (cancel down) Fractions - top heavy", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Lauren Richards", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1589/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}], "tags": ["converting improper fractions to mixed numbers", "converting mixed numbers to improper fractions", "equivalent fractions", "improper fractions", "mixed numbers"], "metadata": {"description": "

This question tests the student's ability to identify equivalent fractions through spotting a fraction which is not equivalent amongst a list of otherwise equivalent fractions. It also tests the students ability to convert mixed numbers into their equivalent improper fractions. It then does the reverse and tests their ability to convert an improper fraction into an equivalent mixed number. 

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "", "advice": "

A mixed number is a number consisting of an integer and a proper fraction, i.e. a number in the form $ a \\displaystyle \\frac{b}{c}$ where $a$ is an integer and $\\displaystyle\\frac{b}{c}$ is a proper fraction: $b$ is smaller than $c$.

\n

An improper fraction is a fraction where the numerator is larger than the denominator, i.e. a number of the form $\\displaystyle\\frac{d}{e}$ where the numerator, $d$, is greater than the denominator, $e$.

\n

To convert an improper fraction into a mixed number, find out how many times the denominator \\var{h_coprime/gcdb} goes into the numerator \\var{num/gcdb}. You can do this by dividing the numerator by the denominator and taking the whole number part or you can just add the denominator to itself until one more addition would make it bigger. This gives us a whole number part of our mixed fraction of \\var{f}.

\n

The numerator of our mixed fraction is what is left from dividing out the whole number. For this question that is $\\var{num/gcdb}-\\var{f*h_coprime}.

\n

Finally the denominator of our mixed fraction is just the denominator of the improper fraction.

\n

\\[
\\frac{\\var{num/gcdb}}{\\var{h_coprime/gcdb}} = {\\var{f}\\frac{\\var{g_coprime}}{\\var{h_coprime}}}\\text{.}
\\] 

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"g": {"name": "g", "group": "Ungrouped variables", "definition": "random(1..h except h)", "description": "

Random number between 1 and 15

", "templateType": "anything", "can_override": false}, "g_coprime": {"name": "g_coprime", "group": "Ungrouped variables", "definition": "g/gcd_gh", "description": "

PART C

", "templateType": "anything", "can_override": false}, "gcd_gh": {"name": "gcd_gh", "group": "Ungrouped variables", "definition": "gcd(g,h)", "description": "

PART C

", "templateType": "anything", "can_override": false}, "num": {"name": "num", "group": "Ungrouped variables", "definition": "((h_coprime*f)+g_coprime)", "description": "

numerator for the improper fraction c(i)

", "templateType": "anything", "can_override": false}, "h": {"name": "h", "group": "Ungrouped variables", "definition": "random(10 .. 24#1)", "description": "

Random number between 1 and 24

", "templateType": "randrange", "can_override": false}, "h_coprime": {"name": "h_coprime", "group": "Ungrouped variables", "definition": "h/gcd_gh", "description": "

PART C

", "templateType": "anything", "can_override": false}, "gcdb": {"name": "gcdb", "group": "Ungrouped variables", "definition": "gcd({num},{h_coprime})", "description": "

gcd of num and h

", "templateType": "anything", "can_override": false}, "f": {"name": "f", "group": "Ungrouped variables", "definition": "random(2 .. 5#1)", "description": "

Random number between 1 and 5

", "templateType": "randrange", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["f", "g", "h", "gcd_gh", "g_coprime", "h_coprime", "num", "gcdb"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": "fraction {\n display: inline-block;\n vertical-align: middle;\n}\nfraction > numerator, fraction > denominator {\n float: left;\n width: 100%;\n text-align: center;\n line-height: 2.5em;\n}\nfraction > numerator {\n border-bottom: 1px solid;\n padding-bottom: 5px;\n}\nfraction > denominator {\n padding-top: 5px;\n}\nfraction input {\n line-height: 1em;\n}\n\nfraction .part {\n margin: 0;\n}\n\n.table-responsive, .fractiontable {\n display:inline-block;\n}\n.fractiontable {\n padding: 0; \n border: 0;\n}\n\n.fractiontable .tddenom \n{\n text-align: center;\n}\n\n.fractiontable .tdnum \n{\n border-bottom: 1px solid black; \n text-align: center;\n}\n\n\n.fractiontable tr {\n height: 3em;\n}\n"}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Write the improper fraction as a mixed number and reduce it down to its simplest form. 

\n

$\\displaystyle{\\frac{\\var{num/gcdb}}{\\var{h_coprime/gcdb}}} = $ [[2]] [[0]] [[1]] .

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "g_coprime", "maxValue": "g_coprime", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "h_coprime", "maxValue": "h_coprime", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "f", "maxValue": "f", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NH1 FDP convert 1 - Percentage into fraction", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Lauren Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21504/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

Convert a percentage to a fraction.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Convert $\\var{perc}$% into its equivalent fraction expressed in its simplest form.

", "advice": "

Percentages can be converted to fractions by treating them as fractions out of $100$:

\n

\\[\\frac{\\var{perc}}{100},\\]

\n

and then simplifying. In this case giving:

\n

\\[\\frac{\\var{ansn}}{\\var{ansd}}\\]

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"perc": {"name": "perc", "group": "Ungrouped variables", "definition": "random(20 .. 90#10)", "description": "", "templateType": "randrange", "can_override": false}, "ansn": {"name": "ansn", "group": "Ungrouped variables", "definition": "perc/GCD(perc,100)", "description": "", "templateType": "anything", "can_override": false}, "ansd": {"name": "ansd", "group": "Ungrouped variables", "definition": "100/GCD(perc,100)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["perc", "ansn", "ansd"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

[[0]] numerator

\n
\n

[[1]] denominator

", "gaps": [{"type": "numberentry", "useCustomName": true, "customName": "Numerator", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": false, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "ansn", "maxValue": "ansn", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": true, "customName": "Denominator", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": false, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "ansd", "maxValue": "ansd", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NJ3 - Dividing amounts in ratios", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

Dividing amounts in ratios

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

The ratio of ethanol to water is {a}:{b} for an experiment. If I have {volWater}ml of water, how much ethanol do I need?

", "advice": "

If there is a ratio of {a}:{b} for ethanol:water then that means for every {b}ml of water we need {a}ml of ethanol.

\n

In our experiment there is {volwater}ml of water so to find the amount of ethanol we divide by {b} and then multiply by {a}.

\n

\\[\\var{volwater}\\text{ml}\\times\\frac{\\var{a}}{\\var{b}}=\\var{volwater*a/b}\\text{ml}\\]

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"a": {"name": "a", "group": "Ungrouped variables", "definition": "random(1..12)", "description": "", "templateType": "anything", "can_override": false}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "random(1..12 except a)", "description": "", "templateType": "anything", "can_override": false}, "volwater": {"name": "volwater", "group": "Ungrouped variables", "definition": "UsedforVol-mod(UsedforVol,b)", "description": "", "templateType": "anything", "can_override": false}, "UsedforVol": {"name": "UsedforVol", "group": "Ungrouped variables", "definition": "random(70..1000)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["a", "b", "volwater", "UsedforVol"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

[[0]]ml

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "volwater/b*a", "maxValue": "volwater/b*a", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NK3 - Standard Form (Calculations)", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

Calculations involving Standard form.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "", "advice": "

To divide two numbers in standard form we can calculate the division of each part of the standard form number separately. In general we have,

\n

\\[\\frac{x\\times10^j}{y\\times10^k}=\\frac xy\\times\\frac{10^j}{10^k}=\\frac xy\\times 10^{j-k}\\]

\n

\n

In this question we therefore have,

\n

\\[\\frac{\\var{a}\\times10^{\\var{n}}}{\\var{b}\\times10^{\\var{m}}}=\\frac{\\var{a}}{\\var{b}}\\times\\frac{10^{\\var{n}}}{10^{\\var{m}}}=\\var{aDivBRound}\\times10^\\var{n-m}.\\]

\n
\n

Since {aDivBRound} is less than 1 then our answer isn't in standard form. In this case we need to reduce the exponent by 1 so the final answer is

\n

\\[\\var{MantAnsRound}\\times10^{\\var{ExponentAns}}.\\]

\n
\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"a": {"name": "a", "group": "Ungrouped variables", "definition": "random(1..9.9 # 0.1)", "description": "", "templateType": "anything", "can_override": false}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "random(1..9.9 # 0.1)", "description": "", "templateType": "anything", "can_override": false}, "n": {"name": "n", "group": "Ungrouped variables", "definition": "random(-10..10)", "description": "", "templateType": "anything", "can_override": false}, "m": {"name": "m", "group": "Ungrouped variables", "definition": "random(-10..10)", "description": "", "templateType": "anything", "can_override": false}, "IsADivBLessOne": {"name": "IsADivBLessOne", "group": "Ungrouped variables", "definition": "a/b<1", "description": "", "templateType": "anything", "can_override": false}, "ExponentAns": {"name": "ExponentAns", "group": "Ungrouped variables", "definition": "if(IsADivBLessOne,n-m-1,n-m)", "description": "", "templateType": "anything", "can_override": false}, "MantAns": {"name": "MantAns", "group": "Ungrouped variables", "definition": "if(IsADivBLessOne, a/b*10, a/b)", "description": "", "templateType": "anything", "can_override": false}, "aDivBRound": {"name": "aDivBRound", "group": "Ungrouped variables", "definition": "precround(a/b,2)", "description": "", "templateType": "anything", "can_override": false}, "MantAnsRound": {"name": "MantAnsRound", "group": "Ungrouped variables", "definition": "precround(MantAns,2)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["a", "b", "n", "m", "IsADivBLessOne", "ExponentAns", "MantAns", "aDivBRound", "MantAnsRound"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

For the equation

\n

\\[\\frac{\\var{a}\\times10^{\\var{n}}}{\\var{b}\\times10^{\\var{m}}}=a\\times10^n\\]

\n

find the values of $a$ and $n$ which keep the answer in standard form.

\n

Give $a$ to two decimal places.

\n

$a=$[[0]]

$n=$[[1]]

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "MantAns", "maxValue": "MantAns", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "2", "precisionPartialCredit": 0, "precisionMessage": "You have not given your answer to the correct precision.", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "ExponentAns", "maxValue": "ExponentAns", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AA3 Indices - Fractional 1", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": ["category: Indices"], "metadata": {"description": "

Calculate an answer involving a fractional index.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Evaluate the following expression:

\n

\\[\\var{a^n}^{\\frac{1}{\\var{n}}}\\]

", "advice": "

To find $\\var{a^n}^{\\frac{1}{\\var{n}}}$, we want to make use of the fact that a power of $\\frac{1}{n}$ is the same as the $n$th root. Since

\n

\\[\\var{a^n}=\\var{a}^\\var{n},\\]

\n

we have,

\n

\\[ \\var{a^n}^{\\frac{1}{\\var{n}}} =\\left(\\var{a}^\\var{n}\\right)^{\\frac{1}{\\var{n}}}=\\var{a}. \\]

\n

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"n": {"name": "n", "group": "Ungrouped variables", "definition": "random(2..3)", "description": "", "templateType": "anything", "can_override": false}, "a": {"name": "a", "group": "Ungrouped variables", "definition": "random(1,2,3,4,5)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["n", "a"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "{a}", "maxValue": "{a}", "correctAnswerFraction": false, "allowFractions": true, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AA5 - Indices - negative", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

perform a calculation involving negative indices.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Evaluate and simplify the following expression:

\n

\\[\\frac{\\var{x}^\\var{n}}{\\var{y}^\\var{m}}\\]

", "advice": "

To simplify this expression we use the rule $a^{-n}=\\frac1{a^n}$.

\n

\\[\\frac{\\var{x}^\\var{n}}{\\var{y}^\\var{m}}=\\frac{\\var{y}^\\var{-m}}{\\var{x}^\\var{-n}}=\\frac{\\var{y^-m}}{\\var{x^-n}}=\\simplify{{y^-m}/{x^-n}}\\]

\n

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"n": {"name": "n", "group": "Ungrouped variables", "definition": "random(-3..-1)", "description": "", "templateType": "anything", "can_override": false}, "x": {"name": "x", "group": "Ungrouped variables", "definition": "random(2..5)", "description": "", "templateType": "anything", "can_override": false}, "y": {"name": "y", "group": "Ungrouped variables", "definition": "random(2..5)", "description": "", "templateType": "anything", "can_override": false}, "m": {"name": "m", "group": "Ungrouped variables", "definition": "random(-3..-1)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["n", "x", "y", "m"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "{x^n/y^m}", "maxValue": "{x^n/y^m}", "correctAnswerFraction": true, "allowFractions": true, "mustBeReduced": true, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AB7 Expand Double Brackets", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Poppy Jeffries", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21275/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

Expanding two linear brackets multiplied together.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Expand the brackets and simplify

", "advice": "

To expand the brackets $\\simplify{({a[1]}x+{a[2]})({a[3]}x+{a[4]})}$ We first multiply all the terms in the left bracket by all the terms in the right bracket. This gives us

\n

\\[\\var{a[1]}\\times\\var{a[3]}x^2+\\var{a[1]}x\\times\\var{a[4]}+\\var{a[2]}\\times\\var{a[3]}x+\\var{a[2]}\\times\\var{a[4]}=\\var{a[1]*a[3]}x^2+\\var{a[1]*a[4]}x+\\var{a[2]*a[3]}x+\\var{a[2]*a[4]}.\\]

\n

We can then collect the terms to give us the final answer of

\n

\\[\\var{a[1]*a[3]}x^2+\\var{a[1]*a[4]+a[2]*a[3]}x+\\var{a[2]*a[4]}.\\]

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"a": {"name": "a", "group": "Ungrouped variables", "definition": "repeat(random(-10..10 except [0] ),5)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["a"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

$\\simplify{({a[1]}x+{a[2]})({a[3]}x+{a[4]})}=$[[0]]

", "gaps": [{"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "answer": "{a[1]*a[3]}x^2+{a[1]*a[4]+a[2]*a[3]}x+{a[2]*a[4]}", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "mustmatchpattern": {"pattern": "`+-$n`?*x^2+`+-$n`?*x+`+-$n`?", "partialCredit": 0, "message": "", "nameToCompare": ""}, "valuegenerators": [{"name": "x", "value": ""}]}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AC2 Solve Linear equations with fractions 1", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Ben Brawn", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/605/"}, {"name": "heike hoffmann", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2960/"}, {"name": "sean hunte", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3167/"}, {"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}, {"name": "Megan Oliver", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23526/"}], "tags": [], "metadata": {"description": "

Solve linear equations with unkowns on both sides. Including brackets and fractions.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "", "advice": "

\n

To solve an equation like

\n

$\\displaystyle{\\frac{x+\\var{num1}}{\\var{num2}}+\\frac{x}{\\var{num3}}=\\var{num4}},$

\n

the first thing to deal with is the denominators of the fractions. In order to do that you multiply both sides of the equation by both denominators $\\var{num2}$ and $\\var{num3}$ (or their lowest common multiple to be slightly more efficient). This will give something equivalent to:

\n

$\\displaystyle{\\var{num3 + num2} x+\\var{num3*num1} = \\var{num2*num3*num4}.}$

\n

Then proceeding by subtracting $\\var{num3*num1} from both sides:

\n

$\\displaystyle{\\var{num3 + num2} x = \\var{num2*num3*num4-num3*num1}.}$

\n

And finally dividing by $\\var{num2+num3}$:

\n

$\\displaystyle{x = \\frac{\\var{num2*num3*num4-num3*num1}}{\\var{num2+num3}}.}$

\n


Use this link to find resources to help you revise how to solve linear equations

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"num1": {"name": "num1", "group": "Ungrouped variables", "definition": "random(-9..9)", "description": "", "templateType": "anything", "can_override": false}, "num2": {"name": "num2", "group": "Ungrouped variables", "definition": "random(2..15)", "description": "", "templateType": "anything", "can_override": false}, "num3": {"name": "num3", "group": "Ungrouped variables", "definition": "random(2..9 except num2)", "description": "", "templateType": "anything", "can_override": false}, "num4": {"name": "num4", "group": "Ungrouped variables", "definition": "random(-15..15)", "description": "", "templateType": "anything", "can_override": false}, "ans": {"name": "ans", "group": "Ungrouped variables", "definition": "(num4*num3*num2-num1*num3)/(num2+num3)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": "100"}, "ungrouped_variables": ["num1", "num2", "num3", "num4", "ans"], "variable_groups": [{"name": "e", "variables": []}], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Solve $\\displaystyle{\\frac{x+\\var{num1}}{\\var{num2}}+\\frac{x}{\\var{num3}}=\\var{num4}}$.

\n

$x=$ [[0]]

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "{ans}", "maxValue": "{ans}", "correctAnswerFraction": true, "allowFractions": true, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AC4 Simultaneous Equations (2 linear)", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}], "tags": ["Category: Simultaneous equations"], "metadata": {"description": "

Solving a pair of linear simultaneous equations, giving answers as integers or fractions.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Solve the simultaneous equations for x and y, giving your answers as integers or fractions, but not decimals.

\n

\\[ \\begin{split} \\simplify[!noLeadingminus,unitFactor]{{a}x+{b}y} &\\,=\\var{c} \\\\ \\simplify[!noLeadingminus,unitFactor]{{a1}x +{b1}y}  &\\,=\\var{c1} \\end{split}\\]

", "advice": "

\\[\\begin{split}\\simplify[!noLeadingminus,unitFactor]{{a}x+{b}y} &\\,=\\var{c} \\qquad\\qquad&(1)\\\\ \\simplify[!noLeadingminus,unitFactor]{{a1}x +{b1}y}  &\\,=\\var{c1} \\qquad\\qquad&(2)\\end{split}\\]

\n

{advice1}

\n

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"a": {"name": "a", "group": "Ungrouped variables", "definition": "random(-2..8 except [0,1])", "description": "", "templateType": "anything", "can_override": false}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "random(-8..8 except [0,1,a])", "description": "", "templateType": "anything", "can_override": false}, "a1": {"name": "a1", "group": "Ungrouped variables", "definition": "random(-5..8 except [0,1])", "description": "", "templateType": "anything", "can_override": false}, "b1": {"name": "b1", "group": "Ungrouped variables", "definition": "random(2..10 except [round(a1*b/a),b,0,1])", "description": "", "templateType": "anything", "can_override": false}, "c": {"name": "c", "group": "Ungrouped variables", "definition": "random(-6..6 except 0)", "description": "", "templateType": "anything", "can_override": false}, "c1": {"name": "c1", "group": "Ungrouped variables", "definition": "random(-7..7 except 0)", "description": "", "templateType": "anything", "can_override": false}, "aorsb": {"name": "aorsb", "group": "Ungrouped variables", "definition": "if(b*abs(b1)=b1*abs(b),'subtract','add')", "description": "", "templateType": "anything", "can_override": false}, "torfb": {"name": "torfb", "group": "Ungrouped variables", "definition": "if(b*abs(b1)=b1*abs(b),'from','to')", "description": "", "templateType": "anything", "can_override": false}, "sgn": {"name": "sgn", "group": "Ungrouped variables", "definition": "if(b*abs(b1)=b1*abs(b),-1,1)", "description": "", "templateType": "anything", "can_override": false}, "xn": {"name": "xn", "group": "Ungrouped variables", "definition": "c*abs(b1)+sgn*c1*abs(b)", "description": "", "templateType": "anything", "can_override": false}, "xd": {"name": "xd", "group": "Ungrouped variables", "definition": "a*abs(b1)+sgn*a1*abs(b)", "description": "", "templateType": "anything", "can_override": false}, "xsimp": {"name": "xsimp", "group": "Ungrouped variables", "definition": "xn/xd", "description": "", "templateType": "anything", "can_override": false}, "samex": {"name": "samex", "group": "Ungrouped variables", "definition": "\"

For these equations, it is easiest to get a solution for $y$ first, due to the $x$-terms having {eqoroppa} coefficients.

\\n

If we {aorsa} equation (2) {torfa} equation (1) this eliminates the $x$-terms leaving us with one equation in terms of $y$:

\\n

\\\\[ \\\\begin{split} \\\\simplify[!collectNumbers, !noLeadingminus]{({b}+{sgna*(b1)})y} &\\\\,= \\\\simplify[!collectNumbers, !noLeadingminus]{{c}+{sgna*(c1)}}\\\\\\\\ \\\\simplify{{b+sgna*(b1)}y} &\\\\,= \\\\simplify{{c+sgna*(c1)}} \\\\\\\\ y &\\\\,= \\\\simplify[all, fractionNumbers]{{c+sgna*(c1)}/{b+sgna*(b1)}} \\\\end{split} \\\\]

\\n

\\n

To obtain a solution for $x$ we can substitute this $y$-value into either of our initial equations. Using equation (1), we obtain

\\n

\\\\[ \\\\begin{split} \\\\var{a}x + \\\\var{b} \\\\times \\\\simplify[all, fractionNumbers]{{c+sgna*(c1)}/{b+sgna*(b1)}} &\\\\,= \\\\var{c} \\\\\\\\ \\\\var{a}x &\\\\,= \\\\simplify[all, !collectNumbers, !noLeadingminus]{{c} - {c*b+b*sgna*(c1)}/{b+sgna*(b1)}} \\\\\\\\ x &\\\\,= \\\\simplify[fractionNumbers]{{(c*abs(b1)+sgn*c1*abs(b))/(a*abs(b1)+sgn*a1*abs(b))}}. \\\\end{split} \\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "eqoroppb": {"name": "eqoroppb", "group": "Ungrouped variables", "definition": "if(abs(b)*b1=abs(b1)*b,'equal','equal and opposite')", "description": "", "templateType": "anything", "can_override": false}, "eqoroppa": {"name": "eqoroppa", "group": "Ungrouped variables", "definition": "if(abs(a)*a1=abs(a1)*a,'equal','equal and opposite')", "description": "", "templateType": "anything", "can_override": false}, "samey": {"name": "samey", "group": "Ungrouped variables", "definition": "\"

For these equations, it is easiest to get a solution for $x$ first, due to the $y$-terms having {eqoroppb} coefficients.

\\n

If we {aorsb} equation (2) {torfb} equation (1) this eliminates the $y$-terms, leaving us with one equation in terms of $x$:

\\n

\\\\[ \\\\begin{split} \\\\simplify[!collectNumbers, !noLeadingminus]{({a}+{sgn*(a1)})x} &\\\\,= \\\\simplify[!collectNumbers, !noLeadingminus]{{c}+{sgn*(c1)}}\\\\\\\\ \\\\simplify{{a+sgn*(a1)}x} &\\\\,= \\\\simplify{{c+sgn*(c1)}} \\\\\\\\ x &\\\\,= \\\\simplify[all, fractionNumbers]{{c+sgn*(c1)}/{a+sgn*(a1)}} \\\\end{split} \\\\]

\\n

\\n

To obtain a solution for $y$ we can substitute this $x$-value into either of our initial equations. Using equation (1), we obtain

\\n

\\\\[ \\\\begin{split} \\\\var{a} \\\\times\\\\simplify[fractionNumbers]{{c+sgn*(c1)}/{a+sgn*(a1)}} + \\\\var{b}y &\\\\,= \\\\var{c} \\\\\\\\ \\\\var{b}y &\\\\,= \\\\simplify[!collectNumbers, !noLeadingminus]{{c} - {c*a+a*sgn*(c1)}/{a+sgn*(a1)}} \\\\\\\\ y &\\\\,= \\\\simplify[fractionNumbers]{{(c-a*xsimp)/b}}. \\\\end{split} \\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "lcmb": {"name": "lcmb", "group": "Ungrouped variables", "definition": "\"

To get a solution for $x$, if we multiply equation (2) by $\\\\simplify{{abs(b/b1)}}$ we will have two equations with {eqoroppb} $y$-coefficients:

\\n

\\\\[ \\\\begin{split} \\\\simplify[!noLeadingminus,unitFactor]{{a}x+{b}y} &\\\\,=\\\\var{c} \\\\qquad\\\\qquad&(3)\\\\\\\\ \\\\simplify[!noLeadingminus,unitFactor]{{a1*abs(b/b1)}x +{b1*abs(b/b1)}y}  &\\\\,=\\\\var{c1*abs(b/b1)} \\\\qquad\\\\qquad&(4)\\\\end{split}\\\\]

\\n

If we {aorsb} equation (4) {torfb} equation (3) this eliminates the $y$-terms, leaving us with one equation in terms of $x$:

\\n

\\\\[ \\\\begin{split} \\\\simplify[!collectNumbers, !noLeadingminus]{({a}+{sgn*(a1*abs(b/b1))})x} &\\\\,= \\\\simplify[all, !collectNumbers, !noLeadingminus]{{c}+{sgn*(c1*abs(b/b1))}}\\\\\\\\ \\\\simplify{{a+sgn*(a1*abs(b/b1))}x} &\\\\,= \\\\simplify{{c+sgn*(c1*abs(b/b1))}} \\\\\\\\ x &\\\\,= \\\\simplify[all,fractionNumbers]{{c+sgn*(c1*abs(b/b1))}/{a+sgn*(a1*abs(b/b1))}}. \\\\end{split} \\\\]

\\n

\\n

To obtain a solution for $y$ we can substitute this $x$-value into either of our initial equations. Using equation (1), we obtain

\\n

\\\\[ \\\\begin{split} \\\\var{a}\\\\times\\\\simplify[all, !noLeadingminus, !expandBrackets, fractionNumbers]{({c+sgn*c1*abs(b/b1)}/{(a)+sgn*a1*abs(b/b1)}) + {b}y} &\\\\,= \\\\var{c} \\\\\\\\ \\\\simplify{{b}y} &\\\\,= \\\\simplify[all, !noLeadingminus, fractionNumbers]{{c} -({(a*c)+a*sgn*c1*abs(b/b1)}/{(a)+sgn*a1*abs(b/b1)})} \\\\\\\\ \\\\simplify{{b}y} &\\\\,= \\\\simplify[all, !noLeadingminus, fractionNumbers]{{c -(a*c+a*sgn*c1*abs(b/b1))/(a+sgn*a1*abs(b/b1))}} \\\\\\\\ y &\\\\,=\\\\simplify[fractionNumbers]{{(c-a*xsimp)/b}}. \\\\end{split} \\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "lcmb1": {"name": "lcmb1", "group": "Ungrouped variables", "definition": "\"

To get a solution for $x$, if we multiply equation (1) by $\\\\simplify{{abs(b1/b)}}$ we will have two equations with {eqoroppb} $y$-coefficients:

\\n

\\\\[ \\\\begin{split} \\\\simplify[!noLeadingminus,unitFactor]{{a*abs(b1/b)}x +{b*abs(b1/b)}y}  &\\\\,=\\\\var{c*abs(b1/b)} \\\\qquad\\\\qquad&(3) \\\\\\\\\\\\simplify[!noLeadingminus,unitFactor]{{a1}x+{b1}y} &\\\\,=\\\\var{c1} \\\\qquad\\\\qquad&(4)\\\\\\\\ \\\\end{split} \\\\]

\\n

If we {aorsb} equation (4) {torfb} equation (3) this eliminates the $y$-terms, leaving us with one equation in terms of $x$:

\\n

\\\\[ \\\\begin{split} \\\\simplify[!collectNumbers, !noLeadingminus]{({(a*abs(b1/b))}+{sgn*a1})x} &\\\\,= \\\\simplify[!collectNumbers, !noLeadingminus]{{(c*abs(b1/b))}+{sgn*c1}}\\\\\\\\ \\\\simplify{{(a*abs(b1/b))+sgn*a1}x} &\\\\,= \\\\simplify{{(c*abs(b1/b))+sgn*c1}} \\\\\\\\ x &\\\\,= \\\\simplify[all, fractionNumbers]{{(c*abs(b1/b))+sgn*c1}/{(a*abs(b1/b))+sgn*a1}}. \\\\end{split} \\\\]

\\n

\\n

To obtain a solution for $y$ we can substitute this $x$-value into either of our initial equations. Using equation (1), we obtain

\\n

\\\\[ \\\\begin{split} \\\\var{a}\\\\times\\\\simplify[all, !noLeadingminus, !expandBrackets, fractionNumbers]{({(c*abs(b1/b))+sgn*c1}/{(a*abs(b1/b))+sgn*a1}) + {b}y} &\\\\,= \\\\var{c} \\\\\\\\ \\\\simplify{{b}y} &\\\\,= \\\\simplify[all, !noLeadingminus, fractionNumbers]{{c} -({(a*c*abs(b1/b))+a*sgn*c1}/{(a*abs(b1/b))+sgn*a1})} \\\\\\\\ \\\\simplify{{b}y} &\\\\,= \\\\simplify[all, !noLeadingminus, fractionNumbers]{{c -(a*c*abs(b1/b)+a*sgn*c1)/(a*abs(b1/b)+sgn*a1)}} \\\\\\\\ y &\\\\,=\\\\simplify[fractionNumbers]{{(c-a*xsimp)/b}}. \\\\end{split} \\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "full": {"name": "full", "group": "Ungrouped variables", "definition": "\"

To get a solution for $x$, if we multiply equation (1) by $\\\\var{abs(b1)}$ and equation (2) by $\\\\var{abs(b)}$, we will have two equations with {eqoroppb} $y$-coefficients:

\\n

\\\\[ \\\\begin{split} \\\\simplify[!noLeadingminus,unitFactor]{{a*abs(b1)}x+{b*abs(b1)}y} &\\\\,=\\\\var{c*abs(b1)} \\\\qquad\\\\qquad&(3)\\\\\\\\\\\\simplify[!noLeadingminus,unitFactor]{{a1*abs(b)}x +{b1*abs(b)}y}  &\\\\,=\\\\var{c1*abs(b)} \\\\qquad\\\\qquad&(4) \\\\end{split}\\\\]

\\n

Now, {aorsb} equation (4) {torfb} equation (3) to eliminate the $y$ terms:

\\n

\\\\[ \\\\begin{split} (\\\\simplify[!collectNumbers]{{a*abs(b1)} +{sgn*a1*abs(b)}}) x &\\\\,= \\\\simplify[!collectNumbers]{{c*abs(b1)}+{sgn*c1*abs(b)}} \\\\\\\\  \\\\simplify{{a*abs(b1)+sgn*a1*abs(b)}} x &\\\\,= \\\\simplify{{c*abs(b1)+sgn*c1*abs(b)}} .\\\\end{split} \\\\]

\\n

So the solution for $x$ is \\\\[ x=\\\\simplify{{c*abs(b1)+sgn*c1*abs(b)}/{a*abs(b1)+sgn*a1*abs(b)}}.\\\\]

\\n

To obtain a solution for $y$ we can substitute this value of $x$ into either of our initial equations. Using equation (1), we obtain

\\n

\\\\[ \\\\begin{split} \\\\simplify[noLeadingminus,fractionNumbers,unitFactor]{{a}  {xsimp} + {b}y} &\\\\,=\\\\var{c} \\\\\\\\ \\\\var{b}y &\\\\,= \\\\simplify[!collectNumbers,fractionNumbers]{{c}-{a*xsimp}} \\\\\\\\\\\\var{b}y &\\\\,= \\\\simplify[fractionNumbers]{{c-a*xsimp}} \\\\\\\\y &\\\\,= \\\\simplify[fractionNumbers]{{(c-a*xsimp)/b}} \\\\end{split} \\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "aorsa": {"name": "aorsa", "group": "Ungrouped variables", "definition": "if(a*abs(a1)=abs(a)*a1,'subtract','add')", "description": "", "templateType": "anything", "can_override": false}, "torfa": {"name": "torfa", "group": "Ungrouped variables", "definition": "if(a*abs(a1)=abs(a)*a1,'from','to')", "description": "", "templateType": "anything", "can_override": false}, "sgna": {"name": "sgna", "group": "Ungrouped variables", "definition": "if(a*abs(a1)=abs(a)*a1,-1,1)", "description": "", "templateType": "anything", "can_override": false}, "lcma": {"name": "lcma", "group": "Ungrouped variables", "definition": "\"

To get a solution for $y$, if we multiply equation (2) by $\\\\simplify{{abs(a/a1)}}$ we will have two equations with {eqoroppa} $x$-coefficients:

\\n

\\\\[ \\\\begin{split} \\\\simplify[!noLeadingminus,unitFactor]{{a}x+{b}y} &\\\\,=\\\\var{c} \\\\qquad\\\\qquad&(3)\\\\\\\\ \\\\simplify[!noLeadingminus,unitFactor]{{a1*abs(a/a1)}x +{b1*abs(a/a1)}y}  &\\\\,=\\\\var{c1*abs(a/a1)} \\\\qquad\\\\qquad&(4)\\\\end{split}\\\\]

\\n

If we {aorsa} equation (4) {torfa} equation (3) this eliminates the $x$-terms, leaving us with one equation in terms of $y$:

\\n

\\\\[ \\\\begin{split} \\\\simplify[!collectNumbers, !noLeadingminus]{({b}+{sgna*(b1*abs(a/a1))})y} &\\\\,= \\\\simplify[all, !collectNumbers, !noLeadingminus]{{c}+{sgna*(c1*abs(a/a1))}}\\\\\\\\ \\\\simplify{{b+sgna*(b1*abs(a/a1))}y} &\\\\,= \\\\simplify{{c+sgna*(c1*abs(a/a1))}} \\\\\\\\ y &\\\\,= \\\\simplify[all,fractionNumbers]{{c+sgna*(c1*abs(a/a1))}/{b+sgna*(b1*abs(a/a1))}}. \\\\end{split} \\\\]

\\n

\\n

To obtain a solution for $x$ we can substitute this $y$-value into either of our initial equations. Using equation (1), we obtain

\\n

\\\\[ \\\\begin{split} \\\\simplify[all, !noLeadingminus, !expandBrackets, fractionNumbers]{{a}x + {b}}\\\\times \\\\simplify[all, !noLeadingminus, !expandBrackets, fractionNumbers]{({c+sgna*c1*abs(a/a1)}/{(b)+sgna*b1*abs(a/a1)})} &\\\\,= \\\\var{c} \\\\\\\\ \\\\simplify{{a}x} &\\\\,= \\\\simplify[all, !noLeadingminus, fractionNumbers]{{c} -({(b*c)+b*sgna*c1*abs(a/a1)}/{(b)+sgna*b1*abs(a/a1)})} \\\\\\\\ \\\\simplify{{a}x} &\\\\,= \\\\simplify[all, !noLeadingminus, fractionNumbers]{{c -(b*c+b*sgna*c1*abs(a/a1))/(b+sgna*b1*abs(a/a1))}} \\\\\\\\ x &\\\\,=\\\\simplify[fractionNumbers]{{(c*abs(b1)+sgn*c1*abs(b))/(a*abs(b1)+sgn*a1*abs(b))}}. \\\\end{split} \\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "lcma1": {"name": "lcma1", "group": "Ungrouped variables", "definition": "\"

To get a solution for $y$, if we multiply equation (1) by $\\\\simplify{{abs(a1/a)}}$ we will have two equations with {eqoroppa} $x$-coefficients:

\\n

\\\\[ \\\\begin{split} \\\\simplify[!noLeadingminus,unitFactor]{{a*abs(a1/a)}x +{b*abs(a1/a)}y}  &\\\\,=\\\\var{c*abs(a1/a)} \\\\qquad\\\\qquad&(3) \\\\\\\\\\\\simplify[!noLeadingminus,unitFactor]{{a1}x+{b1}y} &\\\\,=\\\\var{c1} \\\\qquad\\\\qquad&(4) \\\\end{split}\\\\]

\\n

If we {aorsa} equation (4) {torfa} equation (3) this eliminates the $x$-terms, leaving us with one equation in terms of $y$:

\\n

\\\\[ \\\\begin{split} \\\\simplify[!collectNumbers, !noLeadingminus]{({(b*abs(a1/a))}+{sgna*b1})y} &\\\\,= \\\\simplify[!collectNumbers, !noLeadingminus]{{(c*abs(a1/a))}+{sgna*c1}}\\\\\\\\ \\\\simplify{{(b*abs(a1/a))+sgna*b1}y} &\\\\,= \\\\simplify{{(c*abs(a1/a))+sgna*c1}} \\\\\\\\ y &\\\\,= \\\\simplify[all, fractionNumbers]{{(c*abs(a1/a))+sgna*c1}/{(b*abs(a1/a))+sgna*b1}}. \\\\end{split} \\\\]

\\n

\\n

To obtain a solution for $x$ we can substitute this $y$-value into either of our initial equations. Using equation (1), we obtain

\\n

\\\\[ \\\\begin{split} \\\\simplify[all, !noLeadingminus, !expandBrackets, fractionNumbers]{{a}x + {b}}\\\\times \\\\simplify[all, !noLeadingminus, !expandBrackets, fractionNumbers]{({c*abs(a1/a)+sgna*c1}/{(b*abs(a1/a))+sgna*b1})} &\\\\,= \\\\var{c} \\\\\\\\ \\\\simplify{{a}x} &\\\\,= \\\\simplify[all, !noLeadingminus, fractionNumbers]{{c} -({(b*c*abs(a1/a))+b*sgna*c1}/{(b*abs(a1/a))+sgna*b1})} \\\\\\\\ \\\\simplify{{a}x} &\\\\,= \\\\simplify[all, !noLeadingminus, fractionNumbers]{{c -(b*c*abs(a1/a)+b*sgna*c1)/(b*abs(a1/a)+sgna*b1)}} \\\\\\\\ x &\\\\,=\\\\simplify[fractionNumbers]{{(c*abs(b1)+sgn*c1*abs(b))/(a*abs(b1)+sgn*a1*abs(b))}}. \\\\end{split} \\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "advice1": {"name": "advice1", "group": "Ungrouped variables", "definition": "if(abs(b)=abs(b1), {samey},if(abs(a)=abs(a1),{samex},if(lcm(abs(b),abs(b1))=abs(b),{lcmb},if(lcm(abs(b),abs(b1))=abs(b1),{lcmb1},if(lcm(abs(a),abs(a1))=abs(a),{lcma},if(lcm(abs(a),abs(a1))=abs(a1),{lcma1},{full}))))))", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "abs(b-b1)>1 and\nabs(a-a1)>1 and\ngcd(a,c)=1 and\ngcd(a1,c1)=1", "maxRuns": 100}, "ungrouped_variables": ["a", "b", "a1", "b1", "c", "c1", "aorsa", "torfa", "aorsb", "torfb", "sgna", "sgn", "xn", "xd", "xsimp", "eqoroppa", "eqoroppb", "advice1", "samey", "samex", "lcmb", "lcmb1", "lcma", "lcma1", "full"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

$x=$ [[0]]

\n

$y=$ [[1]]

", "gaps": [{"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "answer": "{(c*abs(b1)+sgn*c1*abs(b))/(a*abs(b1)+sgn*a1*abs(b))}", "answerSimplification": "fractionNumbers", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": []}, {"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "answer": "{(c-a*xsimp)/b}", "answerSimplification": "fractionNumbers", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": []}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AC6 Rearrange Formulae", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Mash Sheffield", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4679/"}, {"name": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}, {"name": "Luigi Pivano", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/18182/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

Rearrange a specific formula. No randomisation.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Rearrange the following equation, to make $y$ the subject:

\n

\\[{cy -b = 3x}\\] 

", "advice": "

In order to rearrange the equation so that it is in terms of $y$, we must first add $b$ to both sides, and then divide both sides of the equation by $c$:

\n

\\begin{split} cy-b  &= 3x \\\\ cy &= 3x + b \\\\ y &=\\frac{3x+b}{c} \\end{split}

\n

\n

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

\n

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": [], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

$y=$ [[0]]

", "gaps": [{"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "answer": "(3x+b)/c", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": [{"name": "b", "value": ""}, {"name": "c", "value": ""}, {"name": "x", "value": ""}]}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AD1 Factorising a Quadratic (a=1)", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Chris Graham", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/369/"}, {"name": "Hannah Aldous", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1594/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}], "tags": ["factorisation", "Factorisation", "factorising quadratic equations", "Factorising quadratic equations", "taxonomy"], "metadata": {"description": "

Factorise three quadratic equations of the form $x^2+bx+c$.

\n

The first has two negative roots, the second has one negative and one positive, and the third is the difference of two squares.

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

Factorise the following quadratic equation.

", "advice": "

Quadratic equations of the form

\n

\\[x^2+bx+c=0\\]

\n

can be factorised to create an equation of the form

\n

\\[(x+m)(x+n)=0\\text{.}\\]

\n

When we expand a factorised quadratic expression we obtain

\n

\\[(x+m)(x+n)=x^2+(m+n)x+(m \\times n)\\text{.}\\]

\n

To factorise an equation of the form $x^2+bx+c$, we need to find two numbers which add together to make $b$, and multiply together to make $c$.

\n

\n

We need to find two values that add together to make $\\var{v3+v4}$ and multiply together to make $\\var{v3*v4}$.

\n

\\[\\begin{align}
\\var{v3} \\times \\var{v4}&=\\var{v3*v4}\\\\
\\var{v3}+\\var{v4}&=\\var{v3+v4}\\\\
\\end{align} \\]

\n

So the factorised form of the equation is

\n

\\[\\simplify{(x+{v3})(x+{v4})}=0\\text{.}\\]

\n

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"v1": {"name": "v1", "group": "Part A ", "definition": "random(1..10)", "description": "", "templateType": "anything", "can_override": false}, "v2": {"name": "v2", "group": "Part A ", "definition": "random(2..6 except v1)", "description": "", "templateType": "anything", "can_override": false}, "v4": {"name": "v4", "group": "Part A ", "definition": "random(1..10 except -v3)", "description": "", "templateType": "anything", "can_override": false}, "v5": {"name": "v5", "group": "Part A ", "definition": "random(2..10)", "description": "", "templateType": "anything", "can_override": false}, "v3": {"name": "v3", "group": "Part A ", "definition": "random(-8..-1)", "description": "", "templateType": "anything", "can_override": false}, "v6": {"name": "v6", "group": "Part A ", "definition": "-v5", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": [], "variable_groups": [{"name": "Part A ", "variables": ["v1", "v2", "v3", "v4", "v5", "v6"]}], "functions": {}, "preamble": {"js": "question.is_factorised = function(part,penalty) {\n penalty = penalty || 0;\n if(part.credit>0) {\n // Parse the student's answer as a syntax tree\n var studentTree = Numbas.jme.compile(part.studentAnswer,Numbas.jme.builtinScope);\n\n // Create the pattern to match against \n // we just want two sets of brackets, each containing two terms\n // or one of the brackets might not have a constant term\n // or for repeated roots, you might write (x+a)^2\n var rule = Numbas.jme.compile('m_all(m_any(x,x+m_pm(m_number),x^m_number,(x+m_pm(m_number))^m_number))*m_nothing');\n\n // Check the student's answer matches the pattern. \n var m = Numbas.jme.display.matchTree(rule,studentTree,true);\n // If not, take away marks\n if(!m) {\n part.multCredit(penalty,'Your answer is not fully factorised.');\n }\n }\n}", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

$\\simplify{x^2+{v3+v4}x+{v3*v4}}=0$

\n

[[0]] $=0$

\n

", "gaps": [{"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "answer": "(x+{v3})(x+{v4})", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "mustmatchpattern": {"pattern": "(`+-x^$n`? + `+- $n)`* * $z", "partialCredit": 0, "message": "Your answer is not fully factorised.", "nameToCompare": ""}, "valuegenerators": [{"name": "x", "value": ""}]}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AD2 Quadratics - solve", "extensions": [], "custom_part_types": [{"source": {"pk": 2, "author": {"name": "Christian Lawson-Perfect", "pk": 7}, "edit_page": "/part_type/2/edit"}, "name": "List of numbers", "short_name": "list-of-numbers", "description": "

The answer is a comma-separated list of numbers.

\n

The list is marked correct if each number occurs the same number of times as in the expected answer, and no extra numbers are present.

\n

You can optionally treat the answer as a set, so the number of occurrences doesn't matter, only whether each number is included or not.

", "help_url": "", "input_widget": "string", "input_options": {"correctAnswer": "join(\n if(settings[\"correctAnswerFractions\"],\n map(let([a,b],rational_approximation(x), string(a/b)),x,settings[\"correctAnswer\"])\n ,\n settings[\"correctAnswer\"]\n ),\n settings[\"separator\"] + \" \"\n)", "hint": {"static": false, "value": "if(settings[\"show_input_hint\"],\n \"Enter a list of numbers separated by {settings['separator']}.\",\n \"\"\n)"}, "allowEmpty": {"static": true, "value": true}}, "can_be_gap": true, "can_be_step": true, "marking_script": "bits:\nlet(b,filter(x<>\"\",x,split(studentAnswer,settings[\"separator\"])),\n if(isSet,list(set(b)),b)\n)\n\nexpected_numbers:\nlet(l,settings[\"correctAnswer\"] as \"list\",\n if(isSet,list(set(l)),l)\n)\n\nvalid_numbers:\nif(all(map(not isnan(x),x,interpreted_answer)),\n true,\n let(index,filter(isnan(interpreted_answer[x]),x,0..len(interpreted_answer)-1)[0], wrong, bits[index],\n warn(wrong+\" is not a valid number\");\n fail(wrong+\" is not a valid number.\")\n )\n )\n\nis_sorted:\nassert(sort(interpreted_answer)=interpreted_answer,\n multiply_credit(0.5,\"Not in order\")\n )\n\nincluded:\nmap(\n let(\n num_student,len(filter(x=y,y,interpreted_answer)),\n num_expected,len(filter(x=y,y,expected_numbers)),\n switch(\n num_student=num_expected,\n true,\n num_studentThe separate items in the student's answer

", "definition": "let(b,filter(x<>\"\",x,split(studentAnswer,settings[\"separator\"])),\n if(isSet,list(set(b)),b)\n)"}, {"name": "expected_numbers", "description": "", "definition": "let(l,settings[\"correctAnswer\"] as \"list\",\n if(isSet,list(set(l)),l)\n)"}, {"name": "valid_numbers", "description": "

Is every number in the student's list valid?

", "definition": "if(all(map(not isnan(x),x,interpreted_answer)),\n true,\n let(index,filter(isnan(interpreted_answer[x]),x,0..len(interpreted_answer)-1)[0], wrong, bits[index],\n warn(wrong+\" is not a valid number\");\n fail(wrong+\" is not a valid number.\")\n )\n )"}, {"name": "is_sorted", "description": "

Are the student's answers in ascending order?

", "definition": "assert(sort(interpreted_answer)=interpreted_answer,\n multiply_credit(0.5,\"Not in order\")\n )"}, {"name": "included", "description": "

Is each number in the expected answer present in the student's list the correct number of times?

", "definition": "map(\n let(\n num_student,len(filter(x=y,y,interpreted_answer)),\n num_expected,len(filter(x=y,y,expected_numbers)),\n switch(\n num_student=num_expected,\n true,\n num_studentHas every number been included the right number of times?

", "definition": "all(included)"}, {"name": "no_extras", "description": "

True if the student's list doesn't contain any numbers that aren't in the expected answer.

", "definition": "if(all(map(x in expected_numbers, x, interpreted_answer)),\n true\n ,\n incorrect(\"Your answer contains \"+extra_numbers[0]+\" but should not.\");\n false\n )"}, {"name": "interpreted_answer", "description": "A value representing the student's answer to this part.", "definition": "if(lower(studentAnswer) in [\"empty\",\"\u2205\"],[],\n map(\n if(settings[\"allowFractions\"],parsenumber_or_fraction(x,notationStyles), parsenumber(x,notationStyles))\n ,x\n ,bits\n )\n)"}, {"name": "mark", "description": "This is the main marking note. It should award credit and provide feedback based on the student's answer.", "definition": "if(studentanswer=\"\",fail(\"You have not entered an answer\"),false);\napply(valid_numbers);\napply(included);\napply(no_extras);\ncorrectif(all_included and no_extras)"}, {"name": "notationStyles", "description": "", "definition": "[\"en\"]"}, {"name": "isSet", "description": "

Should the answer be considered as a set, so the number of times an element occurs doesn't matter?

", "definition": "settings[\"isSet\"]"}, {"name": "extra_numbers", "description": "

Numbers included in the student's answer that are not in the expected list.

", "definition": "filter(not (x in expected_numbers),x,interpreted_answer)"}], "settings": [{"name": "correctAnswer", "label": "Correct answer", "help_url": "", "hint": "The list of numbers that the student should enter. The order does not matter.", "input_type": "code", "default_value": "", "evaluate": true}, {"name": "allowFractions", "label": "Allow the student to enter fractions?", "help_url": "", "hint": "", "input_type": "checkbox", "default_value": false}, {"name": "correctAnswerFractions", "label": "Display the correct answers as fractions?", "help_url": "", "hint": "", "input_type": "checkbox", "default_value": false}, {"name": "isSet", "label": "Is the answer a set?", "help_url": "", "hint": "If ticked, the number of times an element occurs doesn't matter, only whether it's included at all.", "input_type": "checkbox", "default_value": false}, {"name": "show_input_hint", "label": "Show the input hint?", "help_url": "", "hint": "", "input_type": "checkbox", "default_value": true}, {"name": "separator", "label": "Separator", "help_url": "", "hint": "The substring that should separate items in the student's list", "input_type": "string", "default_value": ",", "subvars": false}], "public_availability": "always", "published": true, "extensions": []}], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}, {"name": "Megan Oliver", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23526/"}], "tags": [], "metadata": {"description": "

Solving a quadratic equation via factorisation (or otherwise) with the $x^2$-term having a coefficient of 1.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Solve the following quadratic equation by factorisation or otherwise:

\n

\\[ \\simplify[unitFactor]{x^2+{b}x+{c}=0} \\]

", "advice": "

To solve a quadratic equation of the form \\[ x^2+bx+c=0\\] by factorisation, we want to factorise the equation into the form \\[(x+p)(x+q)=0,\\] where $p+q=b$ and $p \\times q = c$. 

\n

Hence, for the equation \\[\\simplify{x^2+{b}x+{c}=0}, \\]

\n

this can be factorised to \\[\\simplify{(x+{p})(x+{q})=0}.\\] This equation is satisfied when either \\[\\simplify{x+{p}=0} \\quad \\text{or} \\quad \\simplify{x+{q}=0}, \\] which implies the solutions to this quadratic equation are \\[ \\simplify{x={-p}} \\quad \\text{and} \\quad \\simplify{x={-q}} .\\]

\n

Use this link to find resources to help you revise how to solve quadratic equations by factorising the expression.

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"b": {"name": "b", "group": "Ungrouped variables", "definition": "{p+q}", "description": "", "templateType": "anything", "can_override": false}, "c": {"name": "c", "group": "Ungrouped variables", "definition": "{p*q}", "description": "", "templateType": "anything", "can_override": false}, "p": {"name": "p", "group": "Ungrouped variables", "definition": "random(-10..10 except 0)", "description": "", "templateType": "anything", "can_override": false}, "q": {"name": "q", "group": "Ungrouped variables", "definition": "random(-10..10 except [0,p])", "description": "", "templateType": "anything", "can_override": false}, "sol": {"name": "sol", "group": "Ungrouped variables", "definition": "[-p,-q]", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "abs(p+q)>0", "maxRuns": 100}, "ungrouped_variables": ["b", "c", "p", "q", "sol"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

$x= $[[0]]

", "gaps": [{"type": "list-of-numbers", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "settings": {"correctAnswer": "{sol}", "allowFractions": false, "correctAnswerFractions": false, "isSet": false, "show_input_hint": true, "separator": ","}}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AE1 - Algebraic fractions - addition", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Merryn Horrocks", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4052/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}], "tags": [], "metadata": {"description": "

Simplify (qx+a)/(rx+b) +/- (sx+c)/(tx+d)

\n

x is a randomised variable. a,b,c,d,q,r,s,t are randomised integers. a,b,c,d run from -5 to 5, including 0. q,r,s,t run from -3 to 3, and can be 0 if the constant term is nonzero, but are mostly 1.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Express $\\displaystyle{\\var{te[0]}\\var{sgnl}\\var{te[1]}}$ as a single fraction.

", "advice": "

\\[\\begin{align*} \\var{te[0]}\\var{sgnl}\\var{te[1]} &= \\frac{\\var{ndnde[3]}}{\\var{ndnde[3]}}\\times\\var{te[0]}\\var{sgnl}\\frac{\\var{ndnde[1]}}{\\var{ndnde[1]}}\\times\\var{te[1]}\\\\&=\\frac{\\var{cnd[0]}\\var{sgnl}\\var{cnd[1]}}{(\\var{ndnde[1]})(\\var{ndnde[3]})}\\\\&=\\frac{(\\var{cnd[2]})\\var{sgnl}(\\var{cnd[3]})}{(\\var{ndnde[1]})(\\var{ndnde[3]})}\\\\&=\\frac{\\var{cnd[4]}}{(\\var{ndnde[1]})(\\var{ndnde[3]})}\\\\&=\\var{ans} \\end{align*}\\]

\n

There is no benefit in expanding the denominator. In fact, it is best to leave the denominator factorised, because then it is easier to see if the fraction can be simplified.

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"te": {"name": "te", "group": "Ungrouped variables", "definition": "[simplify(expression(\"(\"+ndnd[0]+\")/(\"+ndnd[1]+\")\"),\"all\"),\n simplify(expression(\"(\"+ndnd[2]+\")/(\"+ndnd[3]+\")\"),\"all\")\n]", "description": "", "templateType": "anything", "can_override": false}, "v": {"name": "v", "group": "Ungrouped variables", "definition": "random(\"a\",\"b\",\"c\",\"d\",\"f\",\"g\",\"h\",\"k\",\"m\",\"n\",\"p\",\"q\",\"r\",\"s\",\"t\",\"u\",\"v\",\"w\",\"x\",\"y\",\"z\")", "description": "

the variable to use

", "templateType": "anything", "can_override": false}, "xc": {"name": "xc", "group": "Ungrouped variables", "definition": "repeat(weighted_random([ [1,0.7] , [random(1..3),0.3] ])\n ,4)", "description": "

the x-coefficients

", "templateType": "anything", "can_override": false}, "c": {"name": "c", "group": "Ungrouped variables", "definition": "map(\nswitch(xc[i]=0, random(2..5),\n xc[i]=1, random(-5..5 except 0),\n xc[i]=2, random(-5..5 except [-4,-2,2,4]),\n random(-5..5 except [-xc[i],xc[i]])\n),i,[0,1,2,3])", "description": "

the constants. Make sure that the constants are coprime with their x-coefficient, and if their x-coefficient is 0, that they are positive. There is a condition in variable testing to ensure that no fraction = 1.

", "templateType": "anything", "can_override": false}, "ndnd": {"name": "ndnd", "group": "Ungrouped variables", "definition": "[\"+\"+c[0],\n xc[1]+\"*\"+v+\"+\"+c[1],\n \"+\"+c[2],\n xc[3]+\"*\"+v+\"+\"+c[3]\n ]", "description": "

numerator 1, denominator 1, numerator 2, denominator 2, as strings.

", "templateType": "anything", "can_override": false}, "sgn": {"name": "sgn", "group": "Ungrouped variables", "definition": "random(\"+\",\"-\")", "description": "", "templateType": "anything", "can_override": false}, "sgnl": {"name": "sgnl", "group": "Ungrouped variables", "definition": "latex(sgn)", "description": "

for display purposes

", "templateType": "anything", "can_override": false}, "ndnde": {"name": "ndnde", "group": "Ungrouped variables", "definition": "map(simplify(expression(x),\"all\"),x,ndnd)", "description": "", "templateType": "anything", "can_override": false}, "cnd": {"name": "cnd", "group": "Ungrouped variables", "definition": "[simplify(expression(\"(\"+ndnd[3]+\")*(\"+ndnd[0]+\")\"),\"all\"),\nsimplify(expression(\"(\"+ndnd[1]+\")*(\"+ndnd[2]+\")\"),\"all\"),\nsimplify(expression(\"(\"+ndnd[3]+\")*(\"+ndnd[0]+\")\"),[\"expandBrackets\",\"all\"]),\nsimplify(expression(\"(\"+ndnd[1]+\")*(\"+ndnd[2]+\")\"),[\"expandBrackets\",\"all\"]),\nsimplify(expression(\n string(simplify(\n expression(\"(\"+ndnd[3]+\")*(\"+ndnd[0]+\")\"),\n [\"expandBrackets\",\"all\",\"!noLeadingMinus\"])\n )+\"+\"+\n string(simplify(\n expression(sgn+\"(\"+ndnd[1]+\")*(\"+ndnd[2]+\")\"),\n [\"expandBrackets\",\"all\",\"!noLeadingMinus\"])\n )\n),[\"expandBrackets\",\"basic\"]),\n \nsimplify(expression(\n string(simplify(expression(\"(\"+ndnd[3]+\")*(\"+ndnd[0]+\")\"),\n [\"expandBrackets\",\"all\",\"!noLeadingMinus\"]))+ \"+\" +\n string(simplify(expression(sgn+\"(\"+ndnd[1]+\")*(\"+ndnd[2]+\")\"),\n [\"expandBrackets\",\"all\",\"!noLeadingMinus\"]))\n ),[\"all\",\"!noLeadingMinus\"])\n ]", "description": "

The combined numerator and denominator terms:

\n

0) numerator term 1, 1) numerator term 2,

\n

2) brackets expanded num t1, 3) brackets expanded num t2

\n

4) numerator, no brackets

\n

5) numerator simplified

\n

", "templateType": "anything", "can_override": false}, "ansnum": {"name": "ansnum", "group": "Ungrouped variables", "definition": "simplify(expression(\n string(simplify(expression(\"(\"+ndnd[3]+\")*(\"+ndnd[0]+\")\"),\n [\"expandBrackets\",\"all\",\"!noLeadingMinus\"]))+ \"+\" +\n string(simplify(expression(sgn+\"(\"+ndnd[1]+\")*(\"+ndnd[2]+\")\"),\n [\"expandBrackets\",\"all\",\"!noLeadingMinus\"]))\n ),[\"all\",\"!noLeadingMinus\"])", "description": "", "templateType": "anything", "can_override": false}, "ansden": {"name": "ansden", "group": "Ungrouped variables", "definition": "simplify(expression(\"(\"+ndnd[1]+\")*(\"+ndnd[3]+\")\"),\"all\")", "description": "", "templateType": "anything", "can_override": false}, "ans": {"name": "ans", "group": "Ungrouped variables", "definition": "expression(\"(\"+string(ansnum)+\")/(\"+string(ansden)+\")\")", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "(xc[0]<>xc[1] or c[0]<>c[1]) and (xc[2]<>xc[3] or c[2]<>c[3])", "maxRuns": "76"}, "ungrouped_variables": ["v", "xc", "c", "ndnd", "te", "sgn", "sgnl", "ndnde", "cnd", "ansnum", "ansden", "ans"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "answer": "{ans}", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "mustmatchpattern": {"pattern": "?`+/?`+", "partialCredit": 0, "message": "You need to give your answer as just one fraction", "nameToCompare": ""}, "valuegenerators": []}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AE4 - Multiplication of algebraic fractions 1", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Lauren Richards", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1589/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}, {"name": "Oliver Spenceley", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23557/"}], "tags": ["adding and subtracting fractions", "adding fractions", "converting between decimals and fractions", "converting integers to fractions", "Fractions", "fractions", "integers", "manipulation of fractions", "subtracting fractions", "taxonomy"], "metadata": {"description": "

Manipulate fractions in order to add and subtract them. The difficulty escalates through the inclusion of a whole integer and a decimal, which both need to be converted into a fraction before the addition/subtraction can take place. 

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

Evaluate the following addition, giving the fraction in its simplest form.

\n

\\[\\frac{\\var{a}}{y^\\var{n2}}\\times\\frac{y^\\var{n1}}{\\var{b}}\\]

", "advice": "

To multiply two fractions you just mulitply the numerators and multiply the denominators. This means we have,

\n

\\[\\frac{\\var{a}}{y^\\var{n2}}\\times\\frac{y^\\var{n1}}{\\var{b}}=\\frac{\\var{a}\\times{y^\\var{n1}}}{y^\\var{n2}\\times\\var{b}}=\\frac{\\var{a/gcd_ab}\\times{y^\\var{n1-n2}}}{\\var{b/gcd_ab}}\\]

\n

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"a": {"name": "a", "group": "Ungrouped variables", "definition": "random(1..30)", "description": "", "templateType": "anything", "can_override": false}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "random(1..30)", "description": "", "templateType": "anything", "can_override": false}, "n1": {"name": "n1", "group": "Ungrouped variables", "definition": "random(2..4 except n2)", "description": "", "templateType": "anything", "can_override": false}, "n2": {"name": "n2", "group": "Ungrouped variables", "definition": "random(1..2)", "description": "", "templateType": "anything", "can_override": false}, "gcd_ab": {"name": "gcd_ab", "group": "Ungrouped variables", "definition": "gcd(a,b)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["a", "b", "n1", "n2", "gcd_ab"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": "fraction {\n display: inline-block;\n vertical-align: middle;\n}\nfraction > numerator, fraction > denominator {\n float: left;\n width: 100%;\n text-align: center;\n line-height: 2.5em;\n}\nfraction > numerator {\n border-bottom: 1px solid;\n padding-bottom: 5px;\n}\nfraction > denominator {\n padding-top: 5px;\n}\nfraction input {\n line-height: 1em;\n}\n\nfraction .part {\n margin: 0;\n}\n\n.table-responsive, .fractiontable {\n display:inline-block;\n}\n.fractiontable {\n padding: 0; \n border: 0;\n}\n\n.fractiontable .tddenom \n{\n text-align: center;\n}\n\n.fractiontable .tdnum \n{\n border-bottom: 1px solid black; \n text-align: center;\n}\n\n\n.fractiontable tr {\n height: 3em;\n}\n"}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

[[0]] [[1]]

", "gaps": [{"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "answer": "{a/gcd_ab}y^{n1-n2}", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "mustmatchpattern": {"pattern": "{a/gcd_ab}*?", "partialCredit": 0, "message": "", "nameToCompare": ""}, "valuegenerators": [{"name": "y", "value": ""}]}, {"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "answer": "{b/gcd_ab}", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "mustmatchpattern": {"pattern": "{b/gcd_ab}", "partialCredit": 0, "message": "", "nameToCompare": ""}, "valuegenerators": []}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "GA5 Volume of cylinder", "extensions": [], "custom_part_types": [], "resources": [["question-resources/sqbasedpyramid_sEpkGzO.svg", "/srv/numbas/media/question-resources/sqbasedpyramid_sEpkGzO.svg"], ["question-resources/triangularprism.svg", "/srv/numbas/media/question-resources/triangularprism.svg"], ["question-resources/cylinder.svg", "/srv/numbas/media/question-resources/cylinder.svg"], ["question-resources/cuboid.svg", "/srv/numbas/media/question-resources/cuboid.svg"]], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Aiden McCall", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1592/"}, {"name": "Megan Oliver", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23526/"}], "tags": ["3D shapes", "cuboid", "Cylinder", "cylinder", "pyramid", "taxonomy", "triangular prism", "volume", "Volume", "volume of a cuboid", "volume of a cylinder", "volume of a pyramid", "volume of a triangular prism"], "metadata": {"description": "

Calculate the volume of different 3D shapes, given the units and measurements required. The formulae for the volume of each shape are available as steps if required.

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "", "advice": "

For a cylinder, we first need to find the area of the circular face then multiply this area by the depth of the cylinder.
In this example the radius of the circular face is $\\mathrm{radius} = \\var{r7}m$ which can be used to calculate the area of the circular face.

\n

\\begin{align}
\\mathrm{Area\\thinspace_\\bigcirc} &= \\pi \\times \\mathrm{radius}^2 \\\\
&= \\pi \\times \\var{r7}^2 \\\\
&= \\var{pi * (r7)^2}\\, \\mathrm{m}^2 \\,.
\\end{align}

\n

Now that we have the area of the circular face ($\\mathrm{Area\\thinspace_\\bigcirc}$) we can multiply this by the $\\mathrm{depth} =\\var{w7}m\\thinspace$.

\n

\\begin{align}
\\mathrm{Volume} &= \\mathrm{Area\\thinspace_\\bigcirc} \\times \\mathrm{depth} \\\\
&= \\var{pi*(r7)^2} \\times \\var{w7} \\\\
&= \\var{dpformat(pi*w7*(r7)^2, 5)} \\\\
&= \\var{dpformat(pi*w7*(r7)^2, 1)}\\, \\mathrm{m}^2\\,. \\quad \\text{1 d.p.} 
\\end{align}

\n

Use this link to find resources to help you revise how to calculate the volume of a cylinder.

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"d4": {"name": "d4", "group": "Cuboid ", "definition": "random(2..5#1)", "description": "

Side of square in cuboid.

", "templateType": "anything", "can_override": false}, "w6": {"name": "w6", "group": "Triangular prism", "definition": "random(5..9#1)", "description": "

Creates base of triangle.

", "templateType": "anything", "can_override": false}, "d8": {"name": "d8", "group": "Square based pyramid", "definition": "random(3..6#0.1)", "description": "

One side of square base.

", "templateType": "anything", "can_override": false}, "h8": {"name": "h8", "group": "Square based pyramid", "definition": "random(3..7#1)", "description": "

Height of pyramid.

", "templateType": "anything", "can_override": false}, "w7": {"name": "w7", "group": "Cylinder", "definition": "random(7..15#0.1)", "description": "

Depth of cylinder.

", "templateType": "anything", "can_override": false}, "d6": {"name": "d6", "group": "Triangular prism", "definition": "random(9..15#0.1)", "description": "

Depth of triangular prism.

", "templateType": "anything", "can_override": false}, "r7": {"name": "r7", "group": "Cylinder", "definition": "random(2..6#1)", "description": "

Radius of the cylinder.

", "templateType": "anything", "can_override": false}, "h4": {"name": "h4", "group": "Cuboid ", "definition": "random(2..5#1 except d4)", "description": "

Side of square in cuboid.

", "templateType": "anything", "can_override": false}, "w4": {"name": "w4", "group": "Cuboid ", "definition": "random(5.5..8#0.1)", "description": "

Width of cuboid.

", "templateType": "anything", "can_override": false}, "w8": {"name": "w8", "group": "Square based pyramid", "definition": "random(3..7#1)", "description": "

One side of square base.

", "templateType": "anything", "can_override": false}, "h6": {"name": "h6", "group": "Triangular prism", "definition": "random(2..5#1)", "description": "

Height of traingle.

", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": [], "variable_groups": [{"name": "Cuboid ", "variables": ["w4", "d4", "h4"]}, {"name": "Triangular prism", "variables": ["w6", "h6", "d6"]}, {"name": "Cylinder", "variables": ["r7", "w7"]}, {"name": "Square based pyramid", "variables": ["h8", "w8", "d8"]}], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Calculate the $\\mathrm{Volume}$ of the following cylinder.

\n

\n

$\\mathrm{Volume} =$[[0]] $\\mathrm{m}^3$.  Round your answer to 1 decimal place.

", "stepsPenalty": "1", "steps": [{"type": "information", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Volume of a cylinder:

\n

\\begin{align}
\\mathrm{Volume} &= \\mathrm{Area\\thinspace_\\bigcirc} \\times \\mathrm{depth} \\\\
&= \\pi \\times \\mathrm{r}^2 \\times \\mathrm{depth}
\\end{align}

"}], "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": "2", "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "pi*{r7}^2{w7}", "maxValue": "pi*{r7}^2{w7}", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "1", "precisionPartialCredit": 0, "precisionMessage": "You have not given your answer to the correct precision.", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "GA8 Pythagoras - rectangle", "extensions": ["geogebra"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}, {"name": "Megan Oliver", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23526/"}], "tags": [], "metadata": {"description": "

Find the diagonal or one side of a rectangle using Pythagoras' theorem.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

What is the height of the rectangle below (all measurements given in $cm$)? Please give your answer to one decimal place.

\n

{geogebra_applet('https://www.geogebra.org/m/jk3n6sxh',[base: base, hyp: hyp])}

", "advice": "

You can see that the rectangle contains a right-angled triangle. We also have the lengths of the base and the hypoteneuse of the triangle. This means we can use Pythagoras' theorem to calculate the last remaining side of the triangle which is also the height of the rectangle. 

\n

\\[ \\begin{split} Height &\\, = \\sqrt{hypoteneuse^2 - base^2} \\\\ &\\, = \\sqrt{\\var{hyp}^2-\\var{base}^2} \\\\ &\\, = \\sqrt{\\var{{hyp}^2}-\\var{{base}^2}} \\\\ &\\, = \\sqrt{\\var{{{hyp}^2}-{{base}^2}}}\\\\ &\\, = \\var{ans}\\\\ &\\, = \\var{ansr} \\text{ to 1 d.p.} \\end{split} \\]

\n

Use this link to find resources to help you revise Pythagoras' theorem.

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"hyp": {"name": "hyp", "group": "Ungrouped variables", "definition": "random(10 .. 15#1)", "description": "", "templateType": "randrange", "can_override": false}, "base": {"name": "base", "group": "Ungrouped variables", "definition": "random(3 .. 8#1)", "description": "", "templateType": "randrange", "can_override": false}, "ans": {"name": "ans", "group": "Ungrouped variables", "definition": "sqrt(hyp^2-base^2)", "description": "", "templateType": "anything", "can_override": false}, "ansr": {"name": "ansr", "group": "Ungrouped variables", "definition": "precround(ans,1)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["hyp", "base", "ans", "ansr"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": true, "customName": "Answer", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

[[0]]$cm$ (give your answer to 1 d.p.)

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "ans", "maxValue": "ans", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "1", "precisionPartialCredit": 0, "precisionMessage": "You have not given your answer to the correct precision.", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "GB1 Trigonometry - missing side", "extensions": ["eukleides"], "custom_part_types": [], "resources": [["question-resources/Picture1_caMIdF1.png", "/srv/numbas/media/question-resources/Picture1_caMIdF1.png"], ["question-resources/Picture2_6KE4ZpW.png", "/srv/numbas/media/question-resources/Picture2_6KE4ZpW.png"]], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "David Wishart", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1461/"}, {"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Andrew Neate", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21832/"}, {"name": "Megan Oliver", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23526/"}], "tags": [], "metadata": {"description": "

Draws a triangle based on 3 side lengths.  Randomises asking angle or side.

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

{max_height(25,diagram)}

", "advice": "

Avoid using rounded values in calculations and just round for the final answer.

{advice}

\n

Use this link to find some resources to help you revise how to answer trigonometry questions that ask you to find a missing side.

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"ab": {"name": "ab", "group": "Unnamed group", "definition": "random(7..12)", "description": "", "templateType": "anything", "can_override": false}, "ac": {"name": "ac", "group": "Unnamed group", "definition": "precround(ab*cos(pi*angle/180),2)", "description": "", "templateType": "anything", "can_override": false}, "bc": {"name": "bc", "group": "Unnamed group", "definition": "precround(ab*sin(pi*angle/180),2)", "description": "", "templateType": "anything", "can_override": false}, "d_t_s_1": {"name": "d_t_s_1", "group": "triangle types", "definition": "eukleides(\"A right-angled triangle\",\n let(\n a, point(0,ac),\n b, point(bc,0),\n c, point(0,0),\n\n [\n \n a..b..c\n , angle(a,c,b) right\n , angle(c,a,b) label(angle+'\u00b0')\n , b..c label(bc + 'cm')\n , a..c label('x cm')\n \n ]\n ),\n[\"angle\":{angle}]\n)", "description": "", "templateType": "anything", "can_override": false}, "d_c_s_1": {"name": "d_c_s_1", "group": "triangle types", "definition": "eukleides(\"A right-angled triangle\",\n let(\n a, point(0,ac),\n b, point(bc,0),\n c, point(0,0),\n\n [\n \n a..b..c\n , angle(a,c,b) right\n , angle(c,a,b) label(angle+'\u00b0')\n , a..c label('x cm')\n , a..b label(ab + 'cm')\n \n ]\n ),\n[\"angle\":{angle}]\n)", "description": "", "templateType": "anything", "can_override": false}, "diagram": {"name": "diagram", "group": "Unnamed group", "definition": "if(SCT='s',\n if(AngORside='ang',\n random(d_s_a_1,d_s_a_2),\n random(d_s_s_1,d_s_s_2)),\n if(SCT='t',\n if(AngORside='ang',\n random(d_t_a_1,d_t_a_2),\n random(d_t_s_1,d_t_s_2)),\n if(SCT='c',\n if(AngORside='ang',\n random(d_c_a_1,d_c_a_2),\n random(d_c_s_1,d_c_s_2)),'X')))\n ", "description": "", "templateType": "anything", "can_override": false}, "angle": {"name": "angle", "group": "Unnamed group", "definition": "random(32..72)", "description": "", "templateType": "anything", "can_override": false}, "d_s_s_1": {"name": "d_s_s_1", "group": "triangle types", "definition": "eukleides(\"A right-angled triangle\",\n let(\n a, point(0,ac),\n b, point(bc,0),\n c, point(0,0),\n\n [\n \n a..b..c\n , angle(a,c,b) right\n , angle(c,a,b) label(angle+'\u00b0')\n , b..c label('x cm')\n , a..b label(ab + 'cm')\n \n ]\n ),\n[\"angle\":{angle}]\n)", "description": "", "templateType": "anything", "can_override": false}, "d_c_a_1": {"name": "d_c_a_1", "group": "triangle types", "definition": "eukleides(\"A right-angled triangle\",\n let(\n a, point(0,ac),\n b, point(bc,0),\n c, point(0,0),\n\n [\n \n a..b..c\n , angle(a,c,b) right\n , angle(c,a,b) label('x\u00b0')\n , a..c label(ac + 'cm')\n , a..b label(ab + 'cm')\n \n ]\n ),\n[\"angle\":{angle}]\n)", "description": "", "templateType": "anything", "can_override": false}, "d_s_a_1": {"name": "d_s_a_1", "group": "triangle types", "definition": "eukleides(\"A right-angled triangle\",\n let(\n a, point(0,ac),\n b, point(bc,0),\n c, point(0,0),\n\n [\n \n a..b..c\n , angle(a,c,b) right\n , angle(c,a,b) label('x\u00b0')\n , b..c label(bc + 'cm')\n , a..b label(ab + 'cm')\n \n ]\n ),\n[\"angle\":{angle}]\n)", "description": "", "templateType": "anything", "can_override": false}, "d_t_a_1": {"name": "d_t_a_1", "group": "triangle types", "definition": "eukleides(\"A right-angled triangle\",\n let(\n a, point(0,ac),\n b, point(bc,0),\n c, point(0,0),\n\n [\n \n a..b..c\n , angle(a,c,b) right\n , angle(c,a,b) label('x\u00b0')\n , b..c label(bc + 'cm')\n , a..c label(ac + 'cm')\n \n ]\n ),\n[\"angle\":{angle}]\n)", "description": "", "templateType": "anything", "can_override": false}, "d_t_s_2": {"name": "d_t_s_2", "group": "triangle types", "definition": "eukleides(\"A right-angled triangle\",\n let(\n a, point(0,-ac),\n b, point(bc,0),\n c, point(0,0),\n\n [\n \n a..b..c\n , angle(a,c,b) right\n , angle(b,a,c) label(angle+'\u00b0')\n , b..c label(bc + 'cm')\n , a..c label('x cm')\n \n ]\n ),\n[\"angle\":{angle}]\n)", "description": "", "templateType": "anything", "can_override": false}, "d_c_a_2": {"name": "d_c_a_2", "group": "triangle types", "definition": "eukleides(\"A right-angled triangle\",\n let(\n a, point(0,-ac),\n b, point(bc,0),\n c, point(0,0),\n\n [\n \n a..b..c\n , angle(a,c,b) right\n , angle(b,a,c) label('x\u00b0')\n , a..c label(ac + 'cm')\n , a..b label(ab + 'cm')\n \n ]\n ),\n[\"angle\":{angle}]\n)", "description": "", "templateType": "anything", "can_override": false}, "SCT": {"name": "SCT", "group": "Unnamed group", "definition": "random('s','c','t')", "description": "", "templateType": "anything", "can_override": false}, "AngORside": {"name": "AngORside", "group": "Unnamed group", "definition": "'side'", "description": "", "templateType": "anything", "can_override": false}, "d_c_s_2": {"name": "d_c_s_2", "group": "triangle types", "definition": "eukleides(\"A right-angled triangle\",\n let(\n a, point(0,ac),\n b, point(-bc,0),\n c, point(0,0),\n\n [\n \n a..b..c\n , angle(a,c,b) right\n , angle(b,a,c) label(angle+'\u00b0')\n , a..c label('x cm')\n , a..b label(ab + 'cm')\n \n ]\n ),\n[\"angle\":{angle}]\n)", "description": "", "templateType": "anything", "can_override": false}, "d_s_a_2": {"name": "d_s_a_2", "group": "triangle types", "definition": "eukleides(\"A right-angled triangle\",\n let(\n a, point(0,-ac),\n b, point(-bc,0),\n c, point(0,0),\n\n [\n \n a..b..c\n , angle(a,c,b) right\n , angle(c,a,b) label('x\u00b0')\n , b..c label(bc + 'cm')\n , a..b label(ab + 'cm')\n \n ]\n ),\n[\"angle\":{angle}]\n)", "description": "", "templateType": "anything", "can_override": false}, "d_s_s_2": {"name": "d_s_s_2", "group": "triangle types", "definition": "eukleides(\"A right-angled triangle\",\n let(\n a, point(0,-ac),\n b, point(-bc,0),\n c, point(0,0),\n\n [\n \n a..b..c\n , angle(a,c,b) right\n , angle(c,a,b) label(angle+'\u00b0')\n , b..c label('x cm')\n , a..b label(ab + 'cm')\n \n ]\n ),\n[\"angle\":{angle}]\n)", "description": "", "templateType": "anything", "can_override": false}, "d_t_a_2": {"name": "d_t_a_2", "group": "triangle types", "definition": "eukleides(\"A right-angled triangle\",\n let(\n a, point(0,ac),\n b, point(-bc,0),\n c, point(0,0), \n\n [\n \n a..b..c\n , angle(a,c,b) right\n , angle(b,a,c) label('x\u00b0')\n , b..c label(bc + 'cm')\n , a..c label(ac + 'cm')\n \n ]\n ),\n[\"angle\":{angle}]\n)", "description": "", "templateType": "anything", "can_override": false}, "answer": {"name": "answer", "group": "Unnamed group", "definition": "if(SCT='s',\n if(AngORside='ang',\n angle,\n bc),\n if(SCT='t',\n if(AngORside='ang',\n angle,\n ac),\n if(AngORside='ang',\n angle,ac)))", "description": "", "templateType": "anything", "can_override": false}, "advice": {"name": "advice", "group": "advice", "definition": "if(SCT='s',\n if(AngORside='ang',\n {sin_a},\n {sin_bc}),\n if(SCT='c',\n if(AngORside='ang',\n {cos_a},\n {cos_ac}),\n if(AngORside='ang',\n {tan_a},{tan_ac})))", "description": "", "templateType": "anything", "can_override": false}, "sin_a": {"name": "sin_a", "group": "advice", "definition": "\"

In this situation $x$ is an angle.  We label the known sides of the triangle \\'opposite\\', \\'adjacent\\' and \\'hypothenuse\\' in relation to the angle we are interested in:

\\n

$\\\\text{Opposite} = \\\\var{bc}$
$\\\\text{Hyptonuse} = \\\\var{ab}$

We have \\'O\\' and \\'H\\' in SOHCAHTOA, so we know we need to use the $\\\\sin$ formula:

\\n

\\\\[ \\\\sin(\\\\text{Angle}) = \\\\frac{\\\\text{Opposite}}{\\\\text{Hypotenuse}}\\\\]

\\n

Now we subsitute the values we have in this particular question

\\n

\\\\[ \\\\sin(x) = \\\\frac{\\\\var{bc}}{\\\\var{ab}}\\\\]

We need to use the \\'inverse $\\\\sin$\\' button on the calculator (also called $\\\\arcsin$ or notated $\\\\sin^{-1}$) in order to isolate $x$:

Make sure your calculator is set to \\'degree\\' mode, if you get an odd answer you are likely in the wrong mode!

\\n

\\\\[ x = \\\\sin^{-1}(\\\\var{bc}/\\\\var{ab})\\\\]

\\n

\\\\[ x = \\\\var{precround(180*(arcsin(bc/(ab)))/pi,4)}\\\\]

\\n

Round as required:

\\n

\\\\[x = \\\\var{precround(180*(arcsin(bc/(ab)))/pi,2)}\\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "cos_a": {"name": "cos_a", "group": "advice", "definition": "\"

In this situation $x$ is an angle.  We label the known sides of the triangle \\'opposite\\', \\'adjacent\\' and \\'hypothenuse\\' in relation to the angle we are interested in:

\\n

$\\\\text{Adjacent} = \\\\var{ac}$
$\\\\text{Hyptonuse} = \\\\var{ab}$

We have \\'A\\' and \\'H\\' in SOHCAHTOA, so we know we need to use the $\\\\cos$ formula:

\\n

\\\\[ \\\\cos(\\\\text{Angle}) = \\\\frac{\\\\text{Adjacent}}{\\\\text{Hypotenuse}}\\\\]

\\n

Now we subsitute the values we have in this particular question

\\n

\\\\[ \\\\cos(x) = \\\\frac{\\\\var{ac}}{\\\\var{ab}}\\\\]

We need to use the \\'inverse $\\\\cos$\\' button on the calculator (also called $\\\\arccos$ or notated $\\\\cos^{-1}$) in order to isolate $x$:

Make sure your calculator is set to \\'degree\\' mode, if you get an odd answer you are likely in the wrong mode!

\\n

\\\\[ x = \\\\cos^{-1}(\\\\var{ac}/\\\\var{ab})\\\\]

\\n

\\\\[ x = \\\\var{precround(180*(arccos(ac/(ab)))/pi,4)}\\\\]

\\n

Round as required:

\\n

\\\\[x = \\\\var{precround(180*(arccos(ac/(ab)))/pi,2)}\\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "tan_a": {"name": "tan_a", "group": "advice", "definition": "\"

In this situation $x$ is an angle.  We label the known sides of the triangle \\'opposite\\', \\'adjacent\\' and \\'hypothenuse\\' in relation to the angle we are interested in:

\\n

$\\\\text{Opposite} = \\\\var{bc}$
$\\\\text{Adjacent} = \\\\var{ac}$

We have \\'O\\' and \\'A\\' in SOHCAHTOA, so we know we need to use the $\\\\tan$ formula:

\\n

\\\\[ \\\\tan(\\\\text{Angle}) = \\\\frac{\\\\text{Opposite}}{\\\\text{Adjacent}}\\\\]

\\n

Now we subsitute the values we have in this particular question

\\n

\\\\[ \\\\tan(x) = \\\\frac{\\\\var{bc}}{\\\\var{ac}}\\\\]

We need to use the \\'inverse $\\\\tan$\\' button on the calculator (also called $\\\\arctan$ or notated $\\\\tan^{-1}$) in order to isolate $x$:

Make sure your calculator is set to \\'degree\\' mode, if you get an odd answer you are likely in the wrong mode!

\\n

\\\\[ x = \\\\tan^{-1}(\\\\var{bc}/\\\\var{ac})\\\\]

\\n

\\\\[ x = \\\\var{precround(180*(arctan(bc/(ac)))/pi,4)}\\\\]

\\n

Round as required:

\\n

\\\\[x = \\\\var{precround(180*(arctan(bc/(ac)))/pi,2)}\\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "sin_bc": {"name": "sin_bc", "group": "advice", "definition": "\"

In this situation $x$ is a side.  We label the relevant sides of the triangle \\'opposite\\', \\'adjacent\\' and \\'hypothenuse\\' in relation to the angle we know:

\\n

$\\\\text{Opposite} = x$
$\\\\text{Hypotenuse} = \\\\var{ab}$

We have \\'O\\' and \\'H\\' in SOHCAHTOA, so we know we need to use the $\\\\sin$ formula:

\\n

\\\\[ \\\\sin(\\\\text{Angle}) = \\\\frac{\\\\text{Opposite}}{\\\\text{Hypotenuse}}\\\\]

\\n

Now we subsitute the values we have in this particular question

\\n

\\\\[ \\\\sin(\\\\var{angle}) = \\\\frac{x}{\\\\var{ab}}\\\\]

and rearrange to give:

\\n

\\\\[ x = \\\\var{ab} \\\\times \\\\sin(\\\\var{angle}) \\\\]

Make sure your calculator is set to \\'degree\\' mode, if you get an odd answer you are likely in the wrong mode!

\\n

\\\\[ x = \\\\var{precround(ab*sin(pi*angle/180),4)}\\\\]

\\n

Round as required:

\\n

\\\\[ x = \\\\var{precround(ab*sin(pi*angle/180),2)}\\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "cos_ac": {"name": "cos_ac", "group": "advice", "definition": "\"

In this situation $x$ is a side.  We label the relevant sides of the triangle \\'opposite\\', \\'adjacent\\' and \\'hypothenuse\\' in relation to the angle we know:

\\n

$\\\\text{Hypotenuse} = \\\\var{ab}$
$\\\\text{Adjacent} = x$

We have \\'A\\' and \\'H\\' in SOHCAHTOA, so we know we need to use the $\\\\cos$ formula:

\\n

\\n

\\\\[ \\\\cos(\\\\text{Angle}) = \\\\frac{\\\\text{Adjacent}}{\\\\text{Hypotenuse}}\\\\]

\\n

Now we subsitute the values we have in this particular question

\\n

\\\\[ \\\\cos(\\\\var{angle}) = \\\\frac{x}{\\\\var{ab}}\\\\]

and rearrange to give:

\\n

\\\\[ x = \\\\var{ab} \\\\times \\\\cos(\\\\var{angle}) \\\\]

Make sure your calculator is set to \\'degree\\' mode, if you get an odd answer you are likely in the wrong mode!

\\n

\\\\[ x = \\\\var{precround(ab*cos(pi*angle/180),4)}\\\\]

\\n

Round as required:

\\n

\\\\[ x = \\\\var{precround(ab*cos(pi*angle/180),2)}\\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "tan_ac": {"name": "tan_ac", "group": "advice", "definition": "\"

In this situation $x$ is a side.  We label the relevant sides of the triangle \\'opposite\\', \\'adjacent\\' and \\'hypothenuse\\' in relation to the angle we know:

\\n

$\\\\text{Opposite} = \\\\var{bc}$
$\\\\text{Adjacent} = x$

We have \\'O\\' and \\'A\\' in SOHCAHTOA, so we know we need to use the $\\\\tan$ formula:

\\n

\\\\[ \\\\tan(\\\\text{Angle}) = \\\\frac{\\\\text{Opposite}}{\\\\text{Adjacent}}\\\\]

\\n

Now we subsitute the values we have in this particular question

\\n

\\\\[ \\\\tan(\\\\var{angle}) = \\\\frac{\\\\var{bc}}{x}\\\\]

and rearrange to give:

\\n

\\\\[ x = \\\\frac{\\\\var{bc}}{\\\\tan(\\\\var{angle})} \\\\]

Make sure your calculator is set to \\'degree\\' mode, if you get an odd answer you are likely in the wrong mode!

\\n

\\\\[ x = \\\\var{precround(bc/tan(pi*angle/180),4)}\\\\]

\\n

Round as required:

\\n

\\\\[ x = \\\\var{precround(bc/tan(pi*angle/180),2)}\\\\]

\"", "description": "", "templateType": "long string", "can_override": false}}, "variablesTest": {"condition": "precround(180*(arcsin(bc/(ab)))/pi,1) = precround(angle,1)", "maxRuns": "6"}, "ungrouped_variables": [], "variable_groups": [{"name": "Unnamed group", "variables": ["ab", "ac", "bc", "diagram", "angle", "SCT", "AngORside", "answer"]}, {"name": "triangle types", "variables": ["d_t_a_2", "d_t_s_1", "d_s_a_1", "d_c_a_1", "d_c_s_1", "d_s_s_1", "d_c_s_2", "d_t_a_1", "d_t_s_2", "d_s_a_2", "d_s_s_2", "d_c_a_2"]}, {"name": "advice", "variables": ["advice", "tan_a", "sin_a", "cos_a", "sin_bc", "cos_ac", "tan_ac"]}], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Given a right angled triangle as shown calculate the value of x.

\n

Angles are given in degrees (make sure you calculator is in the right mode)

Give your answer correct to 2 decimal place.

", "minValue": "answer", "maxValue": "answer", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "2", "precisionPartialCredit": "100", "precisionMessage": "", "strictPrecision": true, "showPrecisionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "CA1 Straight Line Graphs", "extensions": ["geogebra"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}, {"name": "Megan Oliver", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23526/"}], "tags": [], "metadata": {"description": "

Calculating gradient and finding intercept from a geogebra graph.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

{app}
Find the gradient of the line.


", "advice": "

Firstly draw a right angled 'step' from left to right. This triangle can be anywhere, but it is more helpful for it to have corners on the vertices (whole number points) of the graph and it is easier to calculate with postive numbers.

\n

{app_advice}

\n

Before we start to calculate, notice that the line is {uod}, so the gradient will be {pon} and the line is {sos}, so the absolute value of the number will be {mol}.

Now find the coordinates of the places your triangle meets the line

\n

$(x_1,y_1)=(\\var{ax},\\var{ay})$ and $(x_2,y_2)=(\\var{bx},\\var{by})$

\n

We need to compare the 'rise on the y-axis' to the 'run across the x-axis', we can say that:

\n

$\\text{gradient} = \\frac{\\text{rise}}{\\text{run}}$

\n

This is equivalent to using the formula:

$  m = \\frac{y_2 - y_1}{x_2 - x_1} $

\n

and substitute the coordinates of the vertices of the triangle:

$\\begin{split} &\\, m = \\frac{\\var{by} - \\var{ay}}{\\var{bx} - \\var{ax}} \\\\  
&\\, = \\frac{\\var{by-ay}}{\\var{bx-ax}} \\\\ 
&\\,  = \\var[fractionNumbers]{m} \\\\
\\end{split} $

\n

Use this link to find resources to help you revise straight line graphs and how to find the gradient of them.

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"app": {"name": "app", "group": "Ungrouped variables", "definition": "geogebra_applet(\n 800,500,\n [\n A: [\n definition: p1,\n label_visible: false,\n visible: false\n ],\n B: [\n definition: p2,\n label_visible: false,\n visible: false \n ],\n line: [\n definition: \"Line(A,B)\",\n label_visible: false\n ]\n ]\n)", "description": "", "templateType": "anything", "can_override": false}, "m": {"name": "m", "group": "Ungrouped variables", "definition": "(ay-by)/(ax-bx)", "description": "", "templateType": "anything", "can_override": false}, "c": {"name": "c", "group": "Ungrouped variables", "definition": "ay-m*ax", "description": "", "templateType": "anything", "can_override": false}, "P1": {"name": "P1", "group": "Ungrouped variables", "definition": "vector(ax, ay)", "description": "", "templateType": "anything", "can_override": false}, "P2": {"name": "P2", "group": "Ungrouped variables", "definition": "vector(bx,by)", "description": "", "templateType": "anything", "can_override": false}, "uod": {"name": "uod", "group": "Ungrouped variables", "definition": "if(m=0,'horizontal',if(m=abs(m),'going up','going down'))", "description": "

if(m=abs(m),'positive','negative')

", "templateType": "anything", "can_override": false}, "ax": {"name": "ax", "group": "Ungrouped variables", "definition": "random(0,1)", "description": "", "templateType": "anything", "can_override": false}, "ay": {"name": "ay", "group": "Ungrouped variables", "definition": "random(0,1,2,3)", "description": "", "templateType": "anything", "can_override": false}, "bx": {"name": "bx", "group": "Ungrouped variables", "definition": "random(ax+1..3) \n", "description": "", "templateType": "anything", "can_override": false}, "by": {"name": "by", "group": "Ungrouped variables", "definition": "random(0..4 except ay)\n", "description": "", "templateType": "anything", "can_override": false}, "app_advice": {"name": "app_advice", "group": "Ungrouped variables", "definition": "geogebra_applet(\n 800,500,\n [\n A: [\n definition: p1,\n label_visible: false,\n visible: true\n ],\n B: [\n definition: p2,\n label_visible: false,\n visible: true \n ],\n \n C: [\n definition: p3,\n label_visible: false,\n visible: false \n ],\n \n line1: [\n definition: \"Line(A,B)\",\n label_visible: false,\n visible: true\n ],\n \n line2: [\n definition: \"Segment(A,C)\",\n label_visible: false,\n visible: true\n ],\n \n \n \n line3: [\n definition: \"Segment(C,B)\",\n label_visible: false,\n visible: true\n ]\n ]\n)", "description": "", "templateType": "anything", "can_override": false}, "p3": {"name": "p3", "group": "Ungrouped variables", "definition": "vector(bx,ay)", "description": "", "templateType": "anything", "can_override": false}, "pon": {"name": "pon", "group": "Ungrouped variables", "definition": "if(m=0,'zero',if(m=abs(m),'a positive number','a negative number'))", "description": "", "templateType": "anything", "can_override": false}, "sos": {"name": "sos", "group": "Ungrouped variables", "definition": "if(m=0,'horizontal',if(abs(m)<1,'shallow','steep'))", "description": "", "templateType": "anything", "can_override": false}, "mol": {"name": "mol", "group": "Ungrouped variables", "definition": "if(m=0,'zero',if(abs(m)<1,'less than 1','greater than or equal to 1'))", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "m<>1", "maxRuns": 100}, "ungrouped_variables": ["app", "m", "c", "P1", "P2", "uod", "ax", "ay", "bx", "by", "app_advice", "p3", "pon", "sos", "mol"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "alternatives": [{"type": "jme", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "alternativeFeedbackMessage": "

It looks like you have incorrectly rounded this answer.  You might want to look at some resources on rounded decimals.  You can also leave your answer in fraction form as
$\\var[fractionNumbers]{m}$

", "useAlternativeFeedback": false, "answer": "{m}", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": "0.1", "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": []}], "answer": "{m}", "showPreview": true, "checkingType": "dp", "checkingAccuracy": "1", "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": []}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "SA1 Types of data", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Stanislav Duris", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1590/"}, {"name": "Lauren Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21504/"}, {"name": "Michael Pan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23528/"}], "tags": ["continuous data", "discrete data", "taxonomy"], "metadata": {"description": "

Decide whether each of the described sets of data is drawn from a discrete or continuous distribution.

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

Decide whether the following data sets are discrete or continuous.

", "advice": "

Data can either be discrete or continuous.

\n\n

\n

a)

\n

Height is a continuous variable. For example, 180.3cm and 180.4cm have a valid midpoint 180.35cm.Weight is a continuous variable. For example, 54.5kg and 54.6kg have a valid midpoint 54.55kg.Time is a continuous variable. For example, 54.2s and 54.3s have a valid midpoint 54.25s.Temperature is a continuous variable, it can take any value between -273.15°C (absolute zero) and positive infinity. For example, 25°C and 26°C have a valid midpoint 25.5°C. Hence, this data is continuous.

\n

b)

\n

The number of Stage 1 students will always be an integer. You cannot split one student into two, for example value 19.5 students does not make sense. Therefore, this is a discrete set of data.The result of rolling 3 dice can take values of integers from 3 up to 18. For example, values 3 and 4 do not have any valid middle measurement. Therefore, this is a discrete set of data.Shoe sizes are a discrete set of data. For example, sizes 39 and 40 mean something while the middle value 39.5 does not.The number of chocolate bars sold on Monday will always be an integer. There is no middle measurement between 1 and 2 bars sold. You cannot buy a half of a bar. Therefore, this is a discrete set of data.The number of movies downloaded will always be an integer. You can either download a movie successfully or unsuccessfuly, so this is a discrete set of data. It is impossible to split 0 and 1 movies downloaded into 0.5. The number of cinema tickets sold will always be a whole number. There is no middle measurement between 1 and 2 tickets sold. You simply cannot buy half of a ticket. Therefore, this is a discrete set of data.

\n

c)

\n

The number of Stage 1 students will always be an integer. You cannot split one student into two, for example value 19.5 students does not make sense. Therefore, this is a discrete set of data.The result of rolling 3 dice can take values of integers from 3 up to 18. For example, values 3 and 4 do not have any valid middle measurement. Therefore, this is a discrete set of data.Shoe sizes are a discrete set of data. For example, sizes 39 and 40 mean something while the middle value 39.5 does not..The number of chocolate bars sold on Monday will always be an integer. There is no middle measurement between 1 and 2 bars sold. You cannot buy a half of a bar. Therefore, this is a discrete set of data.The number of movies downloaded will always be an integer. You can either download a movie successfully or unsuccessfuly, so this is a discrete set of data. It is impossible to split 0 and 1 movies downloaded into 0.5.The number of cinema tickets sold will always be a whole number. There is no middle measurement between 1 and 2 tickets sold. You simply cannot buy half of a ticket. Therefore, this is a discrete set of data.

\n

d)

\n

Height is a continuous variable. For example, 180.3cm and 180.4cm have a valid midpoint 180.35cm.Weight is a continuous variable. For example, 54.5kg and 54.6kg have a valid midpoint 54.55kg.Time is a continuous variable. For example, 54.2s and 54.3s have a valid midpoint 54.25s.Temperature is a continuous variable, it can take any value between -273.15°C (absolute zero) and positive infinity. For example, 25°C and 26°C have a valid midpoint 25.5°C. Hence, this data is continuous.

\n

e)

\n

When we round continuous variables to the nearest integer, this data becomes discrete, as there are no valid middle measurements between the integers. Therefore, the weight of a dog to the nearest kgthe height of Olympic medalists to the nearest cmthe time taken to run 10km to the nearest min is discrete and not continuous.

\n

f)

\n

The number of Stage 1 students will always be an integer. You cannot split one student into two, for example value 19.5 students does not make sense. Therefore, this is a discrete set of data.The result of rolling 3 dice can take values of integers from 3 up to 18. For example, values 3 and 4 do not have any valid middle measurement. Therefore, this is a discrete set of data.Shoe sizes are a discrete set of data. For example, sizes 39 and 40 mean something while the middle value 39.5 does not.The number of chocolate bars sold on Monday will always be an integer. There is no middle measurement between 1 and 2 bars sold. You cannot buy half of a bar of chocolate. Therefore, this is a discrete set of data.The number of movies downloaded will always be an integer. You can either download a movie successfully or unsuccessfuly, so this is a discrete set of data. It is impossible to split 0 and 1 movies downloaded into 0.5.The number of cinema tickets sold will always be a whole number. There is no middle measurement between 1 and 2 tickets sold. You simply cannot buy half of a ticket. Therefore, this is a discrete set of data.

\n

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

\n

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"rand3": {"name": "rand3", "group": "Ungrouped variables", "definition": "random(0..5 except rand except rand2)", "description": "", "templateType": "anything", "can_override": false}, "cont": {"name": "cont", "group": "Ungrouped variables", "definition": "[\"The height of Newcastle University students.\", \"The weight of Olympic medalists.\", \"The time taken to brush teeth.\", \"The maximum daily temperature.\"]", "description": "", "templateType": "anything", "can_override": false}, "disc": {"name": "disc", "group": "Ungrouped variables", "definition": "[\"The number of Stage 1 students.\", \"The result of rolling 3 dice.\", \"Shoe sizes.\", \"The number of chocolate bars sold on Monday.\", \"The number of movies downloaded.\", \"The number of cinema tickets sold.\"]", "description": "", "templateType": "anything", "can_override": false}, "trick": {"name": "trick", "group": "Ungrouped variables", "definition": "[\"The weight of a dog to the nearest kg.\", \"The height of Olympic medalists to the nearest cm.\", \"The time taken to run 10km to the nearest min.\"]", "description": "", "templateType": "anything", "can_override": false}, "ranc2": {"name": "ranc2", "group": "Ungrouped variables", "definition": "random(0..3 except ranc)", "description": "", "templateType": "anything", "can_override": false}, "rant": {"name": "rant", "group": "Ungrouped variables", "definition": "random(0..2)", "description": "", "templateType": "anything", "can_override": false}, "rand": {"name": "rand", "group": "Ungrouped variables", "definition": "random(0..5)", "description": "", "templateType": "anything", "can_override": false}, "rand2": {"name": "rand2", "group": "Ungrouped variables", "definition": "random(0..5 except rand)", "description": "", "templateType": "anything", "can_override": false}, "ranc": {"name": "ranc", "group": "Ungrouped variables", "definition": "random(0..3)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["disc", "cont", "trick", "ranc", "rant", "ranc2", "rand2", "rand3", "rand"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "1_n_2", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

{cont[ranc]}

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": false, "displayType": "radiogroup", "displayColumns": 0, "showCellAnswerState": true, "choices": ["

Discrete

", "

Continuous

"], "matrix": [0, "1"], "distractors": ["", ""]}, {"type": "1_n_2", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

{disc[rand]}

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": false, "displayType": "radiogroup", "displayColumns": 0, "showCellAnswerState": true, "choices": ["

Discrete

", "

Continuous

"], "matrix": ["1", 0], "distractors": ["", ""]}, {"type": "1_n_2", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

{disc[rand2]}

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": false, "displayType": "radiogroup", "displayColumns": 0, "showCellAnswerState": true, "choices": ["

Discrete

", "

Continuous

"], "matrix": ["1", 0], "distractors": ["", ""]}, {"type": "1_n_2", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

{cont[ranc2]}

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": false, "displayType": "radiogroup", "displayColumns": 0, "showCellAnswerState": true, "choices": ["

Discrete

", "

Continuous

"], "matrix": [0, "1"], "distractors": ["", ""]}, {"type": "1_n_2", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

{trick[rant]}

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": false, "displayType": "radiogroup", "displayColumns": 0, "showCellAnswerState": true, "choices": ["

Discrete

", "

Continuous

"], "matrix": ["1", 0], "distractors": ["", ""]}, {"type": "1_n_2", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

{disc[rand3]}

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": false, "displayType": "radiogroup", "displayColumns": 0, "showCellAnswerState": true, "choices": ["

Discrete

", "

Continuous

"], "matrix": ["1", 0], "distractors": ["", ""]}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "SA2 Choosing a suitable chart", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Lauren Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21504/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}, {"name": "Michael Pan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23528/"}], "tags": [], "metadata": {"description": "

This question is about identifying what types of charts or visual representations of data you can use for different data sets.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

This question is about recognising what types of charts or visual representations of data you can use with what types of data sets.

", "advice": "

There are many different types of visual representations of data and sometimes there will be a choice of what you use.

\n

\n

Start by looking at these resources to build up your understanding of data display options and methods. 

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": [], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "m_n_x", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

The table shows different names of charts on the left hand side and different descriptions of data sets along the top.

\n

Pair up each description with the chart that would be most suitable.

", "minMarks": 0, "maxMarks": 0, "minAnswers": 0, "maxAnswers": 0, "shuffleChoices": false, "shuffleAnswers": true, "displayType": "radiogroup", "warningType": "none", "showCellAnswerState": true, "markingMethod": "sum ticked cells", "choices": ["Scatter plot", "Histogram", "Bar Chart"], "matrix": [["1", 0, 0], [0, "0", "1"], [0, "1", "0"]], "layout": {"type": "all", "expression": ""}, "answers": ["Two continuous variables plotted against each other to investigate their relationship.", "Non-numerical categories and the frequencies of each category.", "A continuous variable such as \"height in $cm$\" grouped into intervals showingthe frequency of the data in each interval."]}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "SA3 Interpret Pie Charts", "extensions": ["geogebra"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Lauren Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21504/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}, {"name": "Michael Pan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23528/"}], "tags": [], "metadata": {"description": "

This question is about correctly interpreting pie charts.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

{geogebra_applet{\"https://www.geogebra.org/m/ab2psjcf\",[C: C,M: M]}}

\n

The Pie Chart above shows the responses to a question asked by someone trying to plan a social event for their workplace. It shows answers given to the question \"Where would you like to go for a staff social?\" with the options \"Meal\", \"Cinema\" and \"Games Cafe\".

", "advice": "

A Pie chart of this type can only be used to make statements about the proportions of data in each category and does not provide information about the actual frequencies.

\n

For more information on Pie Charts follow this link.

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"C": {"name": "C", "group": "Ungrouped variables", "definition": "random(25 .. 50#5)", "description": "", "templateType": "randrange", "can_override": false}, "M": {"name": "M", "group": "Ungrouped variables", "definition": "random(30 .. 45#5)", "description": "", "templateType": "randrange", "can_override": false}}, "variablesTest": {"condition": "C<>M", "maxRuns": 100}, "ungrouped_variables": ["C", "M"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "m_n_x", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

From the following comments which can you say are definitely true, definitely false and which do you not have enough information to know?

", "minMarks": 0, "maxMarks": 0, "minAnswers": 0, "maxAnswers": 0, "shuffleChoices": true, "shuffleAnswers": true, "displayType": "radiogroup", "warningType": "none", "showCellAnswerState": true, "markingMethod": "sum ticked cells", "choices": ["50 people responded that they would like to go to the cinema.", "About one third of people said they wanted to go for a meal.", "Over half the people responding said they wanted to go to the Games Cafe."], "matrix": [[0, 0, "1"], [0, "1", 0], ["1", 0, 0]], "layout": {"type": "all", "expression": ""}, "answers": ["Definitely true.", "Definitely false.", "Not enough information to know."]}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "SA4 Interpret Bar Chart", "extensions": ["jsxgraph"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Gareth Woods", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/978/"}, {"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Lauren Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21504/"}], "tags": [], "metadata": {"description": "

Reading a value from a simple bar chart.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "", "advice": "

The bar heights give the values of the spend.

Each company has two bars, the left one for last year (in red) and the right one for this year (in purple).
Isolate last years spend by looking at the the bars on the right side, and choose the tallest bar, corresponding to the highest value.

\n

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

", "rulesets": {"std": ["all", "fractionNumbers"]}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"answervector": {"name": "answervector", "group": "Ungrouped variables", "definition": "vector((yo5-yo0)/yo0*100, (yo6-yo1)/yo1*100,(yo7-yo2)/yo2*100,(yo8-yo3)/yo3*100, (yo9-yo4)/yo4*100)", "description": "", "templateType": "anything", "can_override": false}, "cc": {"name": "cc", "group": "Ungrouped variables", "definition": "random(0.7..1.3#0.01 except 1 except aa except bb)", "description": "", "templateType": "anything", "can_override": false}, "aa": {"name": "aa", "group": "Ungrouped variables", "definition": "random(0.7..1.3#0.01 except 1)", "description": "", "templateType": "anything", "can_override": false}, "year": {"name": "year", "group": "Ungrouped variables", "definition": "yearvector[ii]", "description": "", "templateType": "anything", "can_override": false}, "yn": {"name": "yn", "group": "Ungrouped variables", "definition": "map(vsc*y+vsh,y,yo)", "description": "

new y values after the transformation

", "templateType": "anything", "can_override": false}, "eee": {"name": "eee", "group": "Ungrouped variables", "definition": "random(1.1..1.3#0.01 except a except b except c except d)", "description": "", "templateType": "anything", "can_override": false}, "yo": {"name": "yo", "group": "Ungrouped variables", "definition": "repeat(random(-5..5),5)", "description": "

the (random) original y values which relate to the x values

", "templateType": "anything", "can_override": false}, "d": {"name": "d", "group": "Ungrouped variables", "definition": "random(1.1..1.3#0.01 except a except b except c)", "description": "", "templateType": "anything", "can_override": false}, "yo9": {"name": "yo9", "group": "Ungrouped variables", "definition": "random(41..70#1 except yo5 except yo6 except yo7 except yo8)", "description": "", "templateType": "anything", "can_override": false}, "vsh": {"name": "vsh", "group": "Ungrouped variables", "definition": "if(selector='vsh',random(-3..3#0.5 except 0),0)\n", "description": "

vertical shift

", "templateType": "anything", "can_override": false}, "vsc": {"name": "vsc", "group": "Ungrouped variables", "definition": "if(selector='vsc',random(-2,-1,-0.5,0.5,2),1)", "description": "", "templateType": "anything", "can_override": false}, "c": {"name": "c", "group": "Ungrouped variables", "definition": "random(1.1..1.3#0.01 except a except b)", "description": "", "templateType": "anything", "can_override": false}, "bb": {"name": "bb", "group": "Ungrouped variables", "definition": "random(0.7..1.3#0.01 except 1 except aa)", "description": "", "templateType": "anything", "can_override": false}, "answer": {"name": "answer", "group": "Ungrouped variables", "definition": "max([yo1,yo0,yo2,yo3,yo4])", "description": "", "templateType": "anything", "can_override": false}, "students": {"name": "students", "group": "Ungrouped variables", "definition": "random(120..320#1)", "description": "", "templateType": "anything", "can_override": false}, "a": {"name": "a", "group": "Ungrouped variables", "definition": "random(1.1..1.3#0.01)", "description": "", "templateType": "anything", "can_override": false}, "yo2": {"name": "yo2", "group": "Ungrouped variables", "definition": "random(20..40#1 except yo1 except yo0)", "description": "", "templateType": "anything", "can_override": false}, "yo5": {"name": "yo5", "group": "Ungrouped variables", "definition": "random(41..70#1)", "description": "", "templateType": "anything", "can_override": false}, "yo8": {"name": "yo8", "group": "Ungrouped variables", "definition": "random(41..70#1 except yo5 except yo6 except yo7)", "description": "", "templateType": "anything", "can_override": false}, "yo1": {"name": "yo1", "group": "Ungrouped variables", "definition": "random(20..40#1 except yo0)", "description": "", "templateType": "anything", "can_override": false}, "yo7": {"name": "yo7", "group": "Ungrouped variables", "definition": "random(41..70#1 except yo5 except yo6)", "description": "", "templateType": "anything", "can_override": false}, "maxx": {"name": "maxx", "group": "Ungrouped variables", "definition": "max(map(abs(a),a,xn)+5)+1", "description": "", "templateType": "anything", "can_override": false}, "yearvector": {"name": "yearvector", "group": "Ungrouped variables", "definition": "vector(2007,2008,2009,2010,2011,2012,2013)", "description": "", "templateType": "anything", "can_override": false}, "ii": {"name": "ii", "group": "Ungrouped variables", "definition": "random(3..6#1)", "description": "", "templateType": "anything", "can_override": false}, "yo3": {"name": "yo3", "group": "Ungrouped variables", "definition": "random(20..40#1 except yo1 except yo0 except yo2)", "description": "", "templateType": "anything", "can_override": false}, "selector": {"name": "selector", "group": "Ungrouped variables", "definition": "'vsc'", "description": "", "templateType": "anything", "can_override": false}, "fakeanswer1": {"name": "fakeanswer1", "group": "Ungrouped variables", "definition": "random([yo1,yo0,yo2,yo3,yo4] except answer)", "description": "", "templateType": "anything", "can_override": false}, "hsh": {"name": "hsh", "group": "Ungrouped variables", "definition": "if(selector='hsh',random(-3..3 except 0),0)", "description": "

horizontal shift

", "templateType": "anything", "can_override": false}, "fakeanswer4": {"name": "fakeanswer4", "group": "Ungrouped variables", "definition": "random([yo9,yo7,yo8] except fakeanswer3)", "description": "", "templateType": "anything", "can_override": false}, "dd": {"name": "dd", "group": "Ungrouped variables", "definition": "random(0.7..1.3#0.01 except 1 except aa except bb except cc)", "description": "", "templateType": "anything", "can_override": false}, "percent": {"name": "percent", "group": "Ungrouped variables", "definition": "random(5..15#0.1 except 5 except 6 except 7 except 8 except 9 except 10 except 11 except 12 except 13 except 14 except 15)", "description": "", "templateType": "anything", "can_override": false}, "yo0": {"name": "yo0", "group": "Ungrouped variables", "definition": "random(20..40#1)", "description": "", "templateType": "anything", "can_override": false}, "xn": {"name": "xn", "group": "Ungrouped variables", "definition": "map((x-hsh)/hsc,x,xo)", "description": "

new transformed x values

", "templateType": "anything", "can_override": false}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "random(1.1..1.3#0.01 except a)", "description": "", "templateType": "anything", "can_override": false}, "xo": {"name": "xo", "group": "Ungrouped variables", "definition": "list(-2..2)", "description": "

original x values

", "templateType": "anything", "can_override": false}, "yo4": {"name": "yo4", "group": "Ungrouped variables", "definition": "random(20..40#1 except yo1 except yo0 except yo2 except yo3)", "description": "", "templateType": "anything", "can_override": false}, "fakeanswer2": {"name": "fakeanswer2", "group": "Ungrouped variables", "definition": "random([yo1,yo0,yo2,yo3,yo4] except answer except fakeanswer1)", "description": "", "templateType": "anything", "can_override": false}, "f": {"name": "f", "group": "Ungrouped variables", "definition": "random(1.1..1.3#0.01 except a except b except c except d except e)", "description": "", "templateType": "anything", "can_override": false}, "yo51": {"name": "yo51", "group": "Ungrouped variables", "definition": "eee*yo5", "description": "", "templateType": "anything", "can_override": false}, "fakeanswer3": {"name": "fakeanswer3", "group": "Ungrouped variables", "definition": "random([yo6,yo7,yo8])", "description": "", "templateType": "anything", "can_override": false}, "increase": {"name": "increase", "group": "Ungrouped variables", "definition": "random(10..40#5)", "description": "", "templateType": "anything", "can_override": false}, "yo6": {"name": "yo6", "group": "Ungrouped variables", "definition": "random(41..70#1 except yo5)", "description": "", "templateType": "anything", "can_override": false}, "hsc": {"name": "hsc", "group": "Ungrouped variables", "definition": "if(selector='hsc',random(-2,-1,-0.5,0.5,2),1)", "description": "", "templateType": "anything", "can_override": false}, "yo41": {"name": "yo41", "group": "Ungrouped variables", "definition": "d*yo4", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["selector", "vsh", "hsh", "vsc", "hsc", "yo", "yn", "xo", "xn", "yo0", "yo1", "yo2", "yo3", "yo4", "maxx", "yo6", "yo7", "yo8", "yo9", "yo41", "yo5", "yo51", "a", "b", "c", "d", "eee", "f", "answer", "fakeanswer1", "fakeanswer2", "fakeanswer3", "fakeanswer4", "aa", "bb", "cc", "dd", "percent", "students", "yearvector", "ii", "year", "answervector", "increase"], "variable_groups": [], "functions": {}, "preamble": {"js": "function dragpoint_board() {\n var scope = question.scope;\n\n JXG.Options.text.display = 'internal';\n \n var yo0 = scope.variables.yo0.value;\n var yo1 = scope.variables.yo1.value;\n var yo2 = scope.variables.yo2.value;\n var yo3 = scope.variables.yo3.value;\n var yo4 = scope.variables.yo4.value;\n var yo5 = scope.variables.yo5.value;\n var yo6 = scope.variables.yo6.value;\n var yo7 = scope.variables.yo7.value; \n var yo8 = scope.variables.yo8.value;\n var yo9 = scope.variables.yo9.value; \n \n var div = Numbas.extensions.jsxgraph.makeBoard('550px','550px',{boundingBox:[-0.8,82,16,-8], axis:false, grid:true});\n \n $(question.display.html).find('#dragpoint').append(div);\n \n var board = div.board;\n \nboard.suspendUpdate(); \n\n \n var dataArr = [yo0,yo5,0,yo1,yo6,0,yo2,yo7,0,yo3,yo8,0,yo4,yo9]; \n \n var xaxis = board.create('axis', [[0, 0], [12, 0]], {withLabel: true, name: \"Bank\", label: {offset: [250,-30]}});\n \n xaxis.removeAllTicks(); \n \n board.create('axis', [[0, 0], [0, 10]], {hideTicks:true, withLabel: false, name: \"\", label: {offset: [-110,300]}});\n \n var pop0 = board.create('point', [1.5,0],{name:'Morgan',fixed:true,size:0,color:'black',face:'diamond', label:{offset:[-20,-8]}});\n var pop1 = board.create('point',[4.5,0],{name:'Strome',fixed:true,size:0,color:'black',face:'diamond', label:{offset:[-20,-8]}});\n var pop2 = board.create('point',[7.5,0],{name:'Bentley',fixed:true,size:0,color:'black', face:'diamond', label:{offset:[-15,-8]}});\n var pop3 = board.create('point',[10.5,0],{name:'Sand',fixed:true,size:0,color:'black', face:'diamond', label:{offset:[-15,-8]}});\n var pop4 = board.create('point',[13.5,0],{name:'Karchen',fixed:true,size:0,color:'black', face:'diamond', label:{offset:[-15,-8]}});\n\n var leg1 = board.create('point',[12,75],{name:'last year',fixed:true,size:6,color:'#DA2228', face:'square', label:{offset:[9,0]}});\n var leg2 = board.create('point',[12,72],{name:'this year',fixed:true,size:6,color:'#6F1B75', face:'square', label:{offset:[9,0]}});\n \n \n// var chart = board.createElement('chart', dataArr, \n // {chartStyle:'bar', fillOpacity:1, width:1,\n // colorArray:['#8E1B77','#8E1B77','Red','Red','blue','red','blue','red','red','blue', 'red','blue','red','red'], shadow:false});\n \n//var chart = board.createElement('chart', dataArr, \n // {chartStyle:'bar', width:1,fillOpacity:1, fillColor:'red', shadow:false}); \n \n \n var a = board.create('chart', [[1,2,3],[yo0,yo5,0]], {chartStyle:'bar',colors:['#DA2228','#6F1B75','#6F1B75'],width:1,fillOpacity:1});\n var b = board.create('chart', [[4,5,6],[yo1,yo6,0]], {chartStyle:'bar',width:1,colors:['#DA2228','#6F1B75','#6F1B75'],fillOpacity:1});\n var c = board.create('chart', [[7,8,9],[yo2,yo7,0]], {chartStyle:'bar',width:1,colors:['#DA2228','#6F1B75','#6F1B75'],fillOpacity:1});\n var d = board.create('chart', [[10,11,12],[yo3,yo8,0]], {chartStyle:'bar',width:1,colors:['#DA2228','#6F1B75','#6F1B75'],fillOpacity:1});\n var e = board.create('chart', [[13,14],[yo4,yo9]], {chartStyle:'bar',width:1,colors:['#DA2228','#6F1B75'],fillOpacity:1});\n \n board.unsuspendUpdate();\n \n var txt1 = board.create('text',[-0.3,30, 'Investment \u00a3(m)'], {fontColor:'black', fontSize:14, rotate:90});\n \n // var txt = board.create('text',[0.5,75, 'Investment (m)'], {fontSize:14, rotate:90});\n \n // var txt1 = board.create('text',[8,76, 'red bars represent 2010'], {fontColor:'red', fontSize:14, rotate:90});\n \n // var txt2 = board.create('text',[8,73, 'blue bars represents 2011'], {fontSize:14, rotate:90});\n\n // var myColors = new Array('red', 'blue', 'white','red', 'blue', 'white','red', 'blue', 'white','red', 'blue', 'white','red', 'blue');\n \n \n \n //board.unsuspendUpdate();\n\n // Rotate text around the lower left corner (-2,-1) by 30 degrees.\n // var tRot = board.create('transform', [90.0*Math.PI/180.0, -1,40], {type:'rotate'}); \n // tRot.bindTo(txt);\n // board.update();\n\n \n//var chart2 = board.createElement('chart', dataArr, {chartStyle:'line,point'});\n//chart2[0].setProperty('strokeColor:black','strokeWidth:2','shadow:true');\n//for(var i=0; i<11;i++) {\n // chart2[1][i].setProperty({strokeColor:'black',fillColor:'white',face:'[]', size:4, strokeWidth:2});\n//}\n//board.unsuspendUpdate(); \n \n //board.unsuspendUpdate();\n\n}\n\nquestion.signals.on('HTMLAttached',function() {\n dragpoint_board();\n});", "css": "table#values th {\n background: none;\n text-align: center;\n}"}, "parts": [{"type": "1_n_2", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "
Banking Sector: IT Infrastructure Spending
\n

\n

What was the maximum spend by a single company last year?

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": true, "displayType": "radiogroup", "displayColumns": 0, "showCellAnswerState": true, "choices": ["

£{answer} m

", "

£{fakeanswer1} m    

", "

£{fakeanswer2} m       

", "

£{fakeanswer3} m         

", "

£{fakeanswer4} m   

"], "matrix": ["1", 0, 0, 0, 0], "distractors": ["", "", "", "", ""]}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "SA5 Interpret a Box Plot", "extensions": ["geogebra"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Lauren Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21504/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}, {"name": "Michael Pan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23528/"}], "tags": [], "metadata": {"description": "

Interpreting the elements of a box plot

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

The diagram below shows a box plot of some data.

\n

{geogebra_applet{\"https://www.geogebra.org/m/aj2hcbhg\",[lv: lv,lq: lq,m: m,uq: uq,hv: hv]}}

\n

", "advice": "

A boxplot (also known as a box-and-whisker diagram or plot) is a convenient way of graphically depicting groups of numerical data through their five-number summaries: the smallest observation (sample minimum), lower quartile (Q1), median (Q2), upper quartile (Q3), and largest observation (sample maximum). A boxplot may also indicate which observations, if any, might be considered outliers.

\n

For more information on box plots follow this link.

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"lv": {"name": "lv", "group": "Ungrouped variables", "definition": "random(2 .. 6#1)", "description": "", "templateType": "randrange", "can_override": false}, "lq": {"name": "lq", "group": "Ungrouped variables", "definition": "random(7 .. 10#1)", "description": "", "templateType": "randrange", "can_override": false}, "m": {"name": "m", "group": "Ungrouped variables", "definition": "random(11 .. 14#1)", "description": "", "templateType": "randrange", "can_override": false}, "uq": {"name": "uq", "group": "Ungrouped variables", "definition": "random(15 .. 22#1)", "description": "", "templateType": "randrange", "can_override": false}, "hv": {"name": "hv", "group": "Ungrouped variables", "definition": "random(23 .. 30#1)", "description": "", "templateType": "randrange", "can_override": false}, "IQR": {"name": "IQR", "group": "Ungrouped variables", "definition": "uq-lq", "description": "", "templateType": "anything", "can_override": false}, "range": {"name": "range", "group": "Ungrouped variables", "definition": "hv-lv", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["lv", "lq", "m", "uq", "hv", "IQR", "range"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "m_n_x", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Which of these statements are true and which are false?

", "minMarks": 0, "maxMarks": 0, "minAnswers": 0, "maxAnswers": 0, "shuffleChoices": true, "shuffleAnswers": false, "displayType": "radiogroup", "warningType": "none", "showCellAnswerState": true, "markingMethod": "sum ticked cells", "choices": ["The range of the data is $\\var{range}$.", "The Interquarttile range of the data is larger than the range of the data.", "You can calculate the mean of the data from this Box plot.", "

The median of the data is $\\var{m}$.

", "The mode of the data is $\\var{lv-3}$."], "matrix": [["1", 0], [0, "1"], [0, "1"], ["1", 0], [0, "1"]], "layout": {"type": "all", "expression": ""}, "answers": ["True.", "False."]}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "SA7 Calculate Mean from a list", "extensions": ["stats"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Lauren Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21504/"}, {"name": "Upuli Wickramaarachchi", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23527/"}, {"name": "Michael Pan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23528/"}], "tags": [], "metadata": {"description": "

Calculating the Mean from a basic list of integers.

", "licence": "None specified"}, "statement": "

Calculate the Mean from a list

", "advice": "

The MEAN is the sum, divided by the number of values summed i.e.

$\\frac{\\var{list[0]} + \\var{list[1]} + \\var{list[2]} + \\var{list[3]} + \\var{list[4]}}{5}$

\n

use your calculator to find

\n

mean = $\\var{mean}$.

\n

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"list": {"name": "list", "group": "Ungrouped variables", "definition": "repeat(random(0..20), 5)", "description": "", "templateType": "anything", "can_override": false}, "mean": {"name": "mean", "group": "Ungrouped variables", "definition": "mean(list)", "description": "", "templateType": "anything", "can_override": false}, "median": {"name": "median", "group": "Ungrouped variables", "definition": "median(list)", "description": "", "templateType": "anything", "can_override": false}, "order": {"name": "order", "group": "Ungrouped variables", "definition": "sort(list)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["list", "mean", "median", "order"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Given a list of numbers:

{list}

Calculate the mean:   [[0]]

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "mean", "maxValue": "mean", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "SA8 Calculate Mode From a list", "extensions": ["stats"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Chris Graham", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/369/"}, {"name": "Stanislav Duris", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1590/"}, {"name": "Lauren Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21504/"}, {"name": "Michael Pan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23528/"}], "tags": ["mean", "measures of average and spread", "median", "mode", "range", "taxonomy"], "metadata": {"description": "

This question provides a list of data to the student. They are asked to find the \"mode\".

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

A random sample of 20 residents from Newcastle were asked about the number of times they went to see a play at the theatre last year.

\n

Here is the list of their answers:

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
$\\var{a[0]}$$\\var{a[1]}$$\\var{a[2]}$$\\var{a[3]}$$\\var{a[4]}$$\\var{a[5]}$$\\var{a[6]}$$\\var{a[7]}$$\\var{a[8]}$$\\var{a[9]}$
$\\var{a[10]}$$\\var{a[11]}$$\\var{a[12]}$$\\var{a[13]}$$\\var{a[14]}$$\\var{a[15]}$$\\var{a[16]}$$\\var{a[17]}$$\\var{a[18]}$$\\var{a[19]}$
\n

", "advice": "

The mode is the value that occurs the most often in the data.

\n

To find a mode, we can look at our sorted list:

\n

$\\var{a_s[0]}, \\var{a_s[1]}, \\var{a_s[2]}, \\var{a_s[3]}, \\var{a_s[4]}, \\var{a_s[5]}, \\var{a_s[6]}, \\var{a_s[7]}, \\var{a_s[8]}, \\var{a_s[9]}, \\var{a_s[10]}, \\var{a_s[11]}, \\var{a_s[12]}, \\var{a_s[13]}, \\var{a_s[14]}, \\var{a_s[15]}, \\var{a_s[16]}, \\var{a_s[17]}, \\var{a_s[18]}, \\var{a_s[19]}$.

\n

We notice that $\\var{mode1}$ occurs the most ($\\var{modetimes[mode1]}$ times) so $\\var{mode1}$ is the mode.

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"a2": {"name": "a2", "group": "Ungrouped variables", "definition": "repeat(random(0..8), 20)", "description": "

Option 2 for the list. Only used if there is only one mode and option 1 was not used.

", "templateType": "anything", "can_override": false}, "modea1": {"name": "modea1", "group": "Ungrouped variables", "definition": "mode(a1)", "description": "", "templateType": "anything", "can_override": false}, "a1": {"name": "a1", "group": "Ungrouped variables", "definition": "repeat(random(0..8), 20)", "description": "

Option 1 for the list. Only used if there is only one mode.

", "templateType": "anything", "can_override": false}, "a_s": {"name": "a_s", "group": "final list", "definition": "sort(a)", "description": "

Sorted list.

", "templateType": "anything", "can_override": false}, "modea2": {"name": "modea2", "group": "Ungrouped variables", "definition": "mode(a2)", "description": "", "templateType": "anything", "can_override": false}, "a3": {"name": "a3", "group": "Ungrouped variables", "definition": "shuffle([ random(0..1),\n 2, \n random(4..6),\n random(0..3 except 2), \n random(0..3 except 2),\n random(4..6),\n 2,\n 2,\n random(4..6),\n random(7..8),\n random(0..3 except 2 except 1), \n random(4..6),\n 2,\n random(1..3 except 2), \n random(7..8),\n 2,\n random(7..8),\n random(4..6), \n random(0..3 except 2), \n 2\n])", "description": "

Option 3 for the list. Ensures there is only one mode (2) while still randomising the data.

", "templateType": "anything", "can_override": false}, "modetimes": {"name": "modetimes", "group": "final list", "definition": "map(\nlen(filter(x=j,x,a)),\nj, 0..8)", "description": "

The vector of number of times of each value in the data.

", "templateType": "anything", "can_override": false}, "mode1": {"name": "mode1", "group": "final list", "definition": "mode[0]", "description": "

Mode as a value.

", "templateType": "anything", "can_override": false}, "mode": {"name": "mode", "group": "final list", "definition": "mode(a)", "description": "

Mode as a vector.

", "templateType": "anything", "can_override": false}, "a": {"name": "a", "group": "final list", "definition": "if(len(modea1) = 1, a1, if(len(modea2) = 1, a2, a3))", "description": "

The final list.

", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["modea1", "modea2", "a1", "a2", "a3"], "variable_groups": [{"name": "final list", "variables": ["a", "a_s", "mode", "mode1", "modetimes"]}], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Find the mode.

", "minValue": "mode1", "maxValue": "mode1", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "SA9 Calculate Median from a list", "extensions": ["stats"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Chris Graham", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/369/"}, {"name": "Stanislav Duris", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1590/"}, {"name": "Lauren Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21504/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}, {"name": "Upuli Wickramaarachchi", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23527/"}, {"name": "Michael Pan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23528/"}], "tags": ["mean", "measures of average and spread", "median", "mode", "range", "taxonomy"], "metadata": {"description": "

This question provides a list of data to the student. They are asked to find the \"median\".

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

A random sample of 20 residents from Newcastle were asked about the number of times they went to see a play at the theatre last year.

\n

Here is the list of their answers:

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
$\\var{a[0]}$$\\var{a[1]}$$\\var{a[2]}$$\\var{a[3]}$$\\var{a[4]}$$\\var{a[5]}$$\\var{a[6]}$$\\var{a[7]}$$\\var{a[8]}$$\\var{a[9]}$
$\\var{a[10]}$$\\var{a[11]}$$\\var{a[12]}$$\\var{a[13]}$$\\var{a[14]}$$\\var{a[15]}$$\\var{a[16]}$$\\var{a[17]}$$\\var{a[18]}$$\\var{a[19]}$
\n

", "advice": "

The median is the middle value. We need to sort the list in order:

\n

\\[ \\var{a_s[0]}, \\quad \\var{a_s[1]}, \\quad \\var{a_s[2]}, \\quad \\var{a_s[3]}, \\quad \\var{a_s[4]}, \\quad \\var{a_s[5]}, \\quad \\var{a_s[6]}, \\quad \\var{a_s[7]}, \\quad \\var{a_s[8]}, \\quad \\var{a_s[9]}, \\quad \\var{a_s[10]}, \\quad \\var{a_s[11]}, \\quad \\var{a_s[12]}, \\quad \\var{a_s[13]}, \\quad \\var{a_s[14]}, \\quad \\var{a_s[15]}, \\quad \\var{a_s[16]}, \\quad \\var{a_s[17]}, \\quad \\var{a_s[18]}, \\quad \\var{a_s[19]} \\]

\n

There is an even number of responses, so there are two numbers in the middle (10th and 11th place). To find the median, we need to find the mean of these two numbers $\\var{a_s[9]}$ and $\\var{a_s[10]}$:

\n

\\begin{align}
\\frac{\\var{a_s[9]} + \\var{a_s[10]}}{2} &=  \\frac{\\var{a_s[9] + a_s[10]}}{2} \\\\
&= \\var{median} \\text{.} 
\\end{align}

\n

 

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"a2": {"name": "a2", "group": "Ungrouped variables", "definition": "repeat(random(0..8), 20)", "description": "

Option 2 for the list. Only used if there is only one mode and option 1 was not used.

", "templateType": "anything", "can_override": false}, "modea1": {"name": "modea1", "group": "Ungrouped variables", "definition": "mode(a1)", "description": "", "templateType": "anything", "can_override": false}, "median": {"name": "median", "group": "final list", "definition": "median(a)", "description": "", "templateType": "anything", "can_override": false}, "a1": {"name": "a1", "group": "Ungrouped variables", "definition": "repeat(random(0..8), 20)", "description": "

Option 1 for the list. Only used if there is only one mode.

", "templateType": "anything", "can_override": false}, "a_s": {"name": "a_s", "group": "final list", "definition": "sort(a)", "description": "

Sorted list.

", "templateType": "anything", "can_override": false}, "modea2": {"name": "modea2", "group": "Ungrouped variables", "definition": "mode(a2)", "description": "", "templateType": "anything", "can_override": false}, "a3": {"name": "a3", "group": "Ungrouped variables", "definition": "shuffle([ random(0..1),\n 2, \n random(4..6),\n random(0..3 except 2), \n random(0..3 except 2),\n random(4..6),\n 2,\n 2,\n random(4..6),\n random(7..8),\n random(0..3 except 2 except 1), \n random(4..6),\n 2,\n random(1..3 except 2), \n random(7..8),\n 2,\n random(7..8),\n random(4..6), \n random(0..3 except 2), \n 2\n])", "description": "

Option 3 for the list. Ensures there is only one mode (2) while still randomising the data.

", "templateType": "anything", "can_override": false}, "mean": {"name": "mean", "group": "final list", "definition": "mean(a)", "description": "", "templateType": "anything", "can_override": false}, "modetimes": {"name": "modetimes", "group": "final list", "definition": "map(\nlen(filter(x=j,x,a)),\nj, 0..8)", "description": "

The vector of number of times of each value in the data.

", "templateType": "anything", "can_override": false}, "range": {"name": "range", "group": "final list", "definition": "max(a) - min(a)", "description": "", "templateType": "anything", "can_override": false}, "mode1": {"name": "mode1", "group": "final list", "definition": "mode[0]", "description": "

Mode as a value.

", "templateType": "anything", "can_override": false}, "mode": {"name": "mode", "group": "final list", "definition": "mode(a)", "description": "

Mode as a vector.

", "templateType": "anything", "can_override": false}, "a": {"name": "a", "group": "final list", "definition": "if(len(modea1) = 1, a1, if(len(modea2) = 1, a2, a3))", "description": "

The final list.

", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["modea1", "modea2", "a1", "a2", "a3"], "variable_groups": [{"name": "final list", "variables": ["a", "a_s", "mean", "median", "mode", "mode1", "range", "modetimes"]}], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Find the median.

", "minValue": "median", "maxValue": "median", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "SA11 Identify measures of spread/location", "extensions": ["jsxgraph"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Gareth Woods", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/978/"}, {"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Lauren Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21504/"}, {"name": "Michael Pan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23528/"}], "tags": [], "metadata": {"description": "

Identifying measures of spread or location (average)

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Match each of the following with what they measure.

", "advice": "

The mean is a measure of location or central tendancy. It is calcuated by summing all of the data values and dividing by the number of values.

\n

The median is a measure of location or central tendancy. It is the middle value of an ordered data set.

\n

The inter-quartile range is a measure of spread. The interquartile range is the difference between upper and lower quartiles.The lower quartile, or first quartile (Q1), is the value under which 25% of data points are found when they are arranged in increasing order. The upper quartile, or third quartile (Q3), is the value under which 75% of data points are found when arranged in increasing order. The inter-quartile range therefore gives us an idea of the middle 50% of the ordered data set.

\n

The standard deviation is a measure of spread. It measures the dispersion of a data set relative to its mean. 

\n

The variance is a measure spread because it is the square of the standard deviation.

\n

A p-value the probability that a particular statistical measure, such as the mean or standard deviation, of an assumed probability distribution will be greater than or equal to (or less than or equal to in some instances) observed results. A p-value is used to determine statistical significance, not measures of spread or location.

\n

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

", "rulesets": {"std": ["all", "fractionNumbers"]}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": [], "variable_groups": [], "functions": {}, "preamble": {"js": "function dragpoint_board() {\n var scope = question.scope;\n\n JXG.Options.text.display = 'internal';\n \n var yo0 = scope.variables.yo0.value;\n var yo1 = scope.variables.yo1.value;\n var yo2 = scope.variables.yo2.value;\n var yo3 = scope.variables.yo3.value;\n var yo4 = scope.variables.yo4.value;\n var yo5 = scope.variables.yo5.value;\n var yo6 = scope.variables.yo6.value;\n var yo7 = scope.variables.yo7.value; \n var yo8 = scope.variables.yo8.value;\n var yo9 = scope.variables.yo9.value; \n \n var div = Numbas.extensions.jsxgraph.makeBoard('550px','550px',{boundingBox:[-0.8,82,16,-8], axis:false, grid:true});\n \n $(question.display.html).find('#dragpoint').append(div);\n \n var board = div.board;\n \nboard.suspendUpdate(); \n\n \n var dataArr = [yo0,yo5,0,yo1,yo6,0,yo2,yo7,0,yo3,yo8,0,yo4,yo9]; \n \n var xaxis = board.create('axis', [[0, 0], [12, 0]], {withLabel: true, name: \"Bank\", label: {offset: [250,-30]}});\n \n xaxis.removeAllTicks(); \n \n board.create('axis', [[0, 0], [0, 10]], {hideTicks:true, withLabel: false, name: \"\", label: {offset: [-110,300]}});\n \n var pop0 = board.create('point', [1.5,0],{name:'Morgan',fixed:true,size:0,color:'black',face:'diamond', label:{offset:[-20,-8]}});\n var pop1 = board.create('point',[4.5,0],{name:'Strome',fixed:true,size:0,color:'black',face:'diamond', label:{offset:[-20,-8]}});\n var pop2 = board.create('point',[7.5,0],{name:'Bentley',fixed:true,size:0,color:'black', face:'diamond', label:{offset:[-15,-8]}});\n var pop3 = board.create('point',[10.5,0],{name:'Sand',fixed:true,size:0,color:'black', face:'diamond', label:{offset:[-15,-8]}});\n var pop4 = board.create('point',[13.5,0],{name:'Karchen',fixed:true,size:0,color:'black', face:'diamond', label:{offset:[-15,-8]}});\n\n var leg1 = board.create('point',[12,75],{name:'last year',fixed:true,size:6,color:'#DA2228', face:'square', label:{offset:[9,0]}});\n var leg2 = board.create('point',[12,72],{name:'this year',fixed:true,size:6,color:'#6F1B75', face:'square', label:{offset:[9,0]}});\n \n \n// var chart = board.createElement('chart', dataArr, \n // {chartStyle:'bar', fillOpacity:1, width:1,\n // colorArray:['#8E1B77','#8E1B77','Red','Red','blue','red','blue','red','red','blue', 'red','blue','red','red'], shadow:false});\n \n//var chart = board.createElement('chart', dataArr, \n // {chartStyle:'bar', width:1,fillOpacity:1, fillColor:'red', shadow:false}); \n \n \n var a = board.create('chart', [[1,2,3],[yo0,yo5,0]], {chartStyle:'bar',colors:['#DA2228','#6F1B75','#6F1B75'],width:1,fillOpacity:1});\n var b = board.create('chart', [[4,5,6],[yo1,yo6,0]], {chartStyle:'bar',width:1,colors:['#DA2228','#6F1B75','#6F1B75'],fillOpacity:1});\n var c = board.create('chart', [[7,8,9],[yo2,yo7,0]], {chartStyle:'bar',width:1,colors:['#DA2228','#6F1B75','#6F1B75'],fillOpacity:1});\n var d = board.create('chart', [[10,11,12],[yo3,yo8,0]], {chartStyle:'bar',width:1,colors:['#DA2228','#6F1B75','#6F1B75'],fillOpacity:1});\n var e = board.create('chart', [[13,14],[yo4,yo9]], {chartStyle:'bar',width:1,colors:['#DA2228','#6F1B75'],fillOpacity:1});\n \n board.unsuspendUpdate();\n \n var txt1 = board.create('text',[-0.3,30, 'Investment \u00a3(m)'], {fontColor:'black', fontSize:14, rotate:90});\n \n // var txt = board.create('text',[0.5,75, 'Investment (m)'], {fontSize:14, rotate:90});\n \n // var txt1 = board.create('text',[8,76, 'red bars represent 2010'], {fontColor:'red', fontSize:14, rotate:90});\n \n // var txt2 = board.create('text',[8,73, 'blue bars represents 2011'], {fontSize:14, rotate:90});\n\n // var myColors = new Array('red', 'blue', 'white','red', 'blue', 'white','red', 'blue', 'white','red', 'blue', 'white','red', 'blue');\n \n \n \n //board.unsuspendUpdate();\n\n // Rotate text around the lower left corner (-2,-1) by 30 degrees.\n // var tRot = board.create('transform', [90.0*Math.PI/180.0, -1,40], {type:'rotate'}); \n // tRot.bindTo(txt);\n // board.update();\n\n \n//var chart2 = board.createElement('chart', dataArr, {chartStyle:'line,point'});\n//chart2[0].setProperty('strokeColor:black','strokeWidth:2','shadow:true');\n//for(var i=0; i<11;i++) {\n // chart2[1][i].setProperty({strokeColor:'black',fillColor:'white',face:'[]', size:4, strokeWidth:2});\n//}\n//board.unsuspendUpdate(); \n \n //board.unsuspendUpdate();\n\n}\n\nquestion.signals.on('HTMLAttached',function() {\n dragpoint_board();\n});", "css": "table#values th {\n background: none;\n text-align: center;\n}"}, "parts": [{"type": "m_n_x", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minMarks": 0, "maxMarks": 0, "minAnswers": 0, "maxAnswers": 0, "shuffleChoices": true, "shuffleAnswers": true, "displayType": "radiogroup", "warningType": "none", "showCellAnswerState": true, "markingMethod": "sum ticked cells", "choices": ["Variance", "Mean", "Median", "Inter-quartile range", "P-value", "Standard deviation"], "matrix": [["1", 0, 0], [0, "1", 0], [0, "1", 0], ["1", 0, 0], [0, 0, "1"], ["1", 0, 0]], "layout": {"type": "all", "expression": ""}, "answers": ["Measure of Spread", "Measure of location (average)", "Neither measure of location nor measure of spread"]}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "SA13 Correlation", "extensions": ["jsxgraph"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Richard Miles", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/882/"}, {"name": "Lauren Desoysa", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21504/"}, {"name": "Upuli Wickramaarachchi", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23527/"}], "tags": [], "metadata": {"description": "

Tests understanding of scatter plots and related concepts.

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

The scatter plot below shows the relationship between an employee’s height in centimetres and how long it takes them to walk to work in minutes.

\n\n\n\n\n\n\n\n\n\n\n\n
time (mins){drawgraph()}
height (cm)
\n

\n

\n

\n

", "advice": "

The graph shows that there is a positive correlation between a person's height and how long it takes them to walk to work.

\n

A postive correlation is a relationship between two variables where both variables move in the same diection.

\n

This tells us that as a person's height increases, the time it takes to walk to work increases.

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"slope": {"name": "slope", "group": "Regression variables", "definition": "(6*sumxy-sumx*sumy)/(6*sumxx-(sumx)^2)", "description": "

s

", "templateType": "anything", "can_override": false}, "timemax": {"name": "timemax", "group": "Calculation variables", "definition": "max([p1y,p2y,p3y,p4y,p5y,p6y])", "description": "", "templateType": "anything", "can_override": false}, "minx": {"name": "minx", "group": "Graph Limits", "definition": "140", "description": "", "templateType": "anything", "can_override": false}, "miny": {"name": "miny", "group": "Graph Limits", "definition": "-10", "description": "", "templateType": "anything", "can_override": false}, "p3x": {"name": "p3x", "group": "Points", "definition": "random(166..175)", "description": "", "templateType": "anything", "can_override": false}, "p3y": {"name": "p3y", "group": "Points", "definition": "random(26..35)", "description": "", "templateType": "anything", "can_override": false}, "p5x": {"name": "p5x", "group": "Points", "definition": "random(146..155 except p1x)", "description": "", "templateType": "anything", "can_override": false}, "p5y": {"name": "p5y", "group": "Points", "definition": "random(6..15)", "description": "", "templateType": "anything", "can_override": false}, "p1x": {"name": "p1x", "group": "Points", "definition": "random(146..155)", "description": "", "templateType": "anything", "can_override": false}, "p1y": {"name": "p1y", "group": "Points", "definition": "random(6..15)", "description": "", "templateType": "anything", "can_override": false}, "timediff": {"name": "timediff", "group": "Calculation variables", "definition": "timemax-timemin", "description": "", "templateType": "anything", "can_override": false}, "maxx": {"name": "maxx", "group": "Graph Limits", "definition": "188", "description": "", "templateType": "anything", "can_override": false}, "maxy": {"name": "maxy", "group": "Graph Limits", "definition": "63", "description": "", "templateType": "anything", "can_override": false}, "roundedslope": {"name": "roundedslope", "group": "Regression variables", "definition": "precround(slope,2)", "description": "", "templateType": "anything", "can_override": false}, "yintercept": {"name": "yintercept", "group": "Regression variables", "definition": "(sumy-slope*sumx)/6", "description": "", "templateType": "anything", "can_override": false}, "timemin": {"name": "timemin", "group": "Calculation variables", "definition": "min([p1y,p2y,p3y,p4y,p5y,p6y])", "description": "", "templateType": "anything", "can_override": false}, "tallest": {"name": "tallest", "group": "Calculation variables", "definition": "max([p1x,p2x,p3x,p4x,p5x,p6x])", "description": "", "templateType": "anything", "can_override": false}, "regy1": {"name": "regy1", "group": "Regression variables", "definition": "slope*minx+yintercept", "description": "", "templateType": "anything", "can_override": false}, "regy2": {"name": "regy2", "group": "Regression variables", "definition": "slope*maxx+yintercept", "description": "", "templateType": "anything", "can_override": false}, "sumy": {"name": "sumy", "group": "Regression variables", "definition": "p1y+p2y+p3y+p4y+p5y+p6y", "description": "", "templateType": "anything", "can_override": false}, "sumx": {"name": "sumx", "group": "Regression variables", "definition": "p1x+p2x+p3x+p4x+p5x+p6x", "description": "", "templateType": "anything", "can_override": false}, "p6y": {"name": "p6y", "group": "Points", "definition": "random(46..55)", "description": "

p6y

", "templateType": "anything", "can_override": false}, "p6x": {"name": "p6x", "group": "Points", "definition": "random(176..185 except p4x)", "description": "", "templateType": "anything", "can_override": false}, "p4y": {"name": "p4y", "group": "Points", "definition": "random(36..45)", "description": "", "templateType": "anything", "can_override": false}, "p4x": {"name": "p4x", "group": "Points", "definition": "random(176..185)", "description": "", "templateType": "anything", "can_override": false}, "p2y": {"name": "p2y", "group": "Points", "definition": "random(16..25)", "description": "", "templateType": "anything", "can_override": false}, "p2x": {"name": "p2x", "group": "Points", "definition": "random(156..165)", "description": "", "templateType": "anything", "can_override": false}, "sumxx": {"name": "sumxx", "group": "Regression variables", "definition": "p1x^2+p2x^2+p3x^2+p4x^2+p5x^2+p6x^2", "description": "", "templateType": "anything", "can_override": false}, "sumxy": {"name": "sumxy", "group": "Regression variables", "definition": "p1x*p1y+p2x*p2y+p3x*p3y+p4x*p4y+p5x*p5y+p6x*p6y", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": [], "variable_groups": [{"name": "Graph Limits", "variables": ["minx", "maxx", "miny", "maxy"]}, {"name": "Points", "variables": ["p1x", "p1y", "p2x", "p2y", "p3x", "p3y", "p4x", "p4y", "p5x", "p5y", "p6x", "p6y"]}, {"name": "Calculation variables", "variables": ["tallest", "timemax", "timemin", "timediff"]}, {"name": "Regression variables", "variables": ["sumx", "sumy", "sumxy", "sumxx", "slope", "yintercept", "regy1", "regy2", "roundedslope"]}], "functions": {"drawgraph": {"parameters": [], "type": "html", "language": "javascript", "definition": " var miny = Numbas.jme.unwrapValue(scope.variables.miny);\n var maxy = Numbas.jme.unwrapValue(scope.variables.maxy);\n var minx = Numbas.jme.unwrapValue(scope.variables.minx);\n var maxx = Numbas.jme.unwrapValue(scope.variables.maxx);\n var regy1 = Numbas.jme.unwrapValue(scope.variables.regy1);\n var regy2 = Numbas.jme.unwrapValue(scope.variables.regy2);\n\n var p1x = Numbas.jme.unwrapValue(scope.variables.p1x);\n var p1y = Numbas.jme.unwrapValue(scope.variables.p1y);\n var p2x = Numbas.jme.unwrapValue(scope.variables.p2x);\n var p2y= Numbas.jme.unwrapValue(scope.variables.p2y);\n var p3x = Numbas.jme.unwrapValue(scope.variables.p3x);\n var p3y= Numbas.jme.unwrapValue(scope.variables.p3y);\n var p4x = Numbas.jme.unwrapValue(scope.variables.p4x);\n var p4y= Numbas.jme.unwrapValue(scope.variables.p4y);\n var p5x = Numbas.jme.unwrapValue(scope.variables.p5x);\n var p5y= Numbas.jme.unwrapValue(scope.variables.p5y);\n var p6x = Numbas.jme.unwrapValue(scope.variables.p6x);\n var p6y= Numbas.jme.unwrapValue(scope.variables.p6y);\n \n var div = Numbas.extensions.jsxgraph.makeBoard('400px','400px',\n {boundingBox:[minx,maxy,maxx,miny],\n axis:false,\n showNavigation:false,\n grid:true});\n var brd = div.board; \n var xaxis=brd.createElement('axis', [[minx,0],[maxx,0]]);\n var yaxis=brd.createElement('axis', [[minx+5,miny],[minx+5,maxy]]);\n var li1=brd.create('line',[[minx,regy1],[maxx,regy2]],{fixed:true,withLabel:false});\n var pt1=brd.create('point',[p1x,p1y],{visible:true,withLabel:false}); \n var pt2=brd.create('point',[p2x,p2y],{visible:true,withLabel:false}); \n var pt3=brd.create('point',[p3x,p3y],{visible:true,withLabel:false}); \n var pt4=brd.create('point',[p4x,p4y],{visible:true,withLabel:false}); \n var pt5=brd.create('point',[p5x,p5y],{visible:true,withLabel:false}); \n var pt6=brd.create('point',[p6x,p6y],{visible:true,withLabel:false}); \nreturn div;\n "}}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "1_n_2", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Mark the statement that best describes what this scatter plot shows.

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": true, "displayType": "radiogroup", "displayColumns": 0, "showCellAnswerState": true, "choices": ["

In general, there is a positive correlation between a person's height and how long it takes them to walk to work.

", "

In general, there is a negative correlation between a person's height and how long it takes them to walk to work.

", "

In general, there is a no correlation between a person's height and how long it takes them to walk to work.

"], "matrix": ["1", 0, 0], "distractors": ["", "", ""]}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "SA14 Probability - \"sample space\"", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Mash Sheffield", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4679/"}], "tags": [], "metadata": {"description": "

Calculate probability of selecting coloured counters from a bag.

", "licence": "None specified"}, "statement": "

A bag contains:

$\\var{srn}$ small, red tokens, 
$\\var{sbn}$ small, blue tokens, 
$\\var{brn}$ large, red tokens, and 
$\\var{bbn}$ large, blue tokens.

", "advice": "

part a)

\n

A probability is a fraction.  You can give your answer as a fraction, decimal or percentage as these are all equivalent.

The formula for probability is:

\n

\\[ P(A) = \\frac{\\text{number of possibilities for A}}{\\text{number of total possible outcomes}} \\]

\n

For this question the total possible outcomes are $\\var{srn}+\\var{sbn}+\\var{brn}+\\var{bbn} = \\var{total}$.

Therefore

\n

\\[ P(\\text{A large red token}) = \\frac{\\var{brn}}{\\var{total}} = \\var[fractionnumbers]{brn/total}\\]

\n

part b)

\n

For this question we need to know the total number of small tokens, i.e. $\\var{srn}+\\var{sbn} = \\var{srn+sbn}$.

Therefore

\n

\\[ P(\\text{A small token}) = \\frac{\\var{srn+sbn}}{\\var{total}} = \\var[fractionnumbers]{(srn+sbn)/total}\\]

\n

\n

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

\n

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"srn": {"name": "srn", "group": "Ungrouped variables", "definition": "random(1..20)", "description": "", "templateType": "anything", "can_override": false}, "brn": {"name": "brn", "group": "Ungrouped variables", "definition": "random(1..20)", "description": "", "templateType": "anything", "can_override": false}, "sbn": {"name": "sbn", "group": "Ungrouped variables", "definition": "random(1..20)", "description": "", "templateType": "anything", "can_override": false}, "bbn": {"name": "bbn", "group": "Ungrouped variables", "definition": "random(1..20)", "description": "", "templateType": "anything", "can_override": false}, "total": {"name": "total", "group": "Ungrouped variables", "definition": "brn+bbn+srn+sbn", "description": "", "templateType": "anything", "can_override": false}, "ans1": {"name": "ans1", "group": "Ungrouped variables", "definition": "precround(brn/total,2)", "description": "", "templateType": "anything", "can_override": false}, "ans2": {"name": "ans2", "group": "Ungrouped variables", "definition": "precround((srn+sbn)/total,2)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["srn", "brn", "sbn", "bbn", "total", "ans1", "ans2"], "variable_groups": [{"name": "Unnamed group", "variables": []}], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

You take a token at random.

What is the probability that it is a large, red token?

Give your answer as a fraction, or a decimal correct to 2dp.

", "alternatives": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": "1", "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "alternativeFeedbackMessage": "", "useAlternativeFeedback": false, "minValue": "ans1", "maxValue": "ans1", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "minValue": "{brn}/{total}", "maxValue": "{brn}/{total}", "correctAnswerFraction": true, "allowFractions": true, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

You take a token at random.

What is the probability that it is a small token?

Give your answer as a fraction, or a decimal correct to 2dp.

", "alternatives": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": "1", "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "alternativeFeedbackMessage": "", "useAlternativeFeedback": false, "minValue": "ans2", "maxValue": "ans2", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "minValue": "{{srn}+{sbn}}/{total}", "maxValue": "{{srn}+{sbn}}/{total}", "correctAnswerFraction": true, "allowFractions": true, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "SA15 Intuitive Probability", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Upuli Wickramaarachchi", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23527/"}, {"name": "Michael Pan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23528/"}], "tags": ["taxonomy"], "metadata": {"description": "

Predicting the probability of an unbiased coin landing on heads based on the results of previous throws.

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "", "advice": "

When we flip an unbiased coin there are two possible events that we could measure: the coin lands on heads or the coin lands on tails.

\n

Each toss of the coin is independent; if we flip a coin once and it lands on heads then the next time we flip the coin it is still equally likely to land on either heads or tails.

\n

It doesn't matter what the coin landed on previously as this outcome does not affect the outcome of the next flip of the coin.

\n

Even when we flip an unbiased coin $\\var{no_flips}$ times and it lands on heads each time; the next time we flip the coin, it is still equally likely to land on either heads or tails.

\n

So the probability that the coin lands on heads the next time that the coin is flipped is still $\\displaystyle\\frac{1}{2}$.

\n

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

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"no_flips": {"name": "no_flips", "group": "Ungrouped variables", "definition": "random(6..9)", "description": "

Number of flips of the coin

", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["no_flips"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

An unbiased coin is flipped $\\var{no_flips}$ times. Given that the coin landed on heads each time, what is the probability of the coin landing on heads the next time it is flipped?

", "minValue": "1/2", "maxValue": "1/2", "correctAnswerFraction": true, "allowFractions": true, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}]}], "allowPrinting": true, "navigation": {"allowregen": true, "reverse": true, "browse": true, "allowsteps": true, "showfrontpage": true, "showresultspage": "oncompletion", "navigatemode": "sequence", "onleave": {"action": "none", "message": ""}, "preventleave": true, "typeendtoleave": true, "startpassword": "", "allowAttemptDownload": true, "downloadEncryptionKey": ""}, "timing": {"allowPause": true, "timeout": {"action": "none", "message": ""}, "timedwarning": {"action": "none", "message": ""}}, "feedback": {"showactualmark": true, "showtotalmark": true, "showanswerstate": true, "allowrevealanswer": true, "advicethreshold": 0, "intro": "

This is a tool for you! It is here to help you diagnose whether there are any maths or statistics pre-requisites for your course that you may want to brush up on. If at any point you are struggling with any question you should find a link at the end of the \"reveal answer\" section that will take you to some recommended online resources on that subject area. You can also always contact the Maths and Stats Help team (MaSH) to arrange a one to one appointment or check out our workshop timetable to see if you can access the support you need that way. Find all this information via our website here!

", "end_message": "

Thanks for completing the Skills Audit. You can attempt this as many times as you need. Remember the score is not what matters - this is in no way assessed work - this is simply a tool for working out whether you may need to brush up on anything to ensure that you can access all the material on your course and get off to the best possible start.

\n

Don't forget to look up what support is available to you through our web pages here!

", "reviewshowscore": true, "reviewshowfeedback": true, "reviewshowexpectedanswer": true, "reviewshowadvice": true, "results_options": {"printquestions": true, "printadvice": true}, "feedbackmessages": []}, "diagnostic": {"knowledge_graph": {"topics": [], "learning_objectives": []}, "script": "diagnosys", "customScript": ""}, "contributors": [{"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "extensions": ["eukleides", "geogebra", "jsxgraph", "stats"], "custom_part_types": [{"source": {"pk": 2, "author": {"name": "Christian Lawson-Perfect", "pk": 7}, "edit_page": "/part_type/2/edit"}, "name": "List of numbers", "short_name": "list-of-numbers", "description": "

The answer is a comma-separated list of numbers.

\n

The list is marked correct if each number occurs the same number of times as in the expected answer, and no extra numbers are present.

\n

You can optionally treat the answer as a set, so the number of occurrences doesn't matter, only whether each number is included or not.

", "help_url": "", "input_widget": "string", "input_options": {"correctAnswer": "join(\n if(settings[\"correctAnswerFractions\"],\n map(let([a,b],rational_approximation(x), string(a/b)),x,settings[\"correctAnswer\"])\n ,\n settings[\"correctAnswer\"]\n ),\n settings[\"separator\"] + \" \"\n)", "hint": {"static": false, "value": "if(settings[\"show_input_hint\"],\n \"Enter a list of numbers separated by {settings['separator']}.\",\n \"\"\n)"}, "allowEmpty": {"static": true, "value": true}}, "can_be_gap": true, "can_be_step": true, "marking_script": "bits:\nlet(b,filter(x<>\"\",x,split(studentAnswer,settings[\"separator\"])),\n if(isSet,list(set(b)),b)\n)\n\nexpected_numbers:\nlet(l,settings[\"correctAnswer\"] as \"list\",\n if(isSet,list(set(l)),l)\n)\n\nvalid_numbers:\nif(all(map(not isnan(x),x,interpreted_answer)),\n true,\n let(index,filter(isnan(interpreted_answer[x]),x,0..len(interpreted_answer)-1)[0], wrong, bits[index],\n warn(wrong+\" is not a valid number\");\n fail(wrong+\" is not a valid number.\")\n )\n )\n\nis_sorted:\nassert(sort(interpreted_answer)=interpreted_answer,\n multiply_credit(0.5,\"Not in order\")\n )\n\nincluded:\nmap(\n let(\n num_student,len(filter(x=y,y,interpreted_answer)),\n num_expected,len(filter(x=y,y,expected_numbers)),\n switch(\n num_student=num_expected,\n true,\n num_studentThe separate items in the student's answer

", "definition": "let(b,filter(x<>\"\",x,split(studentAnswer,settings[\"separator\"])),\n if(isSet,list(set(b)),b)\n)"}, {"name": "expected_numbers", "description": "", "definition": "let(l,settings[\"correctAnswer\"] as \"list\",\n if(isSet,list(set(l)),l)\n)"}, {"name": "valid_numbers", "description": "

Is every number in the student's list valid?

", "definition": "if(all(map(not isnan(x),x,interpreted_answer)),\n true,\n let(index,filter(isnan(interpreted_answer[x]),x,0..len(interpreted_answer)-1)[0], wrong, bits[index],\n warn(wrong+\" is not a valid number\");\n fail(wrong+\" is not a valid number.\")\n )\n )"}, {"name": "is_sorted", "description": "

Are the student's answers in ascending order?

", "definition": "assert(sort(interpreted_answer)=interpreted_answer,\n multiply_credit(0.5,\"Not in order\")\n )"}, {"name": "included", "description": "

Is each number in the expected answer present in the student's list the correct number of times?

", "definition": "map(\n let(\n num_student,len(filter(x=y,y,interpreted_answer)),\n num_expected,len(filter(x=y,y,expected_numbers)),\n switch(\n num_student=num_expected,\n true,\n num_studentHas every number been included the right number of times?

", "definition": "all(included)"}, {"name": "no_extras", "description": "

True if the student's list doesn't contain any numbers that aren't in the expected answer.

", "definition": "if(all(map(x in expected_numbers, x, interpreted_answer)),\n true\n ,\n incorrect(\"Your answer contains \"+extra_numbers[0]+\" but should not.\");\n false\n )"}, {"name": "interpreted_answer", "description": "A value representing the student's answer to this part.", "definition": "if(lower(studentAnswer) in [\"empty\",\"\u2205\"],[],\n map(\n if(settings[\"allowFractions\"],parsenumber_or_fraction(x,notationStyles), parsenumber(x,notationStyles))\n ,x\n ,bits\n )\n)"}, {"name": "mark", "description": "This is the main marking note. It should award credit and provide feedback based on the student's answer.", "definition": "if(studentanswer=\"\",fail(\"You have not entered an answer\"),false);\napply(valid_numbers);\napply(included);\napply(no_extras);\ncorrectif(all_included and no_extras)"}, {"name": "notationStyles", "description": "", "definition": "[\"en\"]"}, {"name": "isSet", "description": "

Should the answer be considered as a set, so the number of times an element occurs doesn't matter?

", "definition": "settings[\"isSet\"]"}, {"name": "extra_numbers", "description": "

Numbers included in the student's answer that are not in the expected list.

", "definition": "filter(not (x in expected_numbers),x,interpreted_answer)"}], "settings": [{"name": "correctAnswer", "label": "Correct answer", "help_url": "", "hint": "The list of numbers that the student should enter. The order does not matter.", "input_type": "code", "default_value": "", "evaluate": true}, {"name": "allowFractions", "label": "Allow the student to enter fractions?", "help_url": "", "hint": "", "input_type": "checkbox", "default_value": false}, {"name": "correctAnswerFractions", "label": "Display the correct answers as fractions?", "help_url": "", "hint": "", "input_type": "checkbox", "default_value": false}, {"name": "isSet", "label": "Is the answer a set?", "help_url": "", "hint": "If ticked, the number of times an element occurs doesn't matter, only whether it's included at all.", "input_type": "checkbox", "default_value": false}, {"name": "show_input_hint", "label": "Show the input hint?", "help_url": "", "hint": "", "input_type": "checkbox", "default_value": true}, {"name": "separator", "label": "Separator", "help_url": "", "hint": "The substring that should separate items in the student's list", "input_type": "string", "default_value": ",", "subvars": false}], "public_availability": "always", "published": true, "extensions": []}], "resources": [["question-resources/sqbasedpyramid_sEpkGzO.svg", "/srv/numbas/media/question-resources/sqbasedpyramid_sEpkGzO.svg"], ["question-resources/triangularprism.svg", "/srv/numbas/media/question-resources/triangularprism.svg"], ["question-resources/cylinder.svg", "/srv/numbas/media/question-resources/cylinder.svg"], ["question-resources/cuboid.svg", "/srv/numbas/media/question-resources/cuboid.svg"], ["question-resources/Picture1_caMIdF1.png", "/srv/numbas/media/question-resources/Picture1_caMIdF1.png"], ["question-resources/Picture2_6KE4ZpW.png", "/srv/numbas/media/question-resources/Picture2_6KE4ZpW.png"]]}