Hello, camherokid!
A slightly different approach . . .
A boat leaves a dock at 2:00PM and travels due south at a speed of 20km/h.
Another boat has been heading due east at 15km/h and reached the same dock at 3PM.
At what time were the two boats closest together? Code:
P 15t B 1515t C
*     *       *
\ 
\ 
\ 
x \ 20t
\ 
\ 

* A
Ship #1 starts at C at 2 PM and travels south at 20 km/hr.
In the next t hours, it travels 20t km to point A
Since Ship #2 reaches C at 3 PM at 15 km/hr,
. . it was 15 km west of C at 2 PM at point P.
In the next t hours, it travels 15t km to point B.
. . Hence: . BC = 15  15t
Let x = AB, the distance between the ships.
. . Then: .x² .= .(20t)² + (15  15t)² .= .625t²  450t + 225
Differentiate: .2x(dx/dt) .= .1250 t  450
. . and we have: .dx/dt .= .625t  225)/x .= .0
. . Hence: .t .= .9/25 .= .0.36 hours .= .21 minutes, 36 seconds
Therefore, the ships are closest at 2:21'36" PM
Since x² .= .625(0.36)²  450(0.36) + 225 .= .144
. . their minimum distance is: .x = 12 km.