 Student[Precalculus] - Maple Programming Help

Home : Support : Online Help : Education : Student Packages : Precalculus : Computation : Student/Precalculus/CompleteSquare

Student[Precalculus]

 CompleteSquare
 transform quadratic expressions to completed square form

 Calling Sequence CompleteSquare(f, x, ...)

Parameters

 f - algebraic expression, equation, or an inequality involving algebraic terms x - (optional) name, function, list, or set ... - (optional) name or function

Description

 • The CompleteSquare(f, x) command, where f is a quadratic expression, equation, or an inequality in x, completes the square of f.  If f is not itself quadratic in x, its subexpressions are examined, and any which are quadratic in x are transformed to completed square form.
 • If x is a list or set, the operation of completing the square is applied successively to each component of x.  These components can be names, such as $u$ and $v$, or functions, such as $\mathrm{sin}\left(t\right)$ and $\frac{ⅆ}{ⅆw}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}h\left(w\right)$.
 • The CompleteSquare(f) command is equivalent to CompleteSquare(f, indets(f,name)).
 • The command CompleteSquare(f, [x, y]) is equivalent to the command CompleteSquare(f, x, y).
 • The completed square form of the general quadratic expression $a{x}^{2}+bx+c$ is $a{\left(x+\frac{b}{2a}\right)}^{2}+c-\frac{{b}^{2}}{4a}$.

Examples

 > $\mathrm{with}\left(\mathrm{Student}\left[\mathrm{Precalculus}\right]\right):$
 > $\mathrm{CompleteSquare}\left(3{x}^{2}+2x,x\right)$
 ${3}{}{\left({x}{+}\frac{{1}}{{3}}\right)}^{{2}}{-}\frac{{1}}{{3}}$ (1)
 > $\mathrm{CompleteSquare}\left({x}^{2}{\left(1-y\right)}^{3}+2{y}^{2}x-y,x\right)$
 ${\left({1}{-}{y}\right)}^{{3}}{}{\left({x}{+}\frac{{{y}}^{{2}}}{{\left({1}{-}{y}\right)}^{{3}}}\right)}^{{2}}{-}{y}{-}\frac{{{y}}^{{4}}}{{\left({1}{-}{y}\right)}^{{3}}}$ (2)
 > $\mathrm{CompleteSquare}\left(\frac{1}{{\mathrm{sin}\left(t\right)}^{2}+2\mathrm{sin}\left(t\right)+1},\mathrm{sin}\left(t\right)\right)$
 $\frac{{1}}{{\left({\mathrm{sin}}{}\left({t}\right){+}{1}\right)}^{{2}}}$ (3)
 > $\mathrm{CompleteSquare}\left({a}^{2}+{b}^{2}+a+b,a,b\right)$
 ${\left({b}{+}\frac{{1}}{{2}}\right)}^{{2}}{+}{\left({a}{+}\frac{{1}}{{2}}\right)}^{{2}}{-}\frac{{1}}{{2}}$ (4)
 > $\mathrm{CompleteSquare}\left({x}^{2}-x={y}^{2}+2y+3\right)$
 ${\left({x}{-}\frac{{1}}{{2}}\right)}^{{2}}{-}\frac{{1}}{{4}}{=}{\left({y}{+}{1}\right)}^{{2}}{+}{2}$ (5)
 > $\mathrm{CompleteSquare}\left(\mathrm{Int}\left(\mathrm{Int}\left(\frac{{u}^{2}+2u}{{v}^{2}-3v},v\right),u\right),\left[u,v\right]\right)$
 ${?}$ (6)