// Numbas version: exam_results_page_options {"name": "Input 4", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"functions": {}, "name": "Input 4", "tags": ["Numbas", "algebraic expressions", "input", "introduction", "notation", "numbas", "polynomials", "symbols"], "advice": "", "rulesets": {}, "parts": [{"prompt": "

Inputting polynomials such as $3x^2+5x-2$ is easy: just input 3*x^2+5*x-2.

\n

Input this polynomial: $\\simplify[all]{{a}*x^{b}+{c}*x+{d}}=\\;$[[0]]

", "gaps": [{"expectedvariablenames": [], "checkingaccuracy": 0.001, "vsetrange": [0.0, 1.0], "showpreview": true, "vsetrangepoints": 5.0, "checkingtype": "absdiff", "answersimplification": "all", "marks": 1.0, "answer": "{a}*x^{b}+{c}x+{d}", "checkvariablenames": false, "type": "jme"}], "type": "gapfill", "marks": 0.0}, {"prompt": "

Now consider this problem.

\n

Expand the brackets and input the resulting expression:

\n

$\\simplify[all]{(x+{a}y)(x+{c}y)}=\\;$[[0]]

\n

(Do not include brackets in your answer.)

\n

Two adjacent letters are treated as a single variable: xy is not interpreted as the product of $x$ and $y$, $x \\times y$. You must use the multiplication symbol to separate the two variables, i.e. enter x*y. If you don't do this you will often be given a warning that your answer might not have been interpreted as you intended.

", "gaps": [{"notallowed": {"message": "

Do not include brackets in your answer.

", "showstrings": false, "strings": ["("], "partialcredit": 0.0}, "expectedvariablenames": ["x", "y"], "checkingaccuracy": 0.001, "vsetrange": [0.0, 1.0], "showpreview": true, "vsetrangepoints": 5.0, "checkingtype": "absdiff", "answersimplification": "all", "marks": 1.0, "answer": "x^2+{a+c}x*y+{a*c}y^2", "checkvariablenames": true, "type": "jme"}], "type": "gapfill", "marks": 0.0}], "extensions": [], "statement": "

In this example, we look at how you input algebraic expressions - those involving symbols.

\n

The box next to your input shows your answer in mathematical notation and is very important as you can use it to check your answer has been interpreted as you intended.

", "variable_groups": [], "progress": "in-progress", "type": "question", "variables": {"a": {"definition": "random(2..9)", "name": "a"}, "s": {"definition": "random(1,-1)", "name": "s"}, "b": {"definition": "random(2..4)", "name": "b"}, "c": {"definition": "s*random(1..9)", "name": "c"}, "d": {"definition": "random(1..9)", "name": "d"}}, "metadata": {"notes": "", "description": "

Inputting algebraic expressions into Numbas.

", "licence": "Creative Commons Attribution 4.0 International"}, "showQuestionGroupNames": false, "question_groups": [{"name": "", "pickingStrategy": "all-ordered", "pickQuestions": 0, "questions": []}], "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}]}]}], "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}]}