## A math problem (maximization with restraints)

For the discussion of math. Duh.

Moderators: gmalivuk, Moderators General, Prelates

SirGabriel
Posts: 42
Joined: Wed Jul 16, 2014 11:54 pm UTC

### A math problem (maximization with restraints)

It's been a while since I've taken calculus, so I don't remember how to optimize three-variable problems. Can anyone help?

Maximize (x*y*z) given:
100 ≥ x ≥ y ≥ z ≥ 0
200 ≥ x + pi*sqrt(y^2 + z^2)

(In case anyone's wondering, I'm trying to figure out what shape of box I should use to maximize the amount of stuff I can ship home in one box given the size restrictions for what Austria post will ship internationally.)
Last edited by gmalivuk on Thu Mar 31, 2016 12:24 pm UTC, edited 1 time in total.
Reason: added a description to the topic title

Sabrar
Posts: 43
Joined: Tue Nov 03, 2015 6:29 pm UTC

### Re: A math problem

If you take x as fixed you could optimize it for two variables first as a function of x:
max(y*z) such that [(200-x)/pi]2 ≥(y^2 + z^2)
I think this has a nice symmetric solution.
Then you maximize it separately for x alone.

Spoiler:
I get x=200/3 and y=z~30 as the solution.

ThirdParty
Posts: 351
Joined: Wed Sep 19, 2012 3:53 pm UTC
Location: USA

### Re: A math problem (maximization with restraints)

I agree. x = 200/3, y = z = (200/3)(√2/π).

Here's my reasoning:
Spoiler:
Just by eyeballing it, we can see that the optimum solution will have y and z equal. (Because we want y*z to be high but y^2+z^2 to be low.)

Substituting y for z gives us:
100 ≥ x ≥ y ≥ 0
200 ≥ x + (π√2)y

Since we want x and y to be as high as possible, replace the latter inequality with an equality and solve for x:

x = 200 - (π√2)y

Substitute that into the maximand, to get:

maximize: 200y2 - (π√2)y3

Take the first derivative and set it to zero to find an inflection point:

400y - (3π√2)y2 = 0

Solve for y to get:

y = (200√2)/(3π)

In which case x = 200/3.