Let $a > 0$ be some $\mathbb{R}$ . Find the global maximum and the global minimum of the function: $f(x) = x^3 - x^2 $ on the interval $[-a,a]$.
Is it valid to just define a set of all possible y values: $ Y := $ {$ x \in [-a,a]: f(x$} and then create a set of a single global x value in the following: global maximum := {$ !\exists x \in [-a,a], \forall y \in Y: f(x) \geq y$} and the same for the global minimum := {$ !\exists x \in [-a,a], \forall y \in Y: f(x) \leq y$}?
Would this be a mathematically correct answer? If yes, is there a more elegant way? Thank you very much.
It is mathematically correct. It is useless. You are given an explicit $f$; you should be able to do vastly better than just recite the definition of global minimum and global maximum. For instance, with this $f$, the global minimum on $[-a,a]$ for $a \geq 0$ is $-a^3 - a^2$. The global maximum is a piecewise function with two pieces.