#### Box Folding Optimization

A piece of cardboard with a total area of 0.8m^{2} is to be made into an open-top box by first removing the corners and then by folding the box sides up and securing the tabs to the adjacent box side. The starting cardboard sheet has height *h* and width *w*. When cut and folded, the box has a width of *w-2x*, a length of *h-2x*, and a height of *x*. In order to properly secure the tabs to the adjacent box side, the width of the tab must be 5 centimeters (0.05m). The objective is to maximize the volume of the box by choosing an appropriate value of *x* (the height of the box) and *w* (the starting width of the cardboard sheet).

#### Download Sample Python Code

Python source code solves the box optimization problem with Newton's method, a quasi-Newton's method (BFGS), a steepest descent approach, and a conjugate gradient method. After the script executes, a figure appears that shows a contour plot of the solution with a graphical depiction of the progress of each method.

comments powered by Disqus