JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY HYDERABAD

JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY HYDERABAD B.Tech II DESIGN AND ANALYSIS OF ALGORITHMS Previous Question Paper (December - 2018 - R15)

B.Tech | II | II | R15 | December - 2018

Answer PaperPaper Code: 124CBMaximum Marks: 75Time: 3 Hours

Note: This question paper contains two parts A and B. Part A is compulsory which carries 25 marks. Answer all questions in Part A. Part B consists of 5 Units. Answer any one full question from each unit. Each question carries 10 marks.

Part A

1a

Write the recurrence relation for divide and conquer.

2 marks

Answer

The general recurrence relation for a divide and conquer algorithm that divides a problem of size n into a subproblems, each of size n/b, is given by:

T(n) = aT(n/b) + f(n)

where a ≥ 1 is the number of subproblems, n/b is the size of each subproblem, and f(n) represents the cost of dividing the problem and merging the results of the subproblems.

1b

List out the drawbacks of merge sort algorithm.

3 marks

Answer

The merge sort algorithm has the following primary drawbacks:

  • Space Complexity: It requires an additional auxiliary array of size O(n) to store the merged elements, making it less space-efficient compared to in-place sorting algorithms like quicksort or heapsort.
  • Performance on Small Arrays: For small datasets, the overhead of recursive calls and the repeated copying of elements between the auxiliary array and the original array makes it slower than simpler algorithms like insertion sort.
  • Data Movement: The algorithm involves significant data movement, as elements are constantly copied into the auxiliary array and then back to the original array, which can be inefficient for large objects or complex data structures where copying is costly.
1c

Describe and/or graph.

2 marks

Answer

Sign in to view the complete answer paper.

1d

Explain briefly game trees.

3 marks

Answer

Sign in to view the complete answer paper.

1e

List the applications of Dynamic programming.

2 marks

Answer

Sign in to view the complete answer paper.

1f

Define feasible solution, optimal solution and objective function.

3 marks

Answer

Sign in to view the complete answer paper.

1g

Differentiate live node and dead node.

2 marks

Answer

Sign in to view the complete answer paper.

1h

Define solution state and answer state.

3 marks

Answer

Sign in to view the complete answer paper.

1i

What is decision problem?

2 marks

Answer

Sign in to view the complete answer paper.

1j

Define class NP.

3 marks

Answer

Sign in to view the complete answer paper.

Part B

210 marks
a

Define algorithm. Write about algorithm design techniques.

5 marks

Answer

Sign in to view the complete answer paper.

b

Describe Strassen’s matrix multiplication. Perform the multiplication operation on following two matrices using Strassen’s technique.

[[3, 5], [2, 7]] * [[4, 6], [8, 3]]
5 marks

Answer

Sign in to view the complete answer paper.

OR
310 marks
a

What is amortized analysis? Explain in detail about techniques used in amortized analysis with help of dynamic array example.

5 marks

Answer

Sign in to view the complete answer paper.

b

Show how quick sort sorts the following sequences of keys 65, 70, 75, 80, 85, 60, 55, 50, 45 solve the recurrence relation of quick sort using substitution method.

5 marks

Answer

Sign in to view the complete answer paper.

410 marks
a

Write the pseudo codes for various operations used by disjoint set.

5 marks

Answer

Sign in to view the complete answer paper.

b

Define articulation point. Write the algorithm to find articulation point.

5 marks

Answer

Sign in to view the complete answer paper.

OR
510 marks
a

Explain the graph traversal method with help of following graph shown in figure 1.

5 marks

Answer

Sign in to view the complete answer paper.

b

Write and explain the FIND algorithm for collapse rule with example.

5 marks

Answer

Sign in to view the complete answer paper.

610 marks
a

A thief enters a house for robbing thief can carry a maximum weight of 6kg into his bag. There are 3 items in the house with weights (w1, w2, w3) = (2, 3, 4) and profits (p1, p2, p3) = (1, 2, 5) what items should thief can take will get the maximum profit? He either takes or leaves the item.

5 marks

Answer

Sign in to view the complete answer paper.

b

Describe in detail job sequencing with deadlines problem. Let n= 4, (P1, P2, P3, P4) = (100, 10, 15, 27) and (d1, d2, d3, d4) = (2, 1, 2, 1) find the optimal solution.

5 marks

Answer

Sign in to view the complete answer paper.

OR
7

Explain prim’s and krushkal’s algorithm shown in figure 2 with the following example.

10 marks

Answer

Sign in to view the complete answer paper.

8

What is n-queen problem? Describe 4-queen problem using back tracking.

10 marks

Answer

Sign in to view the complete answer paper.

OR
9

Find the minimum cost of Tour (TSP) for the following adjacency matrix shown in figure 3 using Branch and Bound.

[[0, 10, 15, 20], [5, 0, 9, 10], [6, 13, 0, 12], [8, 8, 9, 0]]
10 marks

Answer

Sign in to view the complete answer paper.

1010 marks
a

Write the Non deterministic algorithm for sorting.

5 marks

Answer

Sign in to view the complete answer paper.

b

Explain CNF-SAT Problem.

5 marks

Answer

Sign in to view the complete answer paper.

OR
1110 marks
a

Explain about cook’s theorem.

5 marks

Answer

Sign in to view the complete answer paper.

b

Explain the P, NP-Hard and NP-complete classes? Give the relation between them.

5 marks

Answer

Sign in to view the complete answer paper.

About this paper

This page contains the solved question paper with answers of DESIGN AND ANALYSIS OF ALGORITHMS from JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY HYDERABAD for B.Tech CSE II II, December - 2018, R15.

For the question paper without answers, switch to the Question Paper tab.

Other papers in DESIGN AND ANALYSIS OF ALGORITHMS

Loading Question Papers

Fetching data from database...