You are going to Europe by road! Wow. And its one single road (wow!). You start on the road at distance d; =0. There are

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899604
Joined: Mon Aug 02, 2021 8:13 am

You are going to Europe by road! Wow. And its one single road (wow!). You start on the road at distance d; =0. There are

Post by answerhappygod »

You Are Going To Europe By Road Wow And Its One Single Road Wow You Start On The Road At Distance D 0 There Are 1
You Are Going To Europe By Road Wow And Its One Single Road Wow You Start On The Road At Distance D 0 There Are 1 (59.65 KiB) Viewed 30 times
You are going to Europe by road! Wow. And its one single road (wow!). You start on the road at distance d; =0. There are many stopovers on this roads and these are located at distances d, <d, <...< dn. You are driving the car yourself and will need to stop at some of these stopovers. In the end, you will definitely stop at the final stopover at distance da Your aim is to travel 500 kms every day (you make stopover at night), as this seems to be the ideal distance that balances the fatigue with the pleasure of travelling the most. However, it's not always possible to do so because the stopovers are not always 500 kms apart from each other. (If they were, you could travel 500 Kms and make a stop, and so on). Being of a quantitative bent of mind, you have formulated that if you travel a miles in a day, the amount of 'loss' in terms of more fatigue and less joy) for that day is (500 - a)? You want to make stops such that this total loss is minimized – that is, the sum over all travel days, of the daily losses is minimized. Give an efficient DP algorithm that determines the optimal sequence of stopovers at which to stop so as to minimize loss, (a) Define a subproblem (b) Write a recurrence (c) Write a bottom up algorithm to compute the subproblem solutions (d) Write a method to retrieve the optimal stopover sequence that produces the optimal (minimum) value of loss.
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply