Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

What is the least value of function:

$$y= (x-2) (x-4)^2 (x-6) + 6$$

For real values of $x$ ?

Does $\frac{dy}{dx} = 0$, give the value of $x$ which will give least value of $y$?

Thanks in advance.

share|cite|improve this question
$y'(x) = 0$ may give $3$ values of $x: x_1,x_2,x_3$; you choose among them the one such that $y(x_i)$ is minimal. Don't forget to show that $y(x)$ and $y(-x)$ is large for large $x$, so the least value is not attained at $\infty$ or $-\infty$ – Ilya Mar 2 '12 at 11:13
Note that the function is obviously symmetric around $x=4$ and will have a local maximum there (quick sketch) - so (given degree 4) you expect two answers symmetrically placed. This motivates the substitutions in Martin Sleziak's answer, and also gives a check on computation. The value of $y (=6)$ at $x=2,4,6$ shows solutions will be strictly between 2 and 4, and 4 and 6. – Mark Bennet Mar 2 '12 at 13:42
Your title should say "What is the least value of the function?". The word "equation" is another one of those words that get incorrectly used as a catch-all. – Michael Hardy Mar 2 '12 at 17:34
up vote 4 down vote accepted

An alternative solution using AM-GM inequality instead of derivatives.

If you use substitution $t=x-4$, then you want to minimize $t^2(t-2)(t+2)+6$, which is equivalent to minimizing $$g(t)=t^2(t-2)(t+2)=t^2(t^2-4).$$

Obviously $g(t)\ge 0$ whenever $t^2\ge 4$. We can use another substitution $s=t^2$ and ask for minimum of $s(s-4)$ for $s\in\langle 0,4 \rangle$. If we change the sign, this is the same thing as looking for the maximum of $$h(s)=s(4-s)$$ for $s\in\langle 0,4 \rangle$.

Now we can use AM-GM inequality to see that $$h(s)=s(4-s) \le \left(\frac{s+(4-s)}2\right)^2 = 2^2=4,$$ where the equality is attained only for $s=4-s$, i.e. $s=2$.

This leads to $t=\pm\sqrt2$ and $x=4\pm\sqrt2$. The minimal value is 2. (Obtained as $6-4=2$, since $4$ is the maximal possible value of $h(s)$.)

You can check this at wolframalpha: minimize (x-2) * (x-4)^2 * (x-6) + 6.

share|cite|improve this answer
Completing the square works too: the minimum of $s(s-4) = (s-2)^2-4$ is clearly $-4$ when $s=2$. – Henry Mar 2 '12 at 15:49

$$\frac{dy}{dx} = (x-4)^2 (x-6)+(x-4)^2 (x-2)+2(x-2)(x-4)(x-6) = 0 $$

$$ \Rightarrow (x-4) \left[ (x-4)(2x-8)+2(x-2)(x-6) \right] = 0$$

$$ \Rightarrow (x-4) \left[ 2x^2-16x+32+2x^2-16x+24 \right] = 0$$

$$ \Rightarrow (x-4) \left[ 4x^2-32x+56 \right] = 0$$

$$ \Rightarrow 4(x-4) \left[ (x-4+\sqrt{2})(x-4-\sqrt{2}) \right] = 0$$

There is a maxima or minima at $x=4, \hspace{5pt}x=(4-\sqrt{2}),\hspace{5pt} x=(4+\sqrt{2})$

If you take the second derivative and find where the second derivative is positive, that is where the function value has a minima.

Second derivative is $$8(x-4)^2+4(x-4+\sqrt{2})(x-4-\sqrt{2})$$

And at $x=4\pm\sqrt{2}$ for instance the second derivative is positive and therefore at it is minimum at those points.

share|cite|improve this answer
You need to phrase that a bit more carefully, since a slope of zero does not imply the existence of a maximum or minimum: consider $y=x^3$ at $x=0$. – Brian M. Scott Mar 2 '12 at 11:42
It's $56$, not $58$. And accordingly, the answers are $x=4$, $x=4-\sqrt 2$ and $x=4+\sqrt 2$ – Gigili Mar 2 '12 at 11:53
$32+24=56$ not 58. I think you should get $4\pm\sqrt{2}$ as the points where the derivative is equal to zero instead of $4\pm\frac{\sqrt6}2$. – Martin Sleziak Mar 2 '12 at 11:54
Okay, I was about to upvote your answer but you really need to edit it. $6$ is the maximum value, not the minimum. – Gigili Mar 2 '12 at 12:23
Thanks for all nice comments – Kirthi Raman Mar 2 '12 at 12:45

Since you are asked to find the least value of $$\tag{1} f(x)=(x-2)(x-4)^2(x-6)+6 $$ over the reals, you are looking for the global minimum value, if there is one.

Your function is continuous, so the following general procedure is applicable:

