January 11th, 2006, 9:07 am
Here is how I came to it: let u, s & d be the total length of the uphill, straight & downhill porions as we travel from A to B.And let Vu, Vs & Vd be 56, 78 & 87 respectively for the speeds in those situations.Then from A to B and B to A the times are (noting that uphill becomes downhill & vice versa on the way back):u/Vu + s/Vs + d/Vd = time(A,B) = 4u/Vd + s/Vs + d/Vu = time(B,A) = 4+2/3Solving the system of u & d on the left we get solutions in terms of s:u = 812/57629( 6760 - 31s ) = 95.2493 - 0.436794 sd = 812/57629( 14196 - 31s ) = 200.023 - 0.436794 sAnd u + d + s = 295.273 + 0.126412 s with the fact thats is limited by s <= Min( 95.2493/0.436794, 200.023/0.436794 ) = 218.065 as u, d >= 0.