final DS 2009 2010

Embed Size (px)

Citation preview

  • 8/10/2019 final DS 2009 2010

    1/5

    V

    V H

    > /

    ^ 1

    o.

    (4 marks)

    Q6 Based on FIG UR E Q6,

    (a) List the relation

    R.

    (2 m arks)

    (b) Find the dom ain and range.

    (2 m arks)

    Q7 Determine whether the directed graph in FI G UR E.Q 7 is Euler circuit or Euler path.

    Explain your answer (use the degree of. vertices)

    (4 marks)

    3

  • 8/10/2019 final DS 2009 2010

    4/5

    BIT1113

    P A R T B

    Answer FIVE (5) questions only.

    Q8 (a) Based on the follo win g relations, assign these pairs ( 1 , 1 ) , 1, 2) , 2,1) , 2, 2)

    to appropriate relations.

    (i) R1 = { (a ,b ) I a ^ b}

    (ii) R2 = { (a ,b) | a > b}

    (4 marks)

    (b) Given the set {1, 2, 3, 4} , decide whether the follow ing relations is reflexive ,

    symmetric

    or

    transitive.

    (i) {(2,2), (2,3), (2,4), (3,2), (3,3), (3,4)}

    (ii) {(1,1),( 1,2),(2,1 ),(2,2),(3,3 ),(4,4)}

    (ii i) {(1,2), (2,3)(3,4)}

    (4 marks)

    Q9 (a) Write an algorithm to find the ma ximu m value from three numbers; a, b, c.

    (4 marks)

    (b) Answ er all the questions based on a graph given in FI G UR E Q9.

    b c 6 d

    Find the:

    (i) length of the shortest path from a to i .

    (ii) length of the shortest path from a to z.

    (iii) length of the shortest path from a to z that passe s through c.

    (4 marks)

    Q10 Let

    A = {L, 2, 3, 4, 5

    } a n d B =

    {0, 2, 4, 6, 8

    }. Suppose

    R

    is

    a

    relation from

    A

    to

    which is defined as follows . Write down the elements of

    R.

    (a) x R y *

    x ^ y.

    (2 marks)

    4

  • 8/10/2019 final DS 2009 2010

    5/5

    BIT1113

    (b) x R y *

    x - y is even.

    (3 marks)

    (c) x Ry x + y = 7.

    (3 marks)

    QLL (a) Le tA = { l , 3, 5} and

    B

    = {

    S

    , t , u, v}. A function f is given in FIG UR E

    Q l l be low .

    A B

    F I G U R E Q l l

    (i) Identify the domain and co-dom ain for function f.

    {"(a,a) y*(*a,b)',

    1

    (b , c ' f / i c^d ) ' , ( c f /a ) , ld , b ) }

    Q12 (a ) P r ov e that 6 x 7 " - - 2 x 3 " i s d iv is ib le b y 4

    (b) Sho w that

    + 2 n

    i s 0 ( n

    2

    )

    n + 1

    Q13 Solve the follow ing recurrence relation,

    a

    n

    = 8a

    n

    - - 16a

    n

    -

    2

    , where a

    0

    = 1, a = 2.

    (3 marks)

    (4 marks)

    (4 marks)

    (8 marks)

    5