Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
2 views

Tutorial-topic2-functions

The document contains a tutorial sheet for a Discrete Mathematics course, focusing on functions, sets, and their properties. It includes a series of questions that require students to analyze functions, determine their characteristics, and perform calculations related to various mathematical concepts. Topics covered include Hamming distance, encoding and decoding functions, and the properties of different types of functions such as one-to-one and onto.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views

Tutorial-topic2-functions

The document contains a tutorial sheet for a Discrete Mathematics course, focusing on functions, sets, and their properties. It includes a series of questions that require students to analyze functions, determine their characteristics, and perform calculations related to various mathematical concepts. Topics covered include Hamming distance, encoding and decoding functions, and the properties of different types of functions such as one-to-one and onto.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

 

  Discrete Mathematics   
Tutorial sheet  Funtions 

Question 1.
Let A and B be two sets with A = {x, y, z} and B = {1, 2, 3, 4}. Which of
the following arrow diagrams define functions from A to B?

Question 2.
Let A and B be two sets with A = {x, y, z} and B = {1, 2, 3, 4}. Let f from
A to B defined by the following arrow diagram:

1. Write the domain, the co-domain and the range of f .

2. Find f (x) and f (y) .

3. Write down the set of pre-images of 3 and the set of pre-images of 1 .

4. represent f as a set of ordered pairs.

Question 3.

The Hamming distance function is very important in coding theory. It gives


a measure of the difference between two strings of 0’s and 1’s that have the
same length. Let Sn be the set of all strings of 0’s and 1’s of length n. The
Humming function H is defined as follows:

1
H : Sn × Sn → N ∪ {0}
(s, t) → H(s, t) = The number of positions in which s and t have different values.
For n = 5, Find H(11111, 00000), H(11000, 00000) , H(00101, 01110) and
H(10001, 01111) .
Question 4.

Digital messages consist of a finite sequence of 0’s and 1’s. When they are
communicated across a transmission channel, they are frequently coded in
special ways to reduce the chance that they will be garbled by interfering
noise in the transmission lines. A simple way to encode a message of 0’s and
1’s is to write each bit three times, for example: the message 0010111 would
be encoded as 000 000 111 000 111 111 111.
Let A be the set of all strings of 0’s and 1’s and let E and D be the encoding
and the decoding function on the set A defined for each string, s, in A as
follows:
E(s) = The string obtained from s by replacing each bit of s with the same
bit written three times.
D(s) = The string obtained from s by replacing each consecutive triple of
three identical bits of s by a single copy of that bit.
Find E(0110), E(0101), D(000111000111000111111) and
D(111111000111000111000000)
Question 5.

Let A = {1, 2, 3, 4, 5, 6}, B = {a, b, c, d} and C = {w, x, y, z} be three sets.


Let f and g be two functions defined as follows:
f : A → B is defined by the following table.
x 1 2 3 4 5 6
f (x) a b a c d d
g : B → C is defined by the following table.
x a b c d
g(x) w x y z

1. Draw arrow diagrams to represent the function f and g.


2. List the domain; the co-domain and the range of f and g.
3. Find f (1), the ancestor (pre-image) of d. and (g o f)(3)
4. Show that f is not a one to one function.
5. Show that f is an onto function.

2
6. Show that g is both one to one and onto.

Question 6.
Suppose you read that a function f : Z × Z+ → Q is defined by the formula
f (m, n) = m
n
for all (m, n) ∈ Z × Z+ .

1. Is f a one to one function?

2. Is f an onto function?

Question 7.

Given a function f definted by f (x) = bxc. where f : R → Z,

1. Plot the graph of the function f(x) for x ∈ [−3, 3].

2. Use this graph to find bπc , b−2.5c , b−1c.

3. Use the graph in (1) to show that f is not a one to one (not injective)
function.

4. Is f onto (surjective)? Justify your answer.

Question 8.
Let S denote the set of all 3 bit binary strings and B = (0, 1, 2, 3). The
function f : S → B is defined by the rule

f(x)= the number of zeros in x for each x ∈ S.

Find the following.

1. The domain of f .

2. f (001) and f (101).

3. The set of ancestors of 2.

4. The range of f .

5. Say whether or not f is one to one, giving a reason for your answer.

6. Say whether or not f is onto, giving a reason for your answer.

Question 9.
Let f (x) = x mod 3, where f (x) is the remainder when x is divided by 3,
and f : Z+ → {0, 1, 2}.

3
1. Find f (7) and f (12).

2. Find the ancestors of 2.

3. Say whether or not f (x) is one to one, justifying your answer.

4. Say whether or not f (x) is onto, justifying your answer.

Question 10.

Given the following function f : R → R with f (x) = 4x − 1, for any real


number x.
1. Is f a one to one function? Prove or give a counter-example.

2. Is f an onto function? Prove or give a counter-example.

3. Is f invertible? and why? if the answer yes define f −1 .


Question 11.
Given the following function f : Z → Z with g(x) = 4x − 1, for any real
number x.
1. Is g a one to one function? Prove or give a counterexample.

2. Is g an onto function? Prove or give a counterexample.

3. Is g invertible? and why? if the answer yes define g −1 .


Question 12.

Given the following function h : R → R with h(x) = x2 − 1, for any real


number x.
1. What is co-domain and the range of h

2. Is h a one to one function? Prove or give a counterexample.

3. Is h an onto function? Prove or give a counterexample.

4. Is h invertible? and why? if the answer yes define h−1 .


Question 13.
Given the following function h : [0, +∞[→ [−1, +∞[with h(x) = x2 − 1, for
any real number x.
1. What is co-domain and the range of h

4
2. Is h a one to one function? Prove or give a counterexample.
3. Is h an onto function? Prove or give a counterexample.
4. Is h invertible? and why? if the answer yes define h−1 .
5. On the same graph, plot the curve of h and that of h−1 if it exists.
Question 14.
Consider the following function f : R → R+ with f (x) = 2x+3 .
1. Show that f is a bijective function.
2. Find the inverse function f −1 .
3. Plot the both curves of f and of f −1 on the same graph.
Question 15.
2x
Consider the following function f : R − {−1} → R with f (x) = x+1
.
1. Show that f is a one to one function.
2. Show that f is not an onto funcion.
Question 16.

Find the inverse of the following functions:


2 −5
1. f (x) = ex
2. g(x) = ex + 5
Question 17.
Find the inverse of the following functions:
1. f (x) = ln(x + 2) + 2
2. g(x) = log2 (x − 5) + 3
Question 18.
Let A, B and C be three sets/and f : A → B and g : B → C be two
functions. Prove that if gof is an onto function then g must be onto.
Question 19.
Let A, B and C be three sets and f : A → B and g : B → C be two functions.
Prove that if gøf is a one to one function then f must be one to one.
Question 20. √
Let f : Q × Q → R with f (x, y) = x + 2y for all x, y ∈ Q
Is f a one to one function? Prove or give a counter-example.
End of questions

You might also like