## Sunday, June 28, 2015

### Optimization Contest Problem: Find the maximum of f(x): First Solution

Find the maximum of $f(x) = \dfrac{x^4-x^2}{x^6+2x^3-1}$ where $x>1$.

This is an excellent problem that could help in effective questioning so to get students fully understand some particular mathematics concepts and how to resolve optimization problem beautifully yet effectively.

But one may be tempted to solve it using the calculus method, as that is what teachers taught them what to do whenever we are to ask to find the maximum of a function, yes, calculus method works wonder and I will let you to decide, after showing you ways of approaching this problem so that you know how much this problem means as the best quality problem that enable us to activate and connect various areas in our brain and therefore think creatively.

We differentiate the rational function using the quotient rule and we get:

$f(x) = \dfrac{x^4-x^2}{x^6+2x^3-1}$

\begin{align*}f'(x) &= \dfrac{(x^6+2x^3-1)(4x^3-2x)-(x^4-x^2)(6x^5-6x^2)}{(x^6+6x^2)^2}\\&= \dfrac{2 x (-x^8+2 x^6+x^5+x^3-2 x^2+1)}{(x^6+6x^2)^2}\\&=-\dfrac{2 x (x^8-2 x^6-x^5-x^3+2 x^2-1)}{(x^6+2 x^3-1)^2}\end{align*}

Wow, the expression of the second factor in the numerator ($x^8-2 x^6-x^5-x^3+2 x^2-1$) seems so hard to factorize completely. But, if we want to stick to and rely on this method, we cannot skip this step as we have to look for the $x$-coordinate of the maximum point so we could calculate the maximum value.

We need to examine the expression of the numerator (second factor) more closely, and it depends on students' sensitivity and observation to factorize a seemingly impossible to factor expression, but deep down, we know it is doable:

\begin{align*}x^8-2 x^6-x^5-x^3+2 x^2-1&=x^8-2 x^6-x^3(x^2+1)+2 x^2-1\\&=(x^2)^4-2 (x^2)^3-x^3(x^2+1)+2 x^2-1\\&=(-1)^4-2 (-1)^3-x^3(-1+1)+2(-1)-1\\&=1+2+0-2-1 \\&=0\end{align*}

This is true only if $x^2+1=0$, in other words, $x^2=-1$.

Great, when we have discovered that, we need to perform the long division to factorize the expression of the numerator.

[MATH]\begin{array}{r}x^6-3x^4-x^3+3x^2-1\hspace{160px}\\x^2+1\enclose{longdiv}{x^8+0x^7-2x^6-x^5+0x^4-x^3+2x^2+0x-1} \\ -\underline{\left(x^8+0x^7+x^6\right)} \hspace{225px} \\ -3x^6-x^5+0x^4 \hspace{155px} \\ -\underline{\left(-3x^6+0x^5-3x^4\right)} \hspace{140px} \\ -x^5+3x^4-x^3 \hspace{120px} \\ -\underline{\left(-x^5+0x^4-x^3\right)} \hspace{110px} \\ 3x^4+0x^3+2x^2 \hspace{70px} \\ -\underline{\left(3x^4+0x^3+3x^2\right)} \hspace{60px} \\ -x^2+0x-1 \hspace{10px} \\ -\underline{\left(-x^2+0x-1\right)} \hspace{0px} \\ 0 \hspace{10px} \end{array}[/MATH]

Therefore, we get:

$x^8-2 x^6-x^5-x^3+2 x^2-1=(x^2+1)(x^6-3x^4-x^3+3x^2-1)$

We are not done yet, since we have yet found the real $x$ coordinate of the maximum point, and the factor $x^2+1$ gives us the complex $x$ value.

There are plenty of ways to factor the second factor in $(x^2+1)(x^6-3x^4-x^3+3x^2-1)$, so math educators can make optimal use of this problem to open students' eyes to the different approaches one can make to factorize an interesting expression.

In this blog post, I will focus on teaching one very smart and intelligent way to factorize $x^6-3x^4-x^3+3x^2-1$, provided you have some prior knowledge about the following two identities:

1.

[MATH]\color{yellow}\bbox[5px,purple]{a^3-3a^2+3a-1=(a-1)^3}[/MATH]

Note that we can replace $a$ by anything else, if we have it replaced by $x^2$, we end up with:

[MATH]\color{yellow}\bbox[5px,purple]{(x^2)^3-3(x^2)^2+3(x^2)-1=x^6-3x^4+3x^2-1=(x^2-1)^3}[/MATH]

2.

[MATH]\color{yellow}\bbox[5px,green]{a^3-b^3=(a-b)(a^2+ab+b^2)}[/MATH]

Also, both $a$ and $b$ can be replaced by absolutely anything else, take for example, if we have [MATH]\color{black}\bbox[5px,orange]{x^2-1}[/MATH] be $a$ and [MATH]\color{black}\bbox[5px,yellow]{x}[/MATH] as $b$, we see that:

[MATH]\color{yellow}\bbox[5px,green]{\begin{align*}a^3-b^3&=\color{black}\bbox[5px,orange]{(x^2-1)^3}\color{yellow}-\color{black}\bbox[5px,yellow]{(x)^3}\\&=\color{yellow}(\color{black}\bbox[5px,orange]{x^2-1}\color{yellow}-\color{black}\bbox[5px,yellow]{x}\color{yellow})\color{yellow}(\color{black}\bbox[5px,orange]{(x^2-1)^2}\color{yellow}+\color{black}\bbox[5px,orange]{(x^2-1)}\color{black}\bbox[5px,yellow]{(x)}\color{yellow}+\color{black}\bbox[5px,yellow]{(x)^2}\color{yellow})\\&=(x^2-x-1)(x^4-2x^2+1+x^3-x+x^2)\\&=(x^2-x-1)(x^4+x^3-x^2-x+1)\\&=(a-b)(a^2+ab+b^2)\end{align*}}[/MATH]

These are two key concepts that help us enormously to do the following factoring:

\begin{align*}x^6-3x^4-x^3+3x^2-1&=x^6-3x^4+3x^2-1-x^3\\&=(x^6-3x^4+3x^2-1)-x^3\\&=((x^2)^3-3(x^2)^2+3x^2-1)-x^3\\&=(x^2-1)^3-x^3\\&=(x^2-1-x)((x^2-1)^2+(x^2-1)(x)+(x^2)^2)\\&=(x^2-x-1)(x^4+x^3-x^2-x+1)\end{align*}

Okay, up to this point, let's see what we have gotten:

\begin{align*}f'(x) &= \dfrac{(x^6+2x^3-1)(4x^3-2x)-(x^4-x^2)(6x^5-6x^2)}{(x^6+6x^2)^2}\\&= \dfrac{2 x (-x^8+2 x^6+x^5+x^3-2 x^2+1)}{(x^6+6x^2)^2}\\&=-\dfrac{2 x (x^8-2 x^6-x^5-x^3+2 x^2-1)}{(x^6+2 x^3-1)^2}\\&=-\dfrac{2 x (x^2+1)(x^6-3x^4-x^3+3x^2-1)}{(x^6+2 x^3-1)^2}\\&=-\dfrac{2 x (x^2+1)(x^2-x-1)(x^4+x^3-x^2-x+1)}{(x^6+2 x^3-1)^2}\end{align*}

Our purpose is to find the maximum point, that is to first look for the $x$ coordinate of the maximum point at $x\gt 1$.

We now can set $f'(x)=0$ to locate the maximum point.

Since $f'(x)=-\dfrac{2 x (x^2+1)(x^2-x-1)(x^4+x^3-x^2-x+1)}{(x^6+2 x^3-1)^2}$, it equals zero iff

$2 x (x^2+1)(x^2-x-1)(x^4+x^3-x^2-x+1)=0$, and $x^6+2 x^3-1\ne 0$

This gives a few points, but we must bear in mind that we're already told the domain for the problem has been set to $x\gt 1$:

$2 x (x^2+1)(x^2-x-1)(x^4+x^3-x^2-x+1)=0$ yields

$x=0$,

$x^2-x-1=0$, and $x^4+x^3-x^2-x+1=0$.

We can cross out $x=0$ since it lies outside of the domain set by the question.

Whereas $x^2-x-1=0$ gives $x=\dfrac{1+\sqrt{5}}{2}$.

Ah! We have one more thing to do, we have to check if $x^4+x^3-x^2-x+1=0$ is possible, if it is possible, then we have to look for the critical points that it bears so we could determine the real maximum point in the domain $x\gt 1$.

That means we have extra work to do here..that it required much thought and effort and this is not at all a shortcut solution to this problem.

I will post in the next blog post how to prove that $x^4+x^3-x^2-x+1\gt 0$ for all $x$ because I don't make to make this blog post so lengthy.

We are not done yet, we have to ascertain that $x=\dfrac{1+\sqrt{5}}{2}\approx 1.618$ yields a maximum, and not a minimum.

We have two options here, the first derivative test or second derivative test.

Judging by the so complicated rational function of the first derivative, we opt out the second derivative test and stick to the first derivative test:

$x=1.5$ gives $f'(1.5)\approx \dfrac{13.84}{\text{always positive}}\gt 0$

$x=\dfrac{1+\sqrt{5}}{2}$ gives $f'\left(\dfrac{1+\sqrt{5}}{2}\right)= 0$

$x=2$ gives $f'(2)= -\dfrac{495}{\text{always positive}}\lt 0$

Therefore, $f(x) = \dfrac{x^4-x^2}{x^6+2x^3-1}$ has its maximum point at $x=\dfrac{1+\sqrt{5}}{2}$ and the maximum value is hence

\begin{align*}f(x)_{\text{maximum}} &= \dfrac{x^4-x^2}{x^6+2x^3-1}\\&=\dfrac{\left(\dfrac{1+\sqrt{5}}{2}\right)^4-\left(\dfrac{1+\sqrt{5}}{2}\right)^2}{\left(\dfrac{1+\sqrt{5}}{2}\right)^6+2\left(\dfrac{1+\sqrt{5}}{2}\right)^3-1}\\&=\dfrac{2+\sqrt{5}}{6(2+\sqrt{5})}\\&=\dfrac{1}{6}\end{align*}