// Numbas version: exam_results_page_options {"name": "Algebra V: algebraic fractions (operations: $+,-,\\times,\\div$)", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"functions": {}, "ungrouped_variables": [], "name": "Algebra V: algebraic fractions (operations: $+,-,\\times,\\div$)", "tags": [], "preamble": {"css": "", "js": ""}, "advice": "

Learn from your mistakes and have another attempt by clicking on 'Try another question like this one' until you get full marks.

", "rulesets": {}, "parts": [{"stepsPenalty": "0", "prompt": "

$\\displaystyle\\frac{\\var{a}x}{\\var{b}}+\\frac{x+\\var{c}}{\\var{b}}=$ []

\n

$\\displaystyle\\frac{\\var{d}}{\\var{c}y}-\\frac{\\var{a}}{\\var{c}y}=$ []

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "gaps": [{"vsetrangepoints": 5, "expectedvariablenames": ["x"], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {"mark": {"order": "after", "script": "// Parse the student's answer as a syntax tree\nvar studentTree = Numbas.jme.compile(this.studentAnswer,Numbas.jme.builtinScope);\n\n// Create the pattern to match against \n// We just want to check that the student has written \"something to the power of something\"\nvar rule = Numbas.jme.compile('?? / ??');\n\n// Check the student's answer matches the pattern. \nvar m = Numbas.jme.display.matchTree(rule,studentTree,true);\n\n// If not, take away marks\nif(!m) {\n this.multCredit(0,'Your answer is not in the form $m/n$.');\n}"}}, "answer": "({a+1}x+{c})/{b}", "marks": 1, "checkvariablenames": true, "checkingtype": "absdiff", "type": "jme"}, {"vsetrangepoints": 5, "expectedvariablenames": ["y"], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {"mark": {"order": "after", "script": "// Parse the student's answer as a syntax tree\nvar studentTree = Numbas.jme.compile(this.studentAnswer,Numbas.jme.builtinScope);\n\n// Create the pattern to match against \n// We just want to check that the student has written \"something to the power of something\"\nvar rule = Numbas.jme.compile('?? / ??');\n\n// Check the student's answer matches the pattern. \nvar m = Numbas.jme.display.matchTree(rule,studentTree,true);\n\n// If not, take away marks\nif(!m) {\n this.multCredit(0,'Your answer is not in the form $m/n$.');\n}"}}, "answer": "{d-a}/({c}y)", "marks": 1, "checkvariablenames": true, "checkingtype": "absdiff", "type": "jme"}], "steps": [{"prompt": "

Add/ the numerators, leave the denominators the same as these fractions have a common denominator.

\n

\n

Let's say you need to evaluate $\\frac{2}{3}+\\frac{5}{3}$, in words this is 'two thirds plus five thirds', so how many thirds are there in total? Seven thirds!

\n

So we have

\n

\$\\frac{2}{3}+\\frac{5}{3}=\\frac{2+5}{3}=\\frac{7}{3}\$

\n

The same logic is used for subtraction. Suppose you had seven fourths and someone borrowed three fourths, then you are left with four fourths.

\n

That is

\n

\$\\frac{7}{4}-\\frac{3}{4}=\\frac{7-3}{4}=\\frac{4}{4}=1\$

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "scripts": {}, "marks": 0, "type": "information"}], "scripts": {}, "marks": 0, "showCorrectAnswer": true, "type": "gapfill"}, {"stepsPenalty": "0", "prompt": "

$\\displaystyle\\simplify{(a+{f})/{g}+({h}a+1)/{j}}=$ []

\n

$\\displaystyle\\simplify{(b+{h})/{f}-(b+{j})/{g}}=$ []

\n

$\\displaystyle \\frac{\\var{a}}{\\var{d}r}+\\var{f}r=$ []

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "gaps": [{"vsetrangepoints": 5, "expectedvariablenames": ["a"], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {"mark": {"order": "after", "script": "// Parse the student's answer as a syntax tree\nvar studentTree = Numbas.jme.compile(this.studentAnswer,Numbas.jme.builtinScope);\n\n// Create the pattern to match against \n// We just want to check that the student has written \"something to the power of something\"\nvar rule = Numbas.jme.compile('?? / ??');\n\n// Check the student's answer matches the pattern. \nvar m = Numbas.jme.display.matchTree(rule,studentTree,true);\n\n// If not, take away marks\nif(!m) {\n this.multCredit(0,'Your answer is not in the form $m/n$.');\n}"}}, "answer": "({j+g*h}a+{f*j+g})/{g*j}", "marks": "1", "checkvariablenames": true, "checkingtype": "absdiff", "type": "jme"}, {"vsetrangepoints": 5, "expectedvariablenames": ["b"], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {"mark": {"order": "after", "script": "// Parse the student's answer as a syntax tree\nvar studentTree = Numbas.jme.compile(this.studentAnswer,Numbas.jme.builtinScope);\n\n// Create the pattern to match against \n// We just want to check that the student has written \"something to the power of something\"\nvar rule = Numbas.jme.compile('?? / ??');\n\n// Check the student's answer matches the pattern. \nvar m = Numbas.jme.display.matchTree(rule,studentTree,true);\n\n// If not, take away marks\nif(!m) {\n this.multCredit(0,'Your answer is not in the form $m/n$.');\n}"}}, "answer": "({g-f}b+{g*h-f*j})/{f*g}", "marks": "1", "checkvariablenames": true, "checkingtype": "absdiff", "type": "jme"}, {"vsetrangepoints": 5, "expectedvariablenames": ["r"], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {"mark": {"order": "after", "script": "// Parse the student's answer as a syntax tree\nvar studentTree = Numbas.jme.compile(this.studentAnswer,Numbas.jme.builtinScope);\n\n// Create the pattern to match against \n// We just want to check that the student has written \"something to the power of something\"\nvar rule = Numbas.jme.compile('?? / ??');\n\n// Check the student's answer matches the pattern. \nvar m = Numbas.jme.display.matchTree(rule,studentTree,true);\n\n// If not, take away marks\nif(!m) {\n this.multCredit(0,'Your answer is not in the form $m/n$.');\n}"}}, "answer": "({a}+{f*d}r^2)/({d}r)", "marks": "1", "checkvariablenames": true, "checkingtype": "absdiff", "type": "jme"}], "steps": [{"prompt": "

Rewrite the fractions so they have a common denominator by scaling up. Then perform the addition or subtraction as required.

\n

If your question was $\\frac{5}{4}+\\frac{3}{8}$ we could rewrite the first fraction as $\\frac{10}{8}$ (by multiplying the top and bottom by 2) and then both fractions would have a denominator of 8. At this point, we can perform the addition. Our working might look like this:

\n

\$\\frac{5}{4}+\\frac{3}{8}=\\frac{5\\times 2}{4\\times 2}+\\frac{3}{8}=\\frac{10}{8}+\\frac{3}{8}=\\frac{13}{8}\$

\n

\n

Often we need to rewrite both fractions to get a common denominator, for instance, $\\frac{5}{4}-\\frac{2}{3}$. We could multiply the first fraction by 3 on the top and bottom, so that it's denominator was 12, and then multiply the second fraction by 4 on the top and bottom so that it also had a denominator of 12. Then we could perform the subtraction. Our working might look like this:

\n

\$\\frac{5}{4}-\\frac{2}{3}=\\frac{5\\times 3}{4\\times 3}-\\frac{2\\times 4}{3\\times 4}=\\frac{15}{12}-\\frac{8}{12}=\\frac{7}{12}\$

\n

\n

Also, recall that whole numbers are just fractions with a denominator of 1, for example $3=\\frac{3}{1}$.

\n

\n

In general, the best denominator is the lowest common multiple (LCM) of the two denominators.

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "scripts": {}, "marks": 0, "type": "information"}], "scripts": {}, "marks": 0, "showCorrectAnswer": true, "type": "gapfill"}, {"stepsPenalty": "0", "prompt": "

$\\displaystyle\\frac{m+1}{n+1}\\times \\frac{y}{x}=$ []

\n

$\\displaystyle -\\frac{\\var{f}+w}{\\var{j}}\\times \\var{d}=$ []

\n

\n

\n

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "gaps": [{"vsetrangepoints": 5, "expectedvariablenames": ["m", "n", "x", "y"], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {"mark": {"order": "after", "script": "// Parse the student's answer as a syntax tree\nvar studentTree = Numbas.jme.compile(this.studentAnswer,Numbas.jme.builtinScope);\n\n// Create the pattern to match against \n// We just want to check that the student has written \"something to the power of something\"\nvar rule = Numbas.jme.compile('?? / ??');\n\n// Check the student's answer matches the pattern. \nvar m = Numbas.jme.display.matchTree(rule,studentTree,true);\n\n// If not, take away marks\nif(!m) {\n this.multCredit(0,'Your answer is not in the form $m/n$.');\n}"}}, "answer": "((m+1)*y)/((n+1)*x)", "marks": 1, "checkvariablenames": true, "checkingtype": "absdiff", "type": "jme"}, {"vsetrangepoints": 5, "expectedvariablenames": ["w"], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {}, "answer": "-({d*f}+{d}w)/{j}", "marks": 1, "checkvariablenames": true, "checkingtype": "absdiff", "type": "jme"}], "steps": [{"prompt": "

Multiply the numerators and the denominators.

\n

For example

\n

\$\\frac{4}{5}\\times \\frac{2}{3}=\\frac{4\\times 2}{5 \\times 3}=\\frac{8}{15}\$

\n

\n

Also recall that whole numbers are just fractions with a denominator of 1, for example $7=\\frac{7}{1}$.

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "scripts": {}, "marks": 0, "type": "information"}], "scripts": {}, "marks": 0, "showCorrectAnswer": true, "type": "gapfill"}, {"stepsPenalty": "0", "prompt": "

$\\displaystyle{\\simplify{({f}+{a}x)^2/{h}}}\\div \\simplify{(({f}+{a}x){g})/({j}x)}=$ []

\n

$\\displaystyle \\frac{\\var{b}q}{\\var{c}q}\\div (\\var{d}+t)=$ []

\n

$\\displaystyle \\var{j}z\\div \\left(\\frac{\\var{-d}(z+1)^2}{\\var{f}z}\\right)=$ []

\n

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "gaps": [{"vsetrangepoints": 5, "expectedvariablenames": ["x"], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {"mark": {"order": "after", "script": "// Parse the student's answer as a syntax tree\nvar studentTree = Numbas.jme.compile(this.studentAnswer,Numbas.jme.builtinScope);\n\n// Create the pattern to match against \n// We just want to check that the student has written \"something to the power of something\"\nvar rule = Numbas.jme.compile('?? / ??');\n\n// Check the student's answer matches the pattern. \nvar m = Numbas.jme.display.matchTree(rule,studentTree,true);\n\n// If not, take away marks\nif(!m) {\n this.multCredit(0,'Your answer is not in the form $m/n$.');\n}"}}, "answer": "({a*j}x^2+{j*f}x)/{g*h}", "marks": "1", "checkvariablenames": true, "checkingtype": "absdiff", "type": "jme"}, {"vsetrangepoints": 5, "expectedvariablenames": [], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {"mark": {"order": "after", "script": "// Parse the student's answer as a syntax tree\nvar studentTree = Numbas.jme.compile(this.studentAnswer,Numbas.jme.builtinScope);\n\n// Create the pattern to match against \n// We just want to check that the student has written \"something to the power of something\"\nvar rule = Numbas.jme.compile('?? / ??');\n\n// Check the student's answer matches the pattern. \nvar m = Numbas.jme.display.matchTree(rule,studentTree,true);\n\n// If not, take away marks\nif(!m) {\n this.multCredit(0,'Your answer is not in the form $m/n$.');\n}"}}, "answer": "{b}/({c}({d}+t))", "marks": "1", "checkvariablenames": false, "checkingtype": "absdiff", "type": "jme"}, {"vsetrangepoints": 5, "expectedvariablenames": [], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {"mark": {"order": "after", "script": "// Parse the student's answer as a syntax tree\nvar studentTree = Numbas.jme.compile(this.studentAnswer,Numbas.jme.builtinScope);\n\n// Create the pattern to match against \n// We just want to check that the student has written \"something to the power of something\"\nvar rule = Numbas.jme.compile('?? / ??');\n\n// Check the student's answer matches the pattern. \nvar m = Numbas.jme.display.matchTree(rule,studentTree,true);\n\n// If not, take away marks\nif(!m) {\n this.multCredit(0,'Your answer is not in the form $m/n$.');\n}"}}, "answer": "({j*f}z^2)/({-d}(z+1)^2)", "marks": "1", "checkvariablenames": false, "checkingtype": "absdiff", "type": "jme"}], "steps": [{"prompt": "

Flip the second fraction and then multiply.

\n

\n

Flipping a fraction is also known as taking the reciprocal of the fraction (or inverting a fraction). Note that a whole number is also a fraction with a denominator of 1, for example, $6=\\frac{6}{1}$.

\n

How do you find half of a number? You could 'divide it by 2', or you could 'multiply by $\\frac{1}{2}$. Notice that $\\frac{1}{2}$ is the reciprocal of 2. When we divide by a number this is actually the same as multiplying by its reciprocal.

\n

\n
\n

\n

Suppose you need to evaluate $\\frac{3}{7}\\div\\frac{5}{4}$. Recall this is the same as asking 'how many $\\frac{5}{4}$s are in $\\frac{3}{7}$?', but that doesn't seem to be very helpful here! What is helpful is realising that dividing by $\\frac{5}{4}$ is the same as multiplying by $\\frac{4}{5}$. Our working could look like this

\n

\$\\frac{3}{7}\\div\\frac{5}{4}=\\frac{3}{7}\\times\\frac{4}{5}=\\frac{3\\times 4}{7\\times 5}=\\frac{12}{35}\$

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "scripts": {}, "marks": 0, "type": "information"}], "scripts": {}, "marks": 0, "showCorrectAnswer": true, "type": "gapfill"}, {"stepsPenalty": "0", "prompt": "

$\\displaystyle \\frac{\\frac{\\var{b}a+b}{c+d}}{\\frac{ \\var{b}a}{d}}=$ []

\n

\n

$\\displaystyle \\frac{\\frac{w+\\var{f}}{\\var{g}w}}{w+\\var{f}}=$ []

\n

\n

$\\displaystyle \\frac{\\var{j}r}{\\frac{\\var{h}r}{\\var{c}r}}=$ []

\n

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "gaps": [{"vsetrangepoints": 5, "expectedvariablenames": ["a", "b", "c", "d"], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {"mark": {"order": "after", "script": "// Parse the student's answer as a syntax tree\nvar studentTree = Numbas.jme.compile(this.studentAnswer,Numbas.jme.builtinScope);\n\n// Create the pattern to match against \n// We just want to check that the student has written \"something to the power of something\"\nvar rule = Numbas.jme.compile('?? / ??');\n\n// Check the student's answer matches the pattern. \nvar m = Numbas.jme.display.matchTree(rule,studentTree,true);\n\n// If not, take away marks\nif(!m) {\n this.multCredit(0,'Your answer is not in the form $m/n$.');\n}"}}, "answer": "(d({b}a+b))/({b}a(c+d))", "marks": "1", "checkvariablenames": true, "checkingtype": "absdiff", "type": "jme"}, {"vsetrangepoints": 5, "expectedvariablenames": ["w"], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {"mark": {"order": "after", "script": "// Parse the student's answer as a syntax tree\nvar studentTree = Numbas.jme.compile(this.studentAnswer,Numbas.jme.builtinScope);\n\n// Create the pattern to match against \n// We just want to check that the student has written \"something to the power of something\"\nvar rule = Numbas.jme.compile('?? / ??');\n\n// Check the student's answer matches the pattern. \nvar m = Numbas.jme.display.matchTree(rule,studentTree,true);\n\n// If not, take away marks\nif(!m) {\n this.multCredit(0,'Your answer is not in the form $m/n$.');\n}"}}, "answer": "1/({g}w)", "marks": "1", "checkvariablenames": true, "checkingtype": "absdiff", "type": "jme"}, {"vsetrangepoints": 5, "expectedvariablenames": ["r"], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "simplifyFractions", "scripts": {"mark": {"order": "after", "script": "// Parse the student's answer as a syntax tree\nvar studentTree = Numbas.jme.compile(this.studentAnswer,Numbas.jme.builtinScope);\n\n// Create the pattern to match against \n// We just want to check that the student has written \"something to the power of something\"\nvar rule = Numbas.jme.compile('?? / ??');\n\n// Check the student's answer matches the pattern. \nvar m = Numbas.jme.display.matchTree(rule,studentTree,true);\n\n// If not, take away marks\nif(!m) {\n this.multCredit(0,'Your answer is not in the form $m/n$.');\n}"}}, "answer": "{j*c}r/{h}", "marks": "1", "checkvariablenames": true, "checkingtype": "absdiff", "type": "jme"}], "steps": [{"prompt": "

The fraction bar means division.

\n

The fraction $\\frac{2}{3}$ means 2 divided by 3. So these questions are just division questions! It is important to note which fraction bar is big and which are small, so you know the order of the divisions.

\n

\n

Here are some examples:

\n

\$\\frac{7}{\\frac{5}{6}}=7\\div\\frac{5}{6} =7\\times\\frac{6}{5}=\\frac{42}{5}\$

\n

\$\\frac{\\frac{7}{5}}{6}=\\frac{7}{5}\\div 6=\\frac{7}{5}\\times \\frac{1}{6}=\\frac{7}{30}\$

\n

\$\\frac{\\frac{9}{11}}{\\frac{5}{3}}=\\frac{9}{11}\\div\\frac{5}{3}=\\frac{9}{11}\\times \\frac{3}{5}=\\frac{27}{55}\$

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "scripts": {}, "marks": 0, "type": "information"}], "scripts": {}, "marks": 0, "showCorrectAnswer": true, "type": "gapfill"}], "extensions": [], "statement": "