Given a continuous function $g$ defined on a nondegenerate interval $I$, to determine if $g$ has a global minimum value on $I$ and to find its value when it exists:

  1. Examine the "endpoint behaviour" of $g$. For example:

    • If $I=[a,b]$, evaluate $g(a)$ and $g(b)$.

    • If $I=(a,b)$, calculate $\lim\limits_{x\rightarrow a^+} g(x)$ and $\lim\limits_{x\rightarrow b^-} g(x)$.

    • If $I= \Bbb R$, calculate $\lim\limits_{x\rightarrow\infty} g(x)$ and $\lim\limits_{x\rightarrow-\infty} g(x)$.

    There are other cases to consider, but I hope that it's obvious what to do in those cases.

    The quantities found here will be used later, so keep them in mind.

  2. Find all critical points of $g$ in the interval $I$. These are points $x\in I$ where $g'(x)=0$ or where $g'(x)$ does not exist. These points and any endpoints of $I$ contained in $I$ are the only points at which a global minimum value can occur.
  3. Evaluate the function $g$ at each point found in step 2..
  4. Use the information found in steps 1. and 3. to determine if $g$ has a global minimum value and what that value is when it exists. That, is compare the values found in steps 1. and 3.. There are several cases to consider depending on the form of $I$. For example:

    • If $I=[a,b]$, then $g$ will have a global minimum value. The global minimum will be the smallest of the quantities found in steps 1. and 3..

    • If $I=(a,b)$, then $g$ will have a global minimum value if and only if the smallest value found in step 3. is less than or equal to both of the limit values found in step 1.. In this case, the global minimum value of $g$ is the smallest value found in step 3.. Note here that since $I$ does not include its endpoints, the endpoints of $I$ are not candidates for places where the global minimum of $g$, if it exists, can occur.

    • If $I=\Bbb R$, then $g$ will have a global minimum value if and only if the smallest value found in step 3. is less than or equal to both of limit values found in step 1.. In this case, the global minimum value of $g$ is the smallest value found in step 3..

Back to our problem:

In our case, the implied domain of $f$ is all of $\Bbb R$.

Step 1:

Note that the function $f$ is a polynomial of degree 4 with positive leading coefficient. This implies that $$\lim\limits_{x\rightarrow\infty}f(x)=\infty\quad\text{and}\quad \lim\limits_{x\rightarrow-\infty}f(x)=\infty.$$
Looking ahead a bit, we can conclude that $f$ does have a global minimum value and that value will be the smallest value found in step 3..

Step 2:

We first find $$\tag{2}\eqalign{ f'(x)&=(x-4)^2(x-6)+2(x-2)(x-4)(x-6)+(x-2) (x-4)^2\cr &=4(x-4)(x^2-8x+14 ). }$$ The derivative $f'$ exists everywhere. We are left with the task of solving the equation $f'(x)=0$. This is easy to do looking at $(2)$ and using the quadratic formula: $f'(x)=0$ if and only if $$ x=4,\quad x={8\pm\sqrt{64-56}\over 2}=4\pm\sqrt2. $$

Step 3:

We evaluate $f$ at each of the three points found above: $$\tag{3} \eqalign{ f(4)&= 6\cr f(4+\sqrt2)&=(2+\sqrt2)\cdot2\cdot( -2+\sqrt2)+6=2\cr f(4-\sqrt2)&=(2-\sqrt2)\cdot2\cdot(-2-\sqrt2)+6=2.\cr } $$

Step 4:

From step 1., $f(x)$ tends to infinity as $x\rightarrow\infty$ or as $x\rightarrow-\infty$. This means that $f$ does have a global minimum value and that that value must be the smallest value found in step 3..

So, from $(3)$, we see that the minumum value of $f$ is $2$. This minimum value is achieved at two places: $x=4+\sqrt2$ and at $x=4-\sqrt 2$.

share|cite|improve this answer

Note that $(x-2)(x-6)=x^2-8x+12$ and $(x-4)^2=x^2-8x+16$. This suggests the symmetrizing substitution $w=x^2-8x+14$. Thus $$y=(w-2)(w+2)+6=w^2+2.$$ We want to minimize the absolute value of $w$. But $w=(x-4)^2-2$. So $w$ has minimum absolute value $0$, reached when $(x-4)^2=2$, that is, when $x=4\pm\sqrt{2}$. The minimum value of $y$ is $2$.

Remark: The curve $y=(x-2)(x-4)^2(x-6)+6$ is very special, with a beautiful double symmetry. It seems likely that the method used above was the intended one. The same idea works for $(x-a)(x-b)(x-c)(x-d)+k$, where $a+d=b+c$.

share|cite|improve this answer

$$y= (x-2) (x-4)^2 (x-6) + 6$$

$let , t = x-4$

$$y= t^2(t-2)(t+2)+ 6$$

$$y= t^4-4t^2+6 $$



attained when $t^2=2$
which gives,
$ x=4-\sqrt2$ and $ x=4+\sqrt2$

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.