Question: Follow the example solution to the algorithm to solve number 1. Consider the following input for the maximum-weight independent set problem: V = {V1, V2,

Consider the following input for the maximum-weight independent set problem: V = {V1, V2, ..., V13) and W = {2,7,8, 4, 3, 1, 7, 1, 1,5, 1,8,6}. = 13 Use the dynamic programming algorithm to find the value of the the maximum-weight independent set. Show the array A. Use the reconstruction algorithm to obtain the maximum-weight independent set S. Show S for all iterations of the while loop. Then give the sum W(S) and its value. Solution: W= [2, 7, 8, 4, 3. 1. 7. 1, 1.5, 1. 8, 6] A = [2, 7, 10, 11, 13. 13. 20. 20. 21. 25, 25, 33.33] : S = ) = 12 S = i = 10: S = [12] i = 8: S = [12. 10] : S = (12.10 = 5: S = (12. 10.7 : S = (12. 10. 751 S= [12. 10. 7. 5. 3] S 112. 10. 7.5.3. 1] W(S) = 8 + 5 + 7 + 3 + 8 + 2 = 33 1 =7 1 1. Answer the question with V = {01.02..... va7} and W = {1.9.7.2.2 2.9,6.1.8.6.9.9, 8. 4.2.4}
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
