// Numbas version: exam_results_page_options {"name": "Quadratics: Interpreting the Discriminant", "extensions": ["geogebra"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "Quadratics: Interpreting the Discriminant", "tags": [], "metadata": {"description": "

Determining the number of real roots a quadratic equation has by evaluating and interpreting the discriminant.

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

By evaluating the discriminant, determine how many roots the following quadratic equation has:

\n

\\[ \\simplify[all]{{a}x^2+{b}x+{c}}=0. \\]

", "advice": "

For a quadratic expression equation of the form \\[ ax^2+bx+c = 0,\\] the discriminant is \\[ b^2-4ac.\\]

\n\n

\n

{eval}

\n

{geogebra_applet('https://www.geogebra.org/m/md6w6cs9',[a: a, b: b, c: c])}

\n

", "rulesets": {}, "extensions": ["geogebra"], "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"a": {"name": "a", "group": "Ungrouped variables", "definition": "random(1..5)", "description": "", "templateType": "anything", "can_override": false}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "random(-10..10)", "description": "", "templateType": "anything", "can_override": false}, "c": {"name": "c", "group": "Ungrouped variables", "definition": "random(-10..10)", "description": "", "templateType": "anything", "can_override": false}, "eval": {"name": "eval", "group": "Ungrouped variables", "definition": "if(b^2-4*a*c>0,{roots2},{eval2})", "description": "", "templateType": "anything", "can_override": false}, "eval2": {"name": "eval2", "group": "Ungrouped variables", "definition": "if(b^2-4*a*c=0,{roots1},{rootsNo})", "description": "", "templateType": "anything", "can_override": false}, "roots1": {"name": "roots1", "group": "Ungrouped variables", "definition": "\"

So for $\\\\simplify[all]{{a}x^2+{b}x+{c}=0}$, the discriminant is

\\n

\\\\[ \\\\begin{split} (\\\\var{b})^2-(4\\\\times \\\\var{a}\\\\times \\\\var{c}) &\\\\,= \\\\simplify[!collectNumbers]{{b^2}-{4*a*c}}, \\\\\\\\&\\\\,= \\\\var{b^2-4*a*c}.\\\\end{split} \\\\]

\\n

Therefore, this quadratic equation has 1 repeated real root.

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

So for $\\\\simplify[all]{{a}x^2+{b}x+{c}=0}$, the discriminant is

\\n

\\\\[ \\\\begin{split} (\\\\var{b})^2-(4\\\\times \\\\var{a}\\\\times \\\\var{c}) &\\\\,= \\\\simplify[!collectNumbers]{{b^2}-{4*a*c}}, \\\\\\\\&\\\\,= \\\\var{b^2-4*a*c}. \\\\end{split} \\\\]

\\n

Therefore, this quadratic equation has 2 distinct real roots.

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

So for $\\\\simplify[all]{{a}x^2+{b}x+{c}=0}$, the discriminant is

\\n

\\\\[ \\\\begin{split} (\\\\var{b})^2-(4\\\\times \\\\var{a}\\\\times \\\\var{c}) &\\\\,= \\\\simplify[!collectNumbers]{{b^2}-{4*a*c}}, \\\\\\\\&\\\\,= \\\\var{b^2-4*a*c}.\\\\end{split} \\\\]

\\n

Therefore, this quadratic equation has no real roots

\"", "description": "", "templateType": "long string", "can_override": false}, "sol": {"name": "sol", "group": "Ungrouped variables", "definition": "if(b^2-4*a*c>0,2,if(b^2-4*a*c<0,0,1))", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["a", "b", "c", "eval", "eval2", "roots1", "roots2", "rootsNo", "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": "

Number of roots: [[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": "{sol}", "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", "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/"}]}]}], "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/"}]}