A new cottage is built across the river and 300m downstream from the nearest telephone relay station. the river is 120m wide. in order to wire the cottage for phone service, wire will be laid across the river under water, and along the edge of the river above ground. the cost to lay wire under water is 15$/m and the cost to lay above ground is 10$/m. how much wire should be laid underwater to minimize the cost?

i set up total cost=

T(c)={\frac{\sqrt{{x^2+120^2}}{15}} + {\frac{300-x}{10}}

T(c)=\frac{1}{15}(x^2+14400)^{\frac{1}{2}} + \frac{1}{10}(300-x)

then i differentiated to get

T'(c)= \frac{1}{15} \frac{1}{2} (x^2+14400)^{{\frac{-1}{2}}(2x) - \frac{1}{10}

T'(c)=\frac{x}{(15(x^2+14400)^{\frac{1}{2} - \frac{1}{10}

i set T'(c)=0 and solved and got a negative number which i could not take the square root of which is where i know i went wrong. where did i go wrong? having trouble with LaTex

i think the problem may be that the original equation made up should be

T(c)={\frac{\sqrt{{x^2+120^2}}{15}} (-) {\frac{300-x}{10}}

instead of (+) because it is asking for wire underground