Consider the function defined by y = x^(sin(x)^sin(x)). Observe its graph. Find an increasing function which passes through each of its local maximums, and another increasing function which passes through each of its local minimums.

Extra credit: You’ll notice the graph isn’t drawn for x-values which make sin(x) negative. This is because most of those values make the function undefined - though it is defined for infinitely many points in those intervals, it just also has infinitely many holes. Since it lacks continuity here, it has no true local maxes or local mins, and doesn’t impact the original problem. We can nonetheless cheat and fill in the holes by expanding the function to these regions with y = x^|sin(x)|^sin(x) (Using x^-|sin(x)|^sin(x) should also be technically valid, but is being ignored because it’s discontinuous with the rest of the graph and not as pretty, but will be mentioned in my solution). Doing so adds more local maxes and local mins. The new local mins should line up with your function that finds the local maxes for the original function - but, find a new function which hits all of the new local maxes.

  • PhobosAnomaly
    link
    fedilink
    5
    edit-2
    7 months ago

    Alright so, I did first-year university level maths so I know enough to be dangerous, but not enough to follow anything exciting.

    Where is sin(x) undefined? That’s a concept I’m not aware of, and I love myself a function with random quirks - so would love to be pointed in a direction to learn more…

    …and more importantly, can you add additional function intervals within the current gaps to draw a single curve in that new interval, so as to output an almighty upwards-trending UwUwUwUwUwU…?

    • zkfcfbzrOP
      link
      English
      37 months ago

      sin(x) is defined everywhere - it’s sin(x)^sin(x) that has undefined spots: A negative number can only be raised to a negative power if that negative power can be expressed as a rational number with an odd denominator. That doesn’t describe most real numbers, so sin(x)^sin(x) is undefined for most values that make sin(x) negative. It does still describe infinitely many values, though - and the extra credit graph kinda just connects them up.

      • PhobosAnomaly
        link
        fedilink
        37 months ago

        Man that’s really cool, I love that sort of thing - thank you for pointing out my oversight.

        It’s times like this that I wish I’d carried a math pathway forward… and then I look back and think “maybe I should have learned to stay in my lane when integration-by-parts became a thing” 😂

        Thanks though, friend!

        • zkfcfbzrOP
          link
          English
          1
          edit-2
          7 months ago

          No worries! The idea isn’t too bad - it all comes down to that you can’t take the square root of a negative number, but that you can take the cube root of a negative - or in general, you can’t take even roots of negatives, but you can take odd roots of negatives. Remember that if your exponent is a/b, it’s like taking a power of a, and a root of b. So something like (-25)^(1/2) is asking for the square root of -25, which isn’t defined (since we’re not considering complex numbers in this problem). On the other hand, something like (-125)^(1/3) is perfectly fine: It’s just -5, since -5 * -5 * -5 = -125. That’s why negative numbers to exponents which can be written as a rational number with an odd denominator are defined, regardless of the sign of the exponent. If a is negative and a^b is defined, then |a^b| will always equal |a|^b - like how |(-125)^(1/3)| = |-125|^(1/3) = 125^(1/3) = 5

          When you write that rational exponent, its numerator will be even or odd, too. If the exponent is even, then the answer will end up positive: Negative numbers have negative odd roots, and negative numbers to even powers are positive. On the other hand, if the exponent is odd, the answer will end up negative: Negative numbers to odd powers are still negative. So if your expression is x^x and is defined, and x is negative, you know it’s going to equal either |x|^x or -|x|^x. Here’s an example of each case:

          (-1/3)^(-1/3) = -1.4422495 = -(1/3)^(-1/3) (a case for x^x = -|x|^x)

          (-2/3)^(-2/3) = 1.31037 = (2/3)^(-2/3) (a case for x^x = |x|^x)

          And that’s why the two extension functions I mention wrap the first sin(x) in parenthesis, and swap its sign around. The actual y = x^(sin(x)^sin(x)) has infinitely many points that lie on both of those functions (within the intervals where sin(x) is negative - so within the intervals where desmos seemingly graphs nothing) already - desmos just isn’t graphing them, and these new functions are filling in the gaps so everything gets drawn. The gaps happen for irrational numbers and for any rational number with an even denominator - but if you actually put a point at every defined value, you would get a graph that looks like this (only taking principle real roots). If you allowed graphing both real roots when available, you’d get this. If you wanted to go to negative x-values too you’d get this.

          All the points you see on that final graph correspond to (x, y) values that do satisfy just the original equation, y = x^sin(x)^sin(x) - them not displaying in the original graph is a combination of desmos not graphing individual discontinuous points, and desmos only graphing primary roots in equations set up as functions. So it’s a case where those points exist on the graph, but lack any continuity: It’s just infinitely many non-connected points, that are nonetheless dense enough that you could zoom in forever and still always see infinitely many defined points in any given region. The key is that between any two real numbers, there are always infinitely many rational numbers, infinitely many of which can be written with odd denominators - so there are points everywhere, just not everywhere enough.

    • zkfcfbzrOP
      link
      English
      2
      edit-2
      7 months ago

      I’ve posted my solution.

      The question of why the bounds swap isn’t too relevant to the problem, since there are no maxes or mins below x = 1 - but the reason they swap is because numbers between 0 and 1 get larger with smaller powers, and smaller with larger powers. Think of how 0.5^2 = 0.25 - so the more a (positive) power is biased toward “rooting” a number in this interval (biased toward 0), the larger the result will be - so the minimum of g now produces a max value, and the max of g yields a minimum value.

      Edit: If it helps, you can also think of numbers between 0 and 1 as being numbers larger than 1, but with a negative power. So something like 0.5^2 is equivalent to (2^-1)^2 = 2^-2. So larger powers become lesser powers that way.

      Really, it’s for the same reason the graphs of 2^x and 0.5^x are reflections of each other

  • zkfcfbzrOP
    link
    English
    27 months ago
    Background / incredibly minor spoilers:

    Unlike the other problems I’ve posted, this is the only one (so far) that I came up with on my own - back in high school while playing around with my calculator I entered this function at some point, and got curious about the minimums. I was in pre-calculus at the time, so it took me a while - but I did eventually work out the solution. Needless to say I was pretty happy the answer was something as cool as it was. I actually didn’t ever work out (or try to work out) the extra credit portion until I wrote up the problem for this post, so it was a nice revisit of a very old problem.

    The language asking for an “increasing” function is mostly to avoid smartasses who might submit the original equation as a technically correct solution. Basically I want the simplest possible function that passes through the described points.

  • zkfcfbzrOP
    link
    English
    2
    edit-2
    7 months ago
    Solution

    For both of these, it’s sufficient to consider only sin(x)^sin(x). It stands to reason that the maximums will happen when sin(x)^sin(x) is at its maximum value, and its minimums will happen when sin(x)^sin(x) is at its minimum value. The x^ part really just makes the function prettier to look at. The function lacks any continuity when sin(x) is negative, so we can consider just the regions where sin(x) is positive.

    For the maximums, this is very easy: The largest sin(x) can be is 1, and so the largest value for sin(x)^sin(x) is also 1. So the monotonically increasing function which passes through each local maximum is y = x^1, or just y = x.

    For the minimums it’s a bit trickier: The smallest sin(x) can be is 0, and while 0^0 is indeterminate, it happens to approach 1 in this case - our minimum is somewhere else (side note: sin(x)^sin(x) approaching 1 for these values is why our max function also exactly bounds the flailing arms of the function). So we turn to derivatives. We can do this using either sin(x)^sin(x) or x^x - I chose to use sin(x)^sin(x) here and x^x (sort of) in the extra credit. Using sin(x)^sin(x) here has the added benefit of also showing the maximums are when sin(x) = 1.

    y = sin(x)^sin(x)

    y = e^(ln(sin(x)) * sin(x))

    y’ = sin(x)^sin(x) * (cos(x)/sin(x) * sin(x) + ln(sin(x)) * cos(x)) → Chain rule, product rule, and chain rule again

    y’ = sin(x)^sin(x) * (cos(x) + ln(sin(x)) * cos(x)) → Simplify

    y’ = sin(x)^sin(x) * cos(x) * (1 + ln(sin(x))) → Factor

    We can set each of these factors to 0.

    sin(x)^sin(x) will never be 0.

    cos(x) will be 0 when x = π/2 + 2πn (2πn instead of πn because we’re skipping over the solutions where sin(x) is negative). These are the maximums, because when x = π/2 + 2πn we have sin(x) = 1.

    1 + ln(sin(x)) = 0

    ln(sin(x)) = -1

    sin(x) = e^-1 = 1/e

    And that’s actually sufficient for our purposes - we could of course say x = arcsin(1/e), but our goal is to calcualte the value of sin(x)^sin(x). Since sin(x) = 1/e, we have sin(x)^sin(x) = (1/e)^(1/e). So our monotonically increasing function which hits all the minimums is y = x^((1/e)^(1/e)), or: y = (e-th root of e)-th root of x.

    Graphed solution visible here.

    For the extra credit, we can do the same basic idea: Find the maximum of |sin(x)|^sin(x). Since we know we’re in a region where sin(x) is negative, we can model this as x^-x, and the solution will be valid as long as x is something between 0 and 1, within sin(x)'s positive range.

    y = x^-x = e^(ln(x) * -x)

    y’ = x^-x * (-1 - ln(x))

    x^-x won’t ever be 0, and -1 - ln(x) will be 0 when ln(x) = -1, or x = 1/e again, same as before. So our maximum value happens at (1/e)^(-1/e), which simplifies to e^(1/e). In other words, our new maximum function is x^(e^(1/e)), or x to the power of the e-th root of e. Graph of all three solution functions

    And, finally - I mentioned that we should also be able to expand the function to its less-defined regions using y = x^-|sin(x)|^sin(x). I don’t care enough to post the full work here, but the reciprocal of the three answer solutions above are what works here: y = 1/x, y = 1/x^((1/e)^(1/e)), and y = 1/x^(e^(1/e)). Graph. Note that the upper function here only applies in regions where the original function is already defined, and so the other parts of this extension are invalid - you can toggle the main function at the top off to see only the parts that truly apply.

    Nothing particularly interesting happens if you extend things to values of x less than 0 - the graphs (more or less) just reflect across the y-axis.

    Bonus graph with everything + phase shifts and pretty colors