// Numbas version: finer_feedback_settings {"name": "Factorise a quadratic", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"functions": {}, "name": "Factorise a quadratic", "tags": ["Steps", "factorisation", "factorise a quadratic", "factorization", "factorize a quadratic", "linear factors", "quadratics", "steps"], "advice": "\n

Direct Factorisation.

\n

If you can spot a direct factorisation then this is the quickest way to do this question.

\n

For this example we have the factorisation

\n

\\[\\simplify{{a*b} * x ^ 2 + ( {-b*c-a * d}) * x + {c * d} = ({a} * x + { -c}) * ({b} * x + { -d})}\\]

\n

Factorisation by finding the roots.

\n

For if $x=r$ and $x=s$ and are the roots then $q(x)=a(x-r)(x-s)$ where $a$ is the coefficient of $x^2$.

\n

There are several methods of finding the roots – here are the main methods.

\n

Finding the roots of a quadratic using the standard formula.

\n

We can use the following formula for finding the roots of a general quadratic equation $ax^2+bx+c=0$

\n

The two roots are

\n

\\[ x = \\frac{-b +\\sqrt{b^2-4ac}}{2a}\\mbox{ and } x = \\frac{-b -\\sqrt{b^2-4ac}}{2a}\\]
there are three main types of solutions depending upon the value of the discriminant $\\Delta=b^2-4ac$

\n

1. $\\Delta \\gt 0$. The roots are real and distinct

\n

2. $\\Delta=0$. The roots are real and equal. Their common value is $-\\frac{b}{2a}$

\n

3. $\\Delta \\lt 0$. There are no real roots. The root are complex and form a complex conjugate pair.

\n

For this question the discriminant of $\\simplify{{a*b}x^2+{-b*c-a*d}x+{c*d}}$ is $\\Delta = \\simplify{{-(b*c+a*d)}^2-4*{a*b}*{c*d}={disc}}$

\n

{rdis}.

\n

So the {rep} roots are:

\n

\\[\\begin{eqnarray} x = \\frac{\\var{n1} + \\sqrt{\\var{disc}}}{\\var{n3}} &=& \\frac{\\var{n1} + \\var{n4} }{\\var{n3}} &=& \\simplify{{n1 + n4}/ {n3}}\\\\ x = \\frac{\\var{n1} - \\sqrt{\\var{disc}}}{\\var{n3}} &=& \\frac{(\\var{n1} - \\var{n4}) }{\\var{n3}} &=& \\simplify{{n1 - n4}/ {n3}} \\end{eqnarray}\\]
So we see that:
\\[q(x)=\\simplify{{a*b}}\\left(\\simplify{x-{n1 + n4}/ {n3}}\\right)\\left(\\simplify{x-{n1 - n4}/ {n3}}\\right)=\\simplify{({b} * x + { -d}) * ({a} * x + { -c})}\\]

\n

Completing the square.

\n

First we complete the square for the quadratic expression $\\simplify{{a*b}x^2+{-n1}x+{c*d}}$
\\[\\begin{eqnarray} \\simplify{{a*b}x^2+{-n1}x+{c*d}}&=&\\var{n5}\\left(\\simplify{x^2+({-n1}/{a*b})x+ {c*d}/{a*b}}\\right)\\\\ &=&\\var{n5}\\left(\\left(\\simplify{x+({-n1}/{2*a*b})}\\right)^2+ \\simplify{{c*d}/{a*b}-({-n1}/({2*a*b}))^2}\\right)\\\\ &=&\\var{n5}\\left(\\left(\\simplify{x+({-n1}/{2*a*b})}\\right)^2 -\\simplify{ {n2^2}/{4*(a*b)^2}}\\right) \\end{eqnarray} \\]
So to solve $\\simplify{{a*b}x^2+{-n1}x+{c*d}}=0$ we have to solve:
\\[\\begin{eqnarray} \\left(\\simplify{x+({-n1}/{2*a*b})}\\right)^2&\\phantom{{}}& -\\simplify{ {n2^2}/{4*(a*b)^2}}=0\\Rightarrow\\\\ \\left(\\simplify{x+({-n1}/{2*a*b})}\\right)^2&\\phantom{{}}&=\\simplify{ {n2^2}/{4*(a*b)^2}=({abs(n2)}/{2*a*b})^2} \\end{eqnarray}\\]
So we get the two {rep} solutions:
\\[\\begin{eqnarray} \\simplify{x+({-n1}/{2*a*b})}&=&\\simplify{{abs(n2)}/{2*a*b}} \\Rightarrow &x& = \\simplify{({abs(n2)+n1}/{2*a*b})}\\\\ \\simplify{x+({-n1}/{2*a*b})}&=&\\simplify{-({abs(n2)}/{2*a*b})} \\Rightarrow &x& = \\simplify{({n1-abs(n2)}/{2*a*b})} \\end{eqnarray}\\]
Finding these roots then gives the factorisation as before.

\n ", "rulesets": {"std": ["all", "!collectNumbers", "fractionNumbers"]}, "parts": [{"stepspenalty": 1.0, "prompt": "\n

\\[q(x)=\\simplify[std]{{a*b} * x ^ 2 + ( {-b*c-a * d}) * x + {c * d}}\\]
$q(x)=\\;$ [[0]]

\n


You can get more information on factorising a quadratic by clicking on Show steps. You will lose 1 mark if you do so.

\n

 

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

Factorise the expression into two factors.

", "showstrings": false, "strings": ["^", "x*x", "x x", "x(", "x (", ")x", ") x"], "partialcredit": 0.0}, "checkingaccuracy": 0.0001, "vsetrange": [0.0, 1.0], "vsetrangepoints": 5.0, "checkingtype": "absdiff", "answersimplification": "std", "marks": 2.0, "answer": "((({a} * x) + {( - c)}) * (({b} * x) + {( - d)}))", "type": "jme", "musthave": {"message": "

factorise the expression into two factors

", "showstrings": false, "strings": ["(", ")"], "partialcredit": 0.0}}], "steps": [{"prompt": "\n

Factorisation by finding the roots

\n

If you cannot spot a direct factorisation of a quadratic $q(x)$ then finding the roots of the equation $q(x)=0$ can help you.

\n

For if $x=r$ and $x=s$ and are the roots then $q(x)=a(x-r)(x-s)$ for some constant $a$.

\n

Finding the roots of a quadratic using the standard formula
We can use the following formula for finding the roots of a general quadratic equation $ax^2+bx+c=0$

\n

The two roots are

\n

\\[ x = \\frac{-b +\\sqrt{b^2-4ac}}{2a}\\mbox{ and } x = \\frac{-b -\\sqrt{b^2-4ac}}{2a}\\]
there are three main types of solutions depending upon the value of the discriminant $\\Delta=b^2-4ac$

\n

1. $\\Delta \\gt 0$. The roots are real and distinct

\n

2. $\\Delta=0$. The roots are real and equal. Their value is $\\frac{-b}{2a}$

\n

3. $\\Delta \\lt 0$. There are no real roots. The root are complex and form a complex conjugate pair.

\n ", "type": "information", "marks": 0.0}], "marks": 0.0, "type": "gapfill"}], "extensions": [], "statement": "

Factorise the following quadratic expression $q(x)$ into linear factors i.e. input $q(x)$ in the form
\\[(ax+b)(cx+d)\\] for suitable integers $a$, $b$, $c$ and $d$ .

", "variable_groups": [], "progress": "ready", "type": "question", "variables": {"a": {"definition": "random(2..5)", "name": "a"}, "c": {"definition": "c1*s3", "name": "c"}, "b": {"definition": "random(1..4)", "name": "b"}, "d": {"definition": "if(d1=-b*c/a, max(d1+1,random(1..5))*s3,d1*s3)", "name": "d"}, "f": {"definition": "a*b", "name": "f"}, "s3": {"definition": "random(1,-1)", "name": "s3"}, "s2": {"definition": "random(1,-1)", "name": "s2"}, "s1": {"definition": "random(1,-1)", "name": "s1"}, "n5": {"definition": "a*b", "name": "n5"}, "disc": {"definition": "(b*c+a*d)^2-4*a*b*c*d", "name": "disc"}, "c1": {"definition": "switch(f=1, random(1..6),f=2,random(1,3,5,7,9),f=3,random(1,2,5,7,8),f=4,random(1,3,5,7,9),f=6, random(1,5,7,8),f=9,random(1,2,4,7,8),f=8,random(1,3,5,7,9),f=12,random(1,5,7),random(1,3,5,7))", "name": "c1"}, "rep": {"definition": "switch(disc=0,'repeated', ' ')", "name": "rep"}, "n1": {"definition": "b*c+a*d", "name": "n1"}, "n2": {"definition": "b*c-a*d", "name": "n2"}, "n3": {"definition": "2*a*b", "name": "n3"}, "n4": {"definition": "abs(n2)", "name": "n4"}, "rdis": {"definition": "switch(disc=0,'The discriminant is '+ 0+' and so we get two repeated roots in this case.',disc<0, 'There are no real roots.','The roots exist and are distinct. ')", "name": "rdis"}, "d1": {"definition": "switch(f=1, random(1..6),f=2,random(1,3,5,7,9),f=3,random(1,2,5,7,8),f=4,random(1,3,5,7,9),f=6, random(1,5,7,8),f=9,random(1,2,4,7,8),f=8,random(1,3,5,7,9),f=12,random(1,5,7),random(1,3,5,7))", "name": "d1"}}, "metadata": {"notes": "\n \t\t

5/08/2012:

\n \t\t

Added more tags.

\n \t\t

Added description. 

\n \t\t

Allowed the use of decimals.

\n \t\t

Improved display of Advice.

\n \t\t", "description": "

Factorise $\\displaystyle{ax ^ 2 + bx + c}$ into linear factors. 

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