Evaluate the following and write your answer as a single fraction. Use  / to signify a fraction or division, for example $\\frac{2a-1}{x+3}$ is written (2a-1)/(x+3). Simplify/cancel where possible.

", "variable_groups": [{"variables": ["a", "b", "c", "d", "f", "g", "h", "j", "primes"], "name": "numerical fractions"}], "variablesTest": {"maxRuns": 100, "condition": ""}, "variables": {"a": {"definition": "primes", "templateType": "anything", "group": "numerical fractions", "name": "a", "description": ""}, "c": {"definition": "primes", "templateType": "anything", "group": "numerical fractions", "name": "c", "description": ""}, "b": {"definition": "primes", "templateType": "anything", "group": "numerical fractions", "name": "b", "description": ""}, "d": {"definition": "primes", "templateType": "anything", "group": "numerical fractions", "name": "d", "description": ""}, "g": {"definition": "primes", "templateType": "anything", "group": "numerical fractions", "name": "g", "description": ""}, "f": {"definition": "primes", "templateType": "anything", "group": "numerical fractions", "name": "f", "description": ""}, "h": {"definition": "primes", "templateType": "anything", "group": "numerical fractions", "name": "h", "description": ""}, "j": {"definition": "random(primes except [d,g,h])", "templateType": "anything", "group": "numerical fractions", "name": "j", "description": ""}, "primes": {"definition": "shuffle([2,3,5,7,11,13,17])", "templateType": "anything", "group": "numerical fractions", "name": "primes", "description": ""}}, "metadata": {"description": "

Add, subtract, multiply and divide numerical fractions.

\n

Adapted from 'Algebraic fractions: operations involving algebraic fractions' by Ben Brawn.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "type": "question", "showQuestionGroupNames": false, "question_groups": [{"name": "", "pickingStrategy": "all-ordered", "pickQuestions": 0, "questions": []}], "contributors": [{"name": "Marlon Arcila", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/321/"}]}]}], "contributors": [{"name": "Marlon Arcila", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/321/"}]}