Since I am a student of Mathematics I enjoy to apply MMA to problems that I have a solid understanding in. The following would be such a problem:
Maximize $f: \mathbb{R}^3 \to \mathbb{R}$ given by $f(x,y,z):= 8xyz$ constrained to the ellipsoid $$ E:= \left\lbrace (x,y,z) \in \mathbb{R}^3: \frac{x^2}{a^2}+ \frac{y^2}{b^2}+ \frac{z^2}{c^2}=1 \right\rbrace $$ where $a,b,c>0$
Under the realistic assumptions that $x,y,z >0$ are all positive (because else wise the cuboid vanishes) this is an easy application by hand on paper with a little help from multivariate Calculus, namely the Lagrange multipliers.
After sume juggling with the gradients one obtains the solutions of the maximum $$x_0= \frac{a}{\sqrt{3}}, \ y_0 = \frac{b}{\sqrt{3}}, \ z_0 = \frac{c}{\sqrt{3}} \implies V_\max=f(x_0,y_0,z_0)= \frac{8abc}{3\sqrt{3}} $$
In Mathematica however I struggle to implement this problem:
f[x_,y_,z_]:= 8 x y z (* a naive R^3 -> R function *)
Then indeed I use the Maximize
function with the appropriate constraints:
Maximize[{f[x,y,z], (x/a)^2+(y/b)^2+(z/c)^2 ==1 && a> 0 && b >0 && c>0}, {x,y,z}]
MMA manages to find the same Maximal volume as I did by hand, but for the variables $x,y,z$ it finds very peculiar results:
While the volume is correct, I wonder how I get the more realistic $x,y,z$ results as I did by hand.
Addendum: More realistically I would have rather defined a function as
g[x_ /; x>0, y_ /; y>0, z_ /; z>0]:= 8 x y z
But in this case Maximize won't even execute
FullSimplify[%, a > 0 && b > 0 && c > 0]
, where%
is your initial result. $\endgroup$