
Benjamin T. answered 04/03/24
Physics Professor, and Former Math Department Head
So the first step in this problem would be to draw a picture. You should include the tanks, the refinery, and point P. Let the south bank of the river lie on the x-axis, put the tanks at the origin, and put the refinery at point (-8,2). Point P should be at (x,1) where we are looking for x. You can just put it where you think it would be for now. This graph is not for accuracy it is to help us create the cost of function.
The pipe will consist of two straight sections. The first section will go from the tanks to P, and the second will go from P to the refinery. Using the distance formula,
lTP = √(x2 + 1)
lRP = √((-8-x)2+1)
where lTP is the length of the pipe from the tanks to P and lRP is the length from the refinery to P.
The cost function is a function of x given as,
c(x) = -5×105 √((-8-x)2+1) + 106 √(x2 + 1)
where each term is the cost of the section of pipe.
To minimize cost we take the derivative and set it equal to zero.
dc/dx = 5×105 (x-8)/√((-8-x)2+1) + 106 x/√(x2 + 1) = 0
This does not look like it has an easy solution so you might want to graph dc/dx and use a calculator to find its intercept.
x ≈-0.57
Make sure to double check my algebra!