Design And Analysis Of Algorithms

Search for question

Questions & Answers

QUESTION 1 Write down a set A of 4 people who are studying at ECU. One of the people in the set should be yourself. Write down a set B of 3 units at ECU. One of those units should be MAT1252. (a) (i)Design a relation R from the set A to itself. The relation should contain at least three elements. Give your relation using infix notation. (ii)Design a relation S from the set A to the set B. The relation should contain at least three elements. Give your relation as a graph. (b) (i)Draw an arrow diagram the composition SR which shows the intermediate arrow diagrams of R and S. (E.g., Lecture 6 slide 24). (ii)Write down the composition S R using ordered pair notation.O (c) (i)Decide whether your relation R is reflexive, symmetric or transitive.Explain your answers to each part. I.e., if the answer is 'no', find specific elements which do not satisfy the property, and if the answer is'yes', explain how you know the answer is yes. (ii)Is your relation R an equivalence relation? Explain your answer. (d)Is your relation S a function? Explain your answer.


4. Give the binary representation for the following tree, showing your intermediate work. Answers consisting of only a binary string will not be marked.


1 Insertion Sort with binary search (5 points)Run the Insertion Sort algorithm with binary search on the following (inte-ger) array: Please indicate how the array looks after each step. How many comparisonsdid the algorithm perform?


No Question Found forDesign And Analysis Of Algorithms

we will make sure available to you as soon as possible.