$24
The energy cost due to heat loss is roughly equal to 1T r=w. The cost of the pipe, which has a xed wall thickness, is approximately proportional to the total material, i.e., it is given by 2r. The cost of the insulation is also approximately proportional to the total insulation material, i.e., roughly 3rw. The total cost is the sum of these three costs.
The heat ow down the pipe is entirely due to the ow of the uid, which has a xed velocity, i.e., it is given by 4T r2. The constants i are all positive, as are the variables T , r, and w.
Now the problem: maximize the total heat ow down the pipe, subject to an upper limit Cmax on total cost, and the constraints
Tmin T Tmax; rmin r rmax wmin w wmax; w 0:1r
.
Consider a simple instance of this problem, where Cmax = 500 and 1 = 2 = 3 = 4 = 1. Also assume for simplicity that each variable has a lower bound of zero and no upper bound. Solve this problem using JuMP. Use the Ipopt solver and the command @NLconstraint(...) to specify nonlinear constraints such as log-sum-exp functions. What is the optimal T , r, and w?