// Numbas version: exam_results_page_options {"name": "BIS110 - Biological Sciences, Zoology draft Skills Audit", "metadata": {"description": "

Skills Audit for Maths and Stats for module BIS110 students.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "duration": 0, "percentPass": 0, "showQuestionGroupNames": false, "shuffleQuestionGroups": false, "showstudentname": true, "question_groups": [{"name": "Group", "pickingStrategy": "all-ordered", "pickQuestions": 1, "questionNames": ["", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""], "variable_overrides": [[], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], []], "questions": [{"name": "NA6 - Convert Units - volume - l to ml", "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": "

Simple unit conversion with metric units. 

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

Express {liquid} litres ($l$) in millilitres ($ml$). 

", "advice": "

There are $1000ml$ in $1l$. To work out the conversion: $\\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(1 .. 6#0.01)", "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]]$ml$

", "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", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "NA8 - Convert Units - metric prefixes - milligrams to grams", "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": "

Using prefixes (milli) in this case.

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

Express {x} milligrams ($mg$) in grams ($g$). Give your answer to 3 decimal places. 

", "advice": "

There are $1000mg$ in $1g$. To work out the conversion: $\\frac{\\var{x}}{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": {"x": {"name": "x", "group": "Ungrouped variables", "definition": "random(100 .. 5200#1)", "description": "", "templateType": "randrange", "can_override": false}, "answer": {"name": "answer", "group": "Ungrouped variables", "definition": "x/1000", "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]]$g$

", "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": "ND1 Rounding DP", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"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": "Oliver Spenceley", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23557/"}], "tags": [], "metadata": {"description": "

Round numbers to a given number of decimal places.

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

We can approximate numbers by rounding.

\n

Round $\\var{c1}$ to a given number of decimal places.

", "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 decimal places, you need to decide whether to keep the last digit the 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
\n

To round a number to a given number $n$ of decimal places, we look at the $n$th digit after the decimal point.

\n

We have $\\var{c1}$.

\n

i)

\n

We look at the first digit after the decimal point. This is $\\var{cdig[4]}$ and the following digit is $\\var{cdig[3]}$ so we round updown to get $\\var{precround(c1, 1)}$.

\n

ii)

\n

The second digit after the decimal point is $\\var{cdig[3]}$. It is followed by $\\var{cdig[2]}$ so we round updown to get $\\var{precround(c1, 2)}$.

\n

iii)

\n

The 3rd decimal place is $\\var{cdig[2]}$, followed by $\\var{cdig[1]}$. We get $\\var{precround(c1, 3)}$. The 4th decimal place is $\\var{cdig[1]}$, followed by $\\var{cdig[0]}$. We get $\\var{precround(c1, 4)}$.

\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": {"c1": {"name": "c1", "group": "Ungrouped variables", "definition": "n_from_digits(cdig)*10^(-5) + random(1..5)", "description": "

Random number with 5 decimal places.

", "templateType": "anything", "can_override": false}, "cdig": {"name": "cdig", "group": "Ungrouped variables", "definition": "repeat(random(1..9), 5)", "description": "", "templateType": "anything", "can_override": false}, "dp": {"name": "dp", "group": "Ungrouped variables", "definition": "random(3..4)", "description": "

Number of decimal places to round.

", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": "100"}, "ungrouped_variables": ["dp", "cdig", "c1"], "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": "

i)   $\\var{c1}$ rounded to 1 decimal place is:  [[0]]

\n

ii)   $\\var{c1}$ rounded to 2 decimal places is:  [[1]]

\n

iii)   $\\var{c1}$ rounded to {dp} decimal places is:  [[2]]

\n

", "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": "precround(c1, 1)", "maxValue": "precround(c1, 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": "precround(c1, 2)", "maxValue": "precround(c1, 2)", "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": "precround(c1, dp)", "maxValue": "precround(c1, dp)", "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": "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": "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": "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": "NK1 standard form (large)", "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": "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/"}], "tags": ["converting", "scientific notation", "standard form"], "metadata": {"description": "

Convert numbers greater than 1 into standard form/scientific notation.

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

Write the following numbers in scientific notation.

", "advice": "

Suppose we have the number $\\var{q2}$. In scientific notation, this number would start with $\\var{dec2}$ since we only want one digit in front of the decimal point. The decimal point is currently to the right of the last digit in $\\var{q2}$ and needs to be between the first and second digits, i.e $\\var{dec2}$. Count the places that the digits must move and you get $\\var{pow2}$ places. That is,

\n

\n

\\[\\var{q2}=\\var{dec2}\\times 10^{\\var{pow2}}\\]

\n

\n

We have a positive $\\var{pow2}$ as the power because we need to make the number $\\var{dec2}$ bigger to get to $\\var{q2}$.

\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": {"pow2": {"name": "pow2", "group": "Ungrouped variables", "definition": "random(4..8)", "description": "", "templateType": "anything", "can_override": false}, "q2": {"name": "q2", "group": "Ungrouped variables", "definition": "precround(dec2*10^pow2,0)", "description": "", "templateType": "anything", "can_override": false}, "dec2": {"name": "dec2", "group": "Ungrouped variables", "definition": "random(1.1..9.9#0.001)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["dec2", "pow2", "q2"], "variable_groups": [], "functions": {"spacenumber": {"parameters": [["n", "number"]], "type": "string", "language": "javascript", "definition": "var parts=n.toString().split(\".\");\n if(parts[1] && parts[1].length<2) {\n parts[1]+='0';\n }\n return parts[0].replace(/\\B(?=(\\d{3})+(?!\\d))/g, \" \") + (parts[1] ? \", \" + parts[1] : \"\");"}}, "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": "

$\\var{q2} =$ [[0]]$\\times 10$ [[1]] 

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": "0.5", "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": false, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "{dec2}", "maxValue": "{dec2}", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": "0.5", "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": false, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "{pow2}", "maxValue": "{pow2}", "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": "NK2 standard form (small)", "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": "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": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": ["converting", "scientific notation", "standard form"], "metadata": {"description": "

Convert numbers between 0 and 1 intro standard form/scientific notation.

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

Write the following numbers in scientific notation.

", "advice": "

Suppose we have the number $\\var{q2}$. In scientific notation, this number would start with $\\var{dec2}$ since we only want one digit in front of the decimal point.  Count the places that the digits must move and you get $\\var{-pow2}$ places to the right. That is,

\n

\\[\\var{q2}=\\var{dec2}\\times 10^{\\var{pow2}}\\]

\n

\n

We have a negative $\\var{-pow2}$ as the power because we need to make the number $\\var{dec2}$ smaller to get to $\\var{q2}$.

\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": {"pow2": {"name": "pow2", "group": "Ungrouped variables", "definition": "random(list(-6..-1))", "description": "", "templateType": "anything", "can_override": false}, "dec2": {"name": "dec2", "group": "Ungrouped variables", "definition": "random(1.1..9.9#0.001)", "description": "", "templateType": "anything", "can_override": false}, "q2": {"name": "q2", "group": "Ungrouped variables", "definition": "precround(dec2*10^pow2,adjpow)", "description": "", "templateType": "anything", "can_override": false}, "adjpow": {"name": "adjpow", "group": "Ungrouped variables", "definition": "If(round(mod(dec2*1000,10))<>0,3-pow2,If(round(mod(dec2*1000,100))<>0,2-pow2,If(round(mod(dec2*1000,1000))<>0,1-pow2,0-pow2)))", "description": "", "templateType": "anything", "can_override": false}, "test": {"name": "test", "group": "Ungrouped variables", "definition": "mod(1000*dec2,10)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["dec2", "pow2", "q2", "adjpow", "test"], "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": "

$\\var{q2}$ = [[0]]$\\times 10$ [[1]]

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": "0.5", "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": false, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "{dec2}", "maxValue": "{dec2}", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": "0.5", "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": false, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "{pow2}", "maxValue": "{pow2}", "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": "AA4 Indices - Fractional 2", "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: Indices"], "metadata": {"description": "

Using indices rules to rewrite an expression from $a^\\frac{m}{n}$ to $b$, for integers $a$, $b$, $m$ and $n$.

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

Evaluate the following expression:

\n

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

", "advice": "

To find $\\var{a^n}^{\\frac{\\var{m}}{\\var{n}}}$, we want to make use of the following rule:

\n

\\[\\left(a^n\\right)^m = a^{n\\times m}\\]

\n

By rewriting the power $\\frac{\\var{m}}{\\var{n}}$ as a product of $\\var{m} \\times \\frac{1}{\\var{n}}$, we can apply this rule:

\n

\\[ \\begin{split} \\var{a^n}^{\\frac{\\var{m}}{\\var{n}}} &\\,= \\var{a^n}^{\\left(\\var{m} \\times \\frac{1}{\\var{n}}\\right)} \\\\ &\\,= \\left(\\var{a^n}^\\frac{1}{\\var{n}}\\right)^\\var{m} \\\\ &\\,= \\var{a}^\\var{m}\\end{split} \\]

\n

Then calculating what is left:

\n

\\[ \\begin{split} \\var{a}^\\var{m} &\\,=\\var{a^(m)} \\end{split} \\]

\n

Therefore,

\n

\\[ \\var{a^n}^{\\frac{\\var{m}}{\\var{n}}} =\\var{a^(m)}. \\]

\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": {"m": {"name": "m", "group": "Ungrouped variables", "definition": "random(2,3)", "description": "", "templateType": "anything", "can_override": false}, "n": {"name": "n", "group": "Ungrouped variables", "definition": "random(2..3 except m)", "description": "", "templateType": "anything", "can_override": false}, "a": {"name": "a", "group": "Ungrouped variables", "definition": "random(2,3,4)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["m", "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^m}", "maxValue": "{a^m}", "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": "AB1 - Collecting terms", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Michael Proudman", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/269/"}, {"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": "

Simple exercise in collecting terms in different powers of \\(x\\)

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

Simplify the following expression by combining \"like\" terms.

", "advice": "

The idea is to collect together and combine any terms that are the same kind of term so:

\n

$\\var{b}$ and $\\var{f}$ are ordinary numbers. We can combine them to get $\\var{b+f}$

\n

We can combine $\\var{a}x$ and $\\var{d}x$ to get $\\var{a+d}x$.

\n

We combine $\\var{c}y$ and $\\var{e}y$ to get $\\var{c+e}y$. So our answer is:

\n

$\\simplify{{c+e}y+{a+d}x+{b+f}}$

\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": {"c": {"name": "c", "group": "Ungrouped variables", "definition": "random(-5..10 except 0)", "description": "", "templateType": "anything", "can_override": false}, "d": {"name": "d", "group": "Ungrouped variables", "definition": "random(-5..10 except 0)", "description": "", "templateType": "anything", "can_override": false}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "random(-5..10 except 0)", "description": "", "templateType": "anything", "can_override": false}, "a": {"name": "a", "group": "Ungrouped variables", "definition": "random(1..10)", "description": "", "templateType": "anything", "can_override": false}, "f": {"name": "f", "group": "Ungrouped variables", "definition": "random(-5..10 except 0 except -b)", "description": "", "templateType": "anything", "can_override": false}, "e": {"name": "e", "group": "Ungrouped variables", "definition": "random(-5..10 except 0 except -c)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["a", "c", "b", "d", "f", "e"], "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, "prompt": "

$\\simplify[!collectNumbers]{{a}x+{b}+{c}y+{d}x+{f}+{e}y}$

", "answer": "({c}+{e})y+({a}+{d})x+({b}+{f})", "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`?*y+`+-$n`?*x+`+-$n`?", "partialCredit": 0, "message": "", "nameToCompare": ""}, "valuegenerators": [{"name": "x", "value": ""}, {"name": "y", "value": ""}]}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AB3 - Collecting terms (higher powers)", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Michael Proudman", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/269/"}, {"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": "

Simple exercise in collecting terms in different powers of \\(x\\)

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

Simplify the following expression by combining \"like\" terms.

", "advice": "

First we expand the minus sign in the bracket.

\n

\\[\\simplify[!collectNumbers]{{a}x^4+{b}x+{c}x^3+{d}x^4-({f}x+{e}x^3)}=\\simplify[!collectNumbers]{{a}x^4+{b}x+{c}x^3+{d}x^4+{-f}x+{-e}x^3}\\]

\n

The idea is to collect together and combine any terms that are the same kind of term so:

\n

$\\var{b}x$ and $\\var{-f}x$ both have an $x$ term. We can combine them to get $\\var{b-f}x$

\n

We can combine $\\var{a}x^4$ and $\\var{d}x^4$ to get $\\var{a+d}x^4$.

\n

We combine $\\var{c}x^3$ and $\\var{-e}x^3$ to get $\\var{c-e}x^3$. So our answer is:

\n

$\\simplify{{a+d}x^4+{c+e}x^3+{b+f}}$

\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": {"c": {"name": "c", "group": "Ungrouped variables", "definition": "random(-5..10 except 0)", "description": "", "templateType": "anything", "can_override": false}, "d": {"name": "d", "group": "Ungrouped variables", "definition": "random(-5..10 except 0)", "description": "", "templateType": "anything", "can_override": false}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "random(-5..10 except 0)", "description": "", "templateType": "anything", "can_override": false}, "a": {"name": "a", "group": "Ungrouped variables", "definition": "random(1..10)", "description": "", "templateType": "anything", "can_override": false}, "f": {"name": "f", "group": "Ungrouped variables", "definition": "random(-5..10 except 0 except b)", "description": "", "templateType": "anything", "can_override": false}, "e": {"name": "e", "group": "Ungrouped variables", "definition": "random(-5..10 except 0 except c)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["a", "c", "b", "d", "f", "e"], "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, "prompt": "

$\\simplify[!collectNumbers]{{a}x^4+{b}x+{c}x^3+{d}x^4-({f}x+{e}x^3)}$

", "answer": "({a}+{d})x^4+({c}-{e})x^3+({b}-{f})x", "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^4+`+-$n`?*x^3+`+-$n`?*x", "partialCredit": 0, "message": "", "nameToCompare": ""}, "valuegenerators": [{"name": "x", "value": ""}]}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AB5 Expand single brackets", "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": "Bradley Bush", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1521/"}, {"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": ["brackets", "expanding brackets", "expansion of brackets", "simplifying algebraic expressions", "simplifying expressions", "taxonomy"], "metadata": {"description": "

This question is made up of 10 exercises to practice the multiplication of brackets by a single term.

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

Expand the expression below by multiplying each of the terms inside the brackets by the term outside. Give the answer in its simplest form.

", "advice": "

Expand brackets using the general formula $\\displaystyle a(x+c)=ax+ac$. This means we multiply each term inside the brackets by the term outside the brackets.

\n

It is easy to forget that the sign outside the brackets also needs to be involved in the multiplication so remember that when two of the same sign are multiplied, the resultant term is positive and when opposite signs are multiplied, the result is negative.

\n

\\[
\\begin{align}
\\simplify[terms]{{a[7]}x({a[8]}x^2+{a[9]}x)}&=
\\simplify[!collectNumbers]{{a[7]}x{a[8]}x^2+{a[7]}x{a[9]}x}\\\\&=
\\simplify{{a[7]}*{a[8]}x^3+{a[7]}*{a[9]}x^2}\\text{.}
\\end{align}
\\]

\n

Use this link to find resources to help you revise how to expand single brackets

", "rulesets": {"terms": ["all", "!collectNumbers", "!unitFactor", "!noLeadingMinus"]}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"a": {"name": "a", "group": "Ungrouped variables", "definition": "repeat(random(-10..10 except [-1,0,1] ),50)", "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[7]}x({a[8]}x^2+{a[9]}x)}=$ [[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[7]*a[8]}x^3+{a[7]*a[9]}x^2", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": true, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "mustmatchpattern": {"pattern": "`+-$n*x^3 + `+-$n*x^2", "partialCredit": 0, "message": "", "nameToCompare": ""}, "valuegenerators": [{"name": "x", "value": ""}]}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "AB6 - Factorise by taking out a factor", "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/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}], "tags": [], "metadata": {"description": "

Factorise an expression of 2 or 3 terms where the gcd is a letter times a number. Part of HELM Book 1.3.4

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

Factorise $\\var{q2expr}$

\n

", "advice": "

The two terms share a common factor of $\\var{q2gcd}\\var{latex(q2v[0])}$ which can be factored out.

\n

So $\\var{q2expr} = \\var{q2ans}$

\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": {"alphabet": {"name": "alphabet", "group": "Ungrouped variables", "definition": "shuffle(['a','b','c','d','f','g','h','k','m','n','p','q','r','s','t','u','v','w','x','y','z'])", "description": "", "templateType": "anything", "can_override": false}, "q2c": {"name": "q2c", "group": "question part c", "definition": "[random(-9..9 except 0), random(-9..9 except 0), random(2..9)]", "description": "", "templateType": "anything", "can_override": false}, "q2v": {"name": "q2v", "group": "question part c", "definition": "alphabet[2..4]", "description": "", "templateType": "anything", "can_override": false}, "q2expr": {"name": "q2expr", "group": "question part c", "definition": "simplify(expression(\n q2terms[0] + \"+\" + q2terms[1]\n ),[\"basic\",\"cancelFactors\",\"unitFactor\"])", "description": "", "templateType": "anything", "can_override": false}, "q2terms": {"name": "q2terms", "group": "question part c", "definition": "[q2coeffs[0] +\"*\"+ q2v[0],q2coeffs[1] +\"*\"+ q2v[0]+\"^2\"]", "description": "", "templateType": "anything", "can_override": false}, "q2gcd": {"name": "q2gcd", "group": "question part c", "definition": "if( (q2c[0] < 0 & q2c[1] < 0),\n-1*gcd(q2c[0],q2c[1])*q2c[2],\ngcd(q2c[0],q2c[1])*q2c[2]\n)", "description": "", "templateType": "anything", "can_override": false}, "q2ans": {"name": "q2ans", "group": "question part c", "definition": "simplify(expression(\n q2gcd + \"*\" + q2v[0] + \"*(\" + q2c[0]*q2c[2]/q2gcd + \"+\" + q2c[1]*q2c[2]/q2gcd + q2v[0] + \")\" ),[\"basic\",\"unitFactor\"])", "description": "", "templateType": "anything", "can_override": false}, "q2coeffs": {"name": "q2coeffs", "group": "question part c", "definition": "[q2c[0]*q2c[2],q2c[1]*q2c[2]]", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["alphabet"], "variable_groups": [{"name": "question part c", "variables": ["q2c", "q2v", "q2coeffs", "q2terms", "q2expr", "q2gcd", "q2ans"]}], "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": "{q2ans}", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": true, "singleLetterVariables": true, "allowUnknownFunctions": false, "implicitFunctionComposition": false, "caseSensitive": false, "musthave": {"strings": ["(", ")"], "showStrings": false, "partialCredit": 0, "message": ""}, "mustmatchpattern": {"pattern": "// a number and a letter times...\n`+-$n`? * $v *\n(\n // either a number 'a' times x,\n // or x on its own, and 'a' is implicitly 1\n `+-($n;a * $v`? `| $v;a:1) \n \n + `+-\n \n // either a number 'b' times x,\n // or x on its own, and 'b' is implicitly 1\n ($n;b * $v`? `| $v;b:1)\n)\n\n// a and b must be coprime\n`where\n\n(gcd(a,b)=1)", "partialCredit": 0, "message": "You have not fully factorised the expression.", "nameToCompare": ""}, "valuegenerators": []}], "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": "AB8 Expand Double Brackets (Hard)", "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": "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": "

Expand two brackets involving powers of $x$.

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

Expand the brackets and simplify

", "advice": "

To expand the brackets $\\simplify{({a[1]}x^{b[1]}+{a[2]}x^{b[2]})({a[3]}x^{b[3]}+{c[1]}x^{b[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]}x^\\var{b[1]}\\times\\var{a[3]}x^\\var{b[3]}+\\var{a[1]}x^\\var{b[1]}\\times\\var{c[1]}x^\\var{b[4]}+\\var{a[2]}x^\\var{b[2]}\\times\\var{a[3]}x^\\var{b[3]}+\\var{a[2]}x^\\var{b[2]}\\times\\var{c[1]}x^\\var{b[4]}\\]

\n

We can then simplify to give us the final answer of

\n

$\\simplify{{a[1]*a[3]}*x^{b[1]+b[3]}+{a[1]*c[1]}*x^{b[1]+b[4]}+{a[2]*a[3]}*x^{b[2]+b[3]}+{a[2]*c[1]}*x^{b[2]+b[4]}}.$

\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": "repeat(random(-5..10 except [0]),5\n)", "description": "", "templateType": "anything", "can_override": false}, "c": {"name": "c", "group": "Ungrouped variables", "definition": "repeat(random([-5,-9/2,-4,7/2,-3,-5/2,-2,-3/2,-1,-1/2,1/2,1,3/2,2,5/2,3,7/2,4,9/2,5]),5)", "description": "", "templateType": "anything", "can_override": false}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "shuffle(1..6)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["a", "c", "b"], "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^{b[1]}+{a[2]}x^{b[2]})({a[3]}x^{b[3]}+{c[1]}x^{b[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^{b[1]+b[3]}+{a[1]*c[1]}*x^{b[1]+b[4]}+{a[2]*a[3]}*x^{b[2]+b[3]}+{a[2]*c[1]}*x^{b[2]+b[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, "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": "AC3 Algebraic substitution", "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": "

Substitute values into an algebraic expression and calculate the result.

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

Evaluate the following expression,

\n

\\[\\simplify{p^{n}+{a}*r*t+{c}},\\]

\n

when $p = \\var{pval}$, $r = \\var{rval}$, and $t = \\var{tval}$.

", "advice": "

In order to evaluate $\\simplify{p^{n}+{a}*r*t+{c}},$ with the given values, $p = \\var{pval}$, $r = \\var{rval}$, and $t = \\var{tval}$, we replace each instance of that letter with its corresponding value and then apply the rules of BIDMAS:

\n

\\[\\var{pval}^\\var{n}+\\var{a}\\times \\var{rval} \\times \\var{tval} + \\var{c}\\]

\n

Which gives the answer $\\var{ans}$.

\n

Follow this link for more help on tackling these kind of questions.

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"n": {"name": "n", "group": "Ungrouped variables", "definition": "random(2 .. 3#1)", "description": "", "templateType": "randrange", "can_override": false}, "a": {"name": "a", "group": "Ungrouped variables", "definition": "random(2 .. 9#1)", "description": "", "templateType": "randrange", "can_override": false}, "c": {"name": "c", "group": "Ungrouped variables", "definition": "Random(-6..6 except 0)", "description": "", "templateType": "anything", "can_override": false}, "pval": {"name": "pval", "group": "Ungrouped variables", "definition": "random(2 .. 9#1)", "description": "", "templateType": "randrange", "can_override": false}, "rval": {"name": "rval", "group": "Ungrouped variables", "definition": "random(-9 .. -2#1)", "description": "", "templateType": "randrange", "can_override": false}, "tval": {"name": "tval", "group": "Ungrouped variables", "definition": "random(-12..12 except 0)", "description": "", "templateType": "anything", "can_override": false}, "ans": {"name": "ans", "group": "Ungrouped variables", "definition": "{pval}^{n}+{a}*{rval}*{tval}+{c}", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["n", "a", "c", "pval", "rval", "tval", "ans"], "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": "{pval}^{n}+{a}*{rval}*{tval}+{c}", "maxValue": "{pval}^{n}+{a}*{rval}*{tval}+{c}", "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": "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": "GA2 Pythagoras - triangle", "extensions": ["geogebra"], "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": "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": "

Draws a triangle based on 3 side lengths and randomises asking for hypotenuse or not.

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

{statement}

\n

Find $x$.

", "advice": "

Only round your final answer to 1 decimal place.

\n

{advice}

\n

Use this link to find some resources to help you revise how to use pythagoras' theorem.

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"setup": {"name": "setup", "group": "Varying q and advice", "definition": "random(1,2)", "description": "", "templateType": "anything", "can_override": false}, "answerside": {"name": "answerside", "group": "Varying q and advice", "definition": "sh1", "description": "", "templateType": "anything", "can_override": false}, "answerhyp": {"name": "answerhyp", "group": "Varying q and advice", "definition": "hyp", "description": "", "templateType": "anything", "can_override": false}, "ans": {"name": "ans", "group": "Varying q and advice", "definition": "if(setup=1,answerside,answerhyp)", "description": "", "templateType": "anything", "can_override": false}, "advice": {"name": "advice", "group": "Varying q and advice", "definition": "if(setup=1,advice1,advice2)", "description": "", "templateType": "anything", "can_override": false}, "advice2": {"name": "advice2", "group": "Varying q and advice", "definition": "\"

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

Pythagoras Theorem states that, in a right angled triangle, with hypotenuse $c$:

\\n

\\\\[a^2 + b^2 = c^2\\\\]

\\n

Let\\'s call the unknown value $x$, therefore we can write:

\\n

$a = \\\\var{sh1}$,  $b =\\\\var{sh2}$ and $c = x$

\\n

So

\\\\[\\\\var{sh1}^2 + \\\\var{sh2}^2 = x^2\\\\]

\\n

and therefore

\\n

\\\\[x^2 = \\\\var{sh1^2} + \\\\var{sh2^2}\\\\]

\\\\[x = \\\\sqrt{\\\\var{sh1^2} + \\\\var{sh2^2}}\\\\]

\\n

\\\\[x = \\\\sqrt{\\\\var{sh1^2+sh2^2}}\\\\]

$x = \\\\var{hyp}$ to 1 d.p.

\"", "description": "", "templateType": "long string", "can_override": false}, "advice1": {"name": "advice1", "group": "Varying q and advice", "definition": "\"

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

Pythagoras Theorem states that, in a right angled triangle, with hypotenuse $c$:

\\n

\\\\[a^2 + b^2 = c^2\\\\]

\\n

Let\\'s call the unknown value $x$, therefore we can write:

\\n

$a = x$,  $b =\\\\var{sh2}$ and $c = \\\\var{hyp}$

\\n

So

\\n

\\\\[x^2 + \\\\var{sh2}^2 = \\\\var{hyp}^2\\\\]

\\n

and therefore

\\n

\\\\[x^2 = \\\\var{hyp^2} - \\\\var{sh2^2}\\\\]

\\n

\\\\[x = \\\\sqrt{\\\\var{hyp^2-sh2^2}}\\\\]

$x = \\\\var{sh1}$ to 1 d.p.

\"", "description": "", "templateType": "long string", "can_override": false}, "statement1": {"name": "statement1", "group": "Varying q and advice", "definition": "{geogebra_applet('https://www.geogebra.org/m/zhu32wjq',[sh1: sh1, sh2: sh2])}", "description": "

\n

", "templateType": "anything", "can_override": false}, "statement2": {"name": "statement2", "group": "Varying q and advice", "definition": "{geogebra_applet('https://www.geogebra.org/m/b8wz2vn9',[sh1: sh1, sh2: sh2])}", "description": "", "templateType": "anything", "can_override": true}, "statement": {"name": "statement", "group": "Varying q and advice", "definition": "if(setup=1,statement1,statement2)", "description": "", "templateType": "anything", "can_override": false}, "hyp": {"name": "hyp", "group": "Unnamed group", "definition": "precround(sqrt(sh1^2+sh2^2),1)", "description": "", "templateType": "anything", "can_override": false}, "sh1_gen": {"name": "sh1_gen", "group": "Unnamed group", "definition": "random(5 .. 10#0.1)", "description": "

one of two shortest sides for calculations.

", "templateType": "randrange", "can_override": false}, "sh1": {"name": "sh1", "group": "Unnamed group", "definition": "precround(sh1_gen,1)", "description": "", "templateType": "anything", "can_override": false}, "sh2_gen": {"name": "sh2_gen", "group": "Unnamed group", "definition": "random(4 .. 9#0.1)", "description": "", "templateType": "randrange", "can_override": true}, "sh2": {"name": "sh2", "group": "Unnamed group", "definition": "precround(sh2_gen,1)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": "10"}, "ungrouped_variables": [], "variable_groups": [{"name": "Unnamed group", "variables": ["hyp", "sh1_gen", "sh1", "sh2_gen", "sh2"]}, {"name": "Varying q and advice", "variables": ["setup", "answerside", "answerhyp", "ans", "advice", "advice2", "advice1", "statement1", "statement2", "statement"]}], "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]] 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": "GA3 Area of a circle", "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": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}, {"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": "

Finding the area of a circle when given the diameter of the circle.

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

Find the area of a circle with diameter $\\var{d}$ cm giving your answer to 1 decimal place.

\n

{geogebra_applet('https://www.geogebra.org/m/ngcchpcj',[d: d])}

", "advice": "

To calculate the area of a circle we want to use the formula \\[ A = \\pi r^2, \\]

\n

where $r$ is the radius of the circle.

\n

So, if the diameter, d, is $\\var{d}$ cm, then the radius is, $r=\\frac{d}{2}=\\var{{d}/2}$ cm, then

\n

\\[ \\begin{split} Area &\\,=\\var{{d}/2}^2 \\times \\pi \\text{ cm}^2 \\\\ &\\,= \\simplify[all, fractionNumbers]{{{{d}^2/4}}pi} \\text{ cm}^2 \\\\ &\\,= \\var{precround({d}^2/4*pi,1)} \\text{ cm}^2. \\end{split} \\]

\n

Use this link to find some resources to help you revise how to calculate the area of a circle.

\n

", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"d": {"name": "d", "group": "Ungrouped variables", "definition": "random(6,8,10,12,14,16,18,20)", "description": "", "templateType": "anything", "can_override": true}, "t": {"name": "t", "group": "Ungrouped variables", "definition": "random(2..6)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["d", "t"], "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": "

$Area=$ [[0]] $\\text{ cm}^2$

", "gaps": [{"type": "jme", "useCustomName": true, "customName": "Gap 0", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": false, "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": "", "useAlternativeFeedback": false, "answer": "precround({{d/2}}^2*pi,1)", "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": []}], "answer": "precround({{d/2}}^2*pi,1)", "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": "GA4 Volume of a triangular prism", "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 triangular prism, we first need to find the area of one of the faces then multiply this area by the depth of the prism.
In this example the easiest way to calculate the volume is to take the area of the triangular face first with $\\mathrm{base} = \\var{w6}m$ and $\\mathrm{height} = \\var{h6}m\\thinspace$.

\n

\\begin{align}
\\mathrm{Area\\thinspace_\\triangle} &= \\frac{\\mathrm{base} \\times \\mathrm{height}}{2} \\\\
&= \\frac{\\var{w6} \\times \\var{h6}}{2} \\\\
&= \\var{0.5*w6*h6}\\, \\mathrm{m}^2\\,.
\\end{align}

\n

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

\n

\\begin{align}
\\mathrm{Volume} &= \\mathrm{Area\\thinspace_\\triangle} \\times \\mathrm{depth} \\\\
&= \\var{0.5*w6*h6} \\times \\var{d6} \\\\
&= \\var{0.5*w6*h6*d6}\\, \\mathrm{m}^2\\,.
\\end{align}

\n

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

", "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 triangular prism.

\n

\n

$\\mathrm{Volume} =$[[0]]$\\mathrm{m}^3$.

", "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 triangular prism:

\n

\\begin{align}
\\mathrm{Volume} &= \\mathrm{Area\\thinspace_\\triangle} \\times \\mathrm{depth} \\\\
&= \\frac{\\mathrm{base} \\times \\mathrm{height}}{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": "0.5{w6}{h6}{d6}", "maxValue": "0.5{w6}{h6}{d6}", "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": "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": "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": "SA6 Calculate Range", "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": "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 \"range\".

", "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": "

Range is the difference between the highest and the lowest value in the data.

\n

To find this, we subtract the lowest value from the highest value:

\n

\\[ \\var{max(a)} - \\var{min(a)} = \\var{range} \\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": {"a2": {"name": "a2", "group": "Ungrouped variables", "definition": "repeat(random(1..9), 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(1..9), 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}, "range": {"name": "range", "group": "final list", "definition": "max(a) - min(a)", "description": "", "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", "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 range.

", "minValue": "range", "maxValue": "range", "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": "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": "SA10 Choosing the appropriate average", "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": "Michael Pan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23528/"}], "tags": [], "metadata": {"description": "

This question asks the student to choose the appropriate measure of average and spread for a data with outliers.

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

Which of the following measures would you choose if you were dealing with data which includes outliers? Select one measure of average and one measure of spread.

", "advice": "

The median is a more appropriate measure of average when your data contains outliers because outliers do not affect the median.

\n

The interquartile range is the best measure of variability for skewed distributions or data sets with outliers. Because it’s based on values that come from the middle half of the distribution, it’s unlikely to be influenced by outliers.

\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": {}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": [], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "m_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, "minMarks": 0, "maxMarks": 0, "shuffleChoices": true, "displayType": "checkbox", "displayColumns": 0, "minAnswers": 0, "maxAnswers": 0, "warningType": "none", "showCellAnswerState": true, "markingMethod": "sum ticked cells", "choices": ["Mean", "Median", "Standard deviation", "P-value", "Range", "Inter-quartile range"], "matrix": [0, "1", 0, 0, 0, "1"], "distractors": ["", "", "", "", "", ""]}], "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": ["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/Picture1_caMIdF1.png", "/srv/numbas/media/question-resources/Picture1_caMIdF1.png"], ["question-resources/Picture2_6KE4ZpW.png", "/srv/numbas/media/question-resources/Picture2_6KE4ZpW.png"], ["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"]]}