0% found this document useful (1 vote)
70 views

Assignment 2

This document outlines an assignment for a discrete mathematics course. It includes 9 questions covering various topics in discrete mathematics, such as functions, sorting algorithms, prime factorizations, modular arithmetic, and matrix operations. Students are asked to determine if functions are one-to-one and onto, sort a list of numbers, prove asymptotic bounds, find divisors and common factors of integers, perform base conversions, use the Euclidean algorithm, and calculate various matrix operations.

Uploaded by

Muhammad Umair
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (1 vote)
70 views

Assignment 2

This document outlines an assignment for a discrete mathematics course. It includes 9 questions covering various topics in discrete mathematics, such as functions, sorting algorithms, prime factorizations, modular arithmetic, and matrix operations. Students are asked to determine if functions are one-to-one and onto, sort a list of numbers, prove asymptotic bounds, find divisors and common factors of integers, perform base conversions, use the Euclidean algorithm, and calculate various matrix operations.

Uploaded by

Muhammad Umair
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

SIT192: DISCRETE MATHEMATICS

Trimester 1, 2019

Assignment 2
Due date: Friday, May 3rd, 11.59 pm

1. Let Z be the set of integers, R the set of real numbers, A = {-5,0,2,5} and

B = {5,13,55}. For each of the following functions check whether or not it is both 1:1

and onto.

In each case justify your conclusion.

(i) f: R → R , where f(x) = -3x + 7;

(ii) f: Z → Z , where f(x) = 2x - 3;

(iii) f: R → R , where f(x) =4x2 - 1;

(iv) f: A → B , where f(x) = 2x2 + 5

2. Use bubblesort to arrange the numbers 91, 68, 52, 77, 14 and 18 into ascending

order. Write the list after each exchange of numbers. How many comparisons are

there altogether?

3. (i) Prove, by finding witnesses that:

f(x) = 3x3 + 7x2logx + 15x - 10 is O(x3)

(ii) Prove that f(x) = 5x4 + 7x2 – 3x - 6 is NOT O(x3)

4. Find the prime factorization of each of the following integers:

(i) 637 (ii) 767 (iii) 841

(iv) 1375 (v) 1581 (vi) 10693

5. Find the greatest common divisors and least common multiples for each of the
following pairs of integers.

(i) 400 and 500 (ii) 2023 and 12103

(iii) 24 x 32 × 134 × 292 and 2 x 3 x 13


6. Find:

(i) 81 mod 7 (ii) -81 mod 7 (iii) -17 mod 5

(iv) 550 mod 624

7. (a) Convert the following integers from the given base into base 10

(i) (13614)7 (ii) (1001120302)4

(b) Convert 756 from base 10 notation to:

(i) base 2 notation; (ii) base 3 notation; (iii) base 6 notation

8. Use the Euclidean Algorithm to find the greatest common divisors of each of the
following pairs of integers:

(i) 1463 and 2737 (ii) 2277 and 2457

1  1 5 0 2
9. Given that A = 3 0 1 and B = [−1 −2] calculate, if possible:
 
(i) BA (ii) AB

(iii) AT B (iv) B2

(v) B3 (vi) AAT

If it is not possible to do a calculation, explain why not.

You might also like