Excuse the non-mathematical way I've phrased the question.
I have the following problem:
I have $N$ square paper documents with side lengths between $150$mm and $860$mm. I know each document side's length.
I need to create $3-4$ differently sized boxes to fit all the documents, e.g. Three box types: Box $1$ side $l_1=300$mm, Box $2$ side $l_2=600$mm, Box $3$: $l_3=860$mm.
There are as many boxes as documents, i.e. each document goes into its own separate box (of the smallest possible size so as to minimize waste of cardboard).
What is the best way to decide on the size of the boxes, so as to minimize the total amount of (surface area) of cardboard used?
I'm not necessarily looking for the analytical solution to this problem. Two ideas I've had:
a) Pick $l_1$ and $l_2$ values at random and calculate the total surface area of cardboard. Guess the values again, see if the total surface area is smaller, and so on and on.
b) A more analytical approach where I'm computing $l_1$ and $l_2$ value in say $1$mm increments and I calculate the total surface area for each combination of box lengths between say ($150$mm, $151$nmm,$860$mm) and ($858$mm,$859$mm,$860$mm).
What would you suggest is the most practical way of going about solving this?
BTW, I'm great with Excel, less so with Mathlab, etc. I can program well in Ruby if that helps in any way.