Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Maximum/minimum through logarithm

  1. Nov 26, 2014 #1
    Hi I seem to have run into a strange problem.
    Suppose one wishes to maximize/minimize the function ## f(x) = (x-4)^{2} ##. Clearly, this function has a minimum at x = 4. One could find the extremum by taking the derivative and setting to zero.

    One could also compute the logarithm of this function, i.e. ## ln (x-4)^{2} = 2 \ ln(x-4) ##, and then find the corresponding extremum of the resulting function, and since ## ln(x )## is monotonic over the region on which it is defined, the maximum/minimum of ##f(x)## and the maximum/minimum of ## f(ln(x))## should coincide.

    This however is not the case, since ## 2 \ ln(x-4) ## seems not to have a maximum or a minimum. What am I missing here?


  2. jcsd
  3. Nov 26, 2014 #2
    I hope I understand your point ...

    Actually the two function would have the same critical point
    when you equate by zero your critical point is 4.

    Again your critical point is 4.

    is that what you mean?

    Am I right ..
  4. Nov 26, 2014 #3


    User Avatar
    Homework Helper

    Your problem is that [itex]\ln x[/itex] is not defined for [itex]x \leq 0[/itex]. Thus the critical point of [itex](x - 4)^2[/itex] is not in the domain of [itex]\ln(x - 4)[/itex].
  5. Nov 26, 2014 #4


    User Avatar
    Science Advisor
    Homework Helper
    Gold Member


    ## ln (x-4)^{2} = 2 \ ln|x-4| \ \ (x \ne 4)##
  6. Dec 1, 2014 #5


    User Avatar
    Science Advisor

    Personally, I wouldn't use "logarithms" or "derivatives". A [tex]x^2[/tex] is never negative and is 0 only for x= 0, so that [tex](x- 4)^2[/tex] is never negative and is 0 only for [tex]x- 4= 0[/tex] or [tex]x= 4[/tex].
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook