April / May 2013
Algorithm Design Techniques
Anna University
2 question papers available. Select an examination session to view its question paper.
Algorithm Design Techniques
Algorithm Design Techniques
Based on available extracted papers. Question groups and frequency are provisional, not official syllabus weightage or examination predictions.
Find the order of n 3 +300 +500
0 eligible source papersDefine 0 notation.
0 eligible source papersList the basic steps involved while solving any problem using the Divide-and- Conquer strategy.
1 eligible source papersState a problem that is solved using a Greedy algorithm.
1 eligible source papersWhat are Greedy algorithms?
1 eligible source papersGive an application of the Longest Common Sequence problem.
1 eligible source papersHow is the solution for 8-Queens problem represented?
0 eligible source papersWhat is meant by best-first branch-and-bound algorithm?
1 eligible source papersDefine NP problems using language theoretic framework.
1 eligible source papersState a classical NPC problem.
1 eligible source papersWrite the complete Merge-so rt algorithm including any algorithm it uses and do a worst case analysis of it. Show how the algorithm works on the list {10, 15, 25, 35, 50, 90, 40, 80} (8+4+4)
0 eligible source papers(a) Write the complete Quick-sort algorithm including any algorithm it uses. Generate a recurrence relation for its worst case analysis. Solve this recurrence relation and arrive at its worst-case behavior. (8+2+6)
0 eligible source papers(b) Write the algorithm FASTEST-WAY that finds the fastest way through the factory which has two assembly lines. (16)
0 eligible source papers(a) Write down the MATRIX-CHAIN_ORDER algorithm. Find an optimal parenthesization of a matrix-chain product whose sequence of dimensions is (5, 10, 3, 2, 5 ). How many scalar multiplications are done in that case? Show the m table and s table generated. (16)
0 eligible source papersProve that n° + 300 n—512 is © (n°). . 2. Write the algorithm MAX that finds the maximum in a given list of numbers. 3. List the basic steps involved while solving any problem using the Divide- and-Conquer strategy. 4. Give an example of a problem that can be solved using Dynamic Programming design technique. 5. What is a Greedy algorithm? 6. Output the stations used in the assembly-line scheduling problem given the following | table and [*- 1. j 2; 3 4 5 6) hO]) 2 1 2 1 2 |2]]] 1 2 2 1 1 7. Compare the two techniques, backtracking and branch-and-bound. 8. What data structure would be used to keep track of live nodes in a depth- first branch-and-bound algorithm? 9. Define class P, NP problems. 10. State a classical NPComplete problem.
0 eligible source papers| Write the Binary-Search algorithm that searches for an element in a sorted list. Use a list of 8 elements and illustrate its working. Compute its worst case running time. (16) ©
0 eligible source papers(a) Write the complete Merge-sort algorithm including any algorithm it uses. Assume two sorted sub lists with 4 and 3 elements respectively and explain its working. Do a worst case analysis of it. ; (16)
0 eligible source papers(b) Explain the Activity-selection problem. Write an algorithm to solve it. What is its worst-case running time? Solve the following problem where, for each activity the start and the finish times are given: . Activity 1 (3, 5), Activity 2 (6, 7 ), Activity 3 (3, 6 ), Activity 4 (8, 10), Activity 5 (0, 2). (16)
0 eligible source papers(a) Find an optimal parenthesization of a matrix-chain product whose sequence of dimensions is (4, 10, 5, 3, 5 ). How many scalar multiplications are done in that case? Show the m table and s table generated by the MATRIX- CHAIN ORDER algorithm. (16)
0 eligible source papers(b) Write an iterative algorithm to find a Longest Common Subsequence (LCS) of two given sequences. Compute its worst- case running time. Determine aLCS of <1, 0,0, 1,0, 1> - and <0, 1,0, 1, 0,0, 1>. . (16)
0 eligible source papers(a) State the n-queens problem. Write down an algorithm that solves the n-queens problem using the backtracking technique. Draw the portion of the state space tree that is generated while finding a solution to the 4-queens problem. (16)
0 eligible source papers(b) Solve the following instance of the assignment problem by the branch- and-bound technique. Show the state space tree that is generated. Indicate the order in which the nodes are generated by ~ numbering them. job 1 |job2 | job 3] job4 person a 4 8 3° 7 person b |7 6 5 3 person ௦ 3 6 17 8 person 0 9 |5 9 15 (16)
0 eligible source papers{a) List the sequence of steps that are carried out to prove a problem is NPComplete. Assume any NPC problem of your choice and show that itis NPC. (16) . (OR) (b) (i) Let T be defined for all powers of 2 and given as : T(n) = 4T(n/2) +n and T(1)=0 Find the closed form for T. {8) (0) What is optimal Huffman code for the following set of frequencies, 9:30, 0:15, 0:25, -d:9, e:5, 1:20, g:10, h:40 ? (8)
0 eligible source papersHistorical analysis based on extracted question papers. Topic classifications, marks and planning estimates are provisional.