// Numbas version: exam_results_page_options {"name": "Numbas: Inputting powers", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"functions": {}, "ungrouped_variables": ["a", "c", "s", "d", "f"], "name": "Numbas: Inputting powers", "tags": ["brackets", "input", "introduction", "Numbas", "numbas", "powers"], "preamble": {"css": "", "js": ""}, "advice": "", "rulesets": {}, "parts": [{"prompt": "

Input $e^{\\simplify{{a}x}}$. [[0]]

\n

Notice that your input appears in mathematical notation next to the input box so that you can check that you have entered it correctly.

\n

Click on Submit part to check your answer.

\n

\n

 

\n

 

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "gaps": [{"vsetrangepoints": 5, "expectedvariablenames": [], "checkingaccuracy": 1e-05, "vsetrange": [0, 0.1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "all", "scripts": {}, "answer": "e^({a}*x)", "marks": 1, "checkvariablenames": false, "checkingtype": "absdiff", "type": "jme"}], "showCorrectAnswer": true, "scripts": {}, "marks": 0, "type": "gapfill"}, {"prompt": "

Input $x^{\\simplify{{c} + {d}}}$.

\n

[[0]]

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "gaps": [{"vsetrangepoints": 5, "expectedvariablenames": [], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "all", "scripts": {}, "answer": "x^({c+d})", "marks": 1, "checkvariablenames": false, "checkingtype": "absdiff", "type": "jme"}], "showCorrectAnswer": true, "scripts": {}, "marks": 0, "type": "gapfill"}, {"prompt": "

Input $(xy)^{\\var{f}}$

\n

[[0]]

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "gaps": [{"notallowed": {"message": "

Input in the form $x^ay^b$ for suitable values of $a$ and $b$.

", "showStrings": false, "strings": ["xy", "x*y"], "partialCredit": 0}, "vsetrangepoints": 5, "expectedvariablenames": [], "checkingaccuracy": 0.001, "vsetrange": [0, 1], "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "answersimplification": "all", "scripts": {}, "answer": "(x*y)^{f}", "marks": 1, "checkvariablenames": false, "checkingtype": "absdiff", "type": "jme"}], "showCorrectAnswer": true, "scripts": {}, "marks": 0, "type": "gapfill"}], "extensions": [], "statement": "

This example shows you how to input powers.

\n

$a^b$ is input as a^b.

\n

But you have to be careful with inputting such expressions as

\n

\\[e^{2x},\\;x^{-2},\\;(xy)^2\\]

\n

For these you must enclose the power in brackets. 

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
ExpressionCorrect InputIncorrect InputWhy it's wrong
$e^{2x}$e^(2*x)e^2*xThe system thinks this is $(e^2) \\cdot x$.
$x^{-2}$x^(-2)x^-2This does not make any sense to the system.
$(xy)^2$(x*y)^2x*y^2The system thinks this is $x \\cdot (y^2)$.
\n

Try the following examples.

", "variable_groups": [], "variablesTest": {"maxRuns": 100, "condition": ""}, "variables": {"a": {"definition": "random(6..12)*s", "templateType": "anything", "group": "Ungrouped variables", "name": "a", "description": ""}, "c": {"definition": "random(-12..-6)", "templateType": "anything", "group": "Ungrouped variables", "name": "c", "description": ""}, "f": {"definition": "random(-5,-4,-3,-2,-1)", "templateType": "anything", "group": "Ungrouped variables", "name": "f", "description": ""}, "s": {"definition": "random(1,-1)", "templateType": "anything", "group": "Ungrouped variables", "name": "s", "description": ""}, "d": {"definition": "random(-12..-6)", "templateType": "anything", "group": "Ungrouped variables", "name": "d", "description": ""}}, "metadata": {"description": "

Information on inputting powers.

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