0% found this document useful (0 votes)
52 views21 pages

Math1005 and Math6005 Sample Final

Uploaded by

cocofzfz
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
52 views21 pages

Math1005 and Math6005 Sample Final

Uploaded by

cocofzfz
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 21

Australian Student Number:

National
u
University

Mathematical Sciences Institute


EXAMINATION: SAMPLE Final Exam, Semester 1, 2024
MATH1005/MATH6005: Discrete Mathematical Models

Exam Duration: (See below) minutes.


Reading Time: 15 minutes.

Materials Permitted In The Exam Venue:

• Unannotated (foreign-to-English or just English) paper-based dictionary (no approval required).

• No notes or electronic aids are permitted e.g. laptops, phones, calculators.

Materials To Be Supplied To Students:

• Extra paper for writing solutions is available; just raise your hand and ask an invigilator to
bring it for you.

Instructions To Students:

• You must justify your answers and show your work. Please be neat.

• Write all solutions in the appropriate spaces in the exam paper. If you need extra space for a
solution, first use the blank page at the back of the paper; use extra paper if you still need more
space after filling the back page. Please indicate in the appropriate space in the exam paper if
your solution continues on the back page or on an extra piece of paper.

• Cross out any work that you do not wish the examiners to consider.

• No paper may leave the exam room.

• Questions on the paper are organised into 9 Problems, each worth 6 marks. On your actual final,
there will be 11 problems, each worth 6 marks. The total number of marks available on this exam
is 54. On your actual final there will be 66 marks available. You should budget about 16 minutes
per problem. Your best strategy may include leaving some parts of some problems blank if you
do not know how to complete them. YOU SHOULD AIM TO COMPLETE THIS SAMPLE
EXAM IN 2.5 HOURS PLUS READING TIME. YOU HAVE 3 HOURS To COMPLETE
YOUR ACTUAL FINAL.

• No solutions to this sample exam will be provided.


Throughout this exam we write N for the set {1, 2, 3, . . . } and we write Z≥0 for the set {0, 1, 2, 3, ...} .

Problem 1 (6 marks)

(a) For each of the following sentences, circle one of the words STATEMENT/PREDICATE/NEITHER
to indicate the nature of the sentence.

(i) ∀𝑡 ∈ Z 𝑥 ≥ 𝑡 2 STATEMENT /PREDICATE /NEITHER

(ii) ∃𝑥 ∈ N 𝑥 2 − 𝑥
2 = 17 STATEMENT /PREDICATE /NEITHER

(iii) Kruskal’s algorithm is clever.


STATEMENT /PREDICATE /NEITHER

(iv) For any connected graph 𝐺 , 𝐺 has an Euler circuit if and only if every vertex has degree
two. STATEMENT /PREDICATE /NEITHER

(b) Recall that “𝑝 nor 𝑞 ” is logically equiavalent to “¬(𝑝 ∨ 𝑞) .” Consider the following statement:

“Today is Thursday nor I am enjoying my exam, nor, Today is Thursday nor I am


enjoying my exam.”

Write a statement that is logically equivalent to the statement under consideration, but which
uses exactly one logical connective. Your statement should be written in English and you should
use a truth table to justify that your statement is logically equivalent to the statement under
consideration.

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 2 of 21


(c) Suppose that 𝐴 and 𝐵 are non-empty sets. In no more than five sentences, explain each of the
following concepts, how the concepts are related to each other, the notation we typically use for
each:

• a relation from 𝐴 to 𝐵 ;
• a function from 𝐴 to 𝐵 .

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 3 of 21


Problem 2 (6 marks)

(a) Consider the predicate

𝑃 (𝑓 ) : ∀𝑎 1 ∈ N ∀𝑎 2 ∈ N ∀𝑏 1 ∈ N ∀𝑏 2 ∈ N ((𝑎 1, 𝑏 1 ) ∈ 𝑓 )∧((𝑎 2, 𝑏 2 ) ∈ 𝑓 )∧(𝑎 1 < 𝑎 2 )) ⇒ (𝑏 1 < 𝑏 2 )),

defined over the domain of functions from N to N.

(i) Without using the symbol ¬, write down a predicate 𝑄 (𝑓 ) , defined over the domain of
functions from N to N, such that 𝑄 (𝑓 ) ≡ ¬𝑃 (𝑓 )

(ii) Write down an example of a function 𝑔 : N → N for which 𝑃 (𝑔) is true. Justify your
answer.

(iii) Write down an example of a function ℎ : N → N for which 𝑃 (ℎ) is false. Justify your
answer.

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 4 of 21


(b) Let 𝑗 : Z → N be defined by 𝑗 (𝑥) = |𝑥 | + 1. Prove or disprove the following: 𝑗 is surjective.

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 5 of 21


Problem 3 (6 marks)

(a) For each 𝑖 ∈ N, we write 𝑀𝑖 = {. . . , −3𝑖, −2𝑖, −𝑖, 0, 𝑖, 2𝑖, 3𝑖, . . . } .

(i) Use set-builder notation to describe 𝑀5 .

(ii) Either prove or disprove the following statement:

∀𝑛 ∈ N (11𝑛 − 6 ∈ 𝑀5 ).

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 6 of 21


(b) Let 𝐸 denote the set of even integers.

(i) Let 𝐴 and 𝐵 be sets. Write down what it means to say that 𝐴 and 𝐵 have the same
cardinality.

(ii) Write down the rule for a bijection 𝑓 : N → 𝐸 , or explain how you know that no such
bijection exists.

(iii) What fact about 𝐸 does your answer to (ii) demonstrate?

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 7 of 21


Problem 4 (6 marks)

(a) Either use the logical equivalences below and the definitions of set operations to prove, or
provide a counterexample to disprove, the following statement:

For any universal set 𝑈 , and any sets 𝐴, 𝐵, 𝐶, ∈ P (𝑈 ) , 𝐴 ∪ (𝐵 \ 𝐶) = 𝐵 ∪ (𝐴 \ 𝐶) .

Given any statement variables 𝑝 , 𝑞 , and 𝑟 , a tautology 𝑡 and a contradiction 𝑐 , the following hold.
1. Commutative laws: 𝑝 ∧𝑞 ≡ 𝑞 ∧𝑝 𝑝 ∨𝑞 ≡ 𝑞 ∨𝑝
2. Associative laws: (𝑝 ∧ 𝑞) ∧ 𝑟 ≡ 𝑝 ∧ (𝑞 ∧ 𝑟 ) (𝑝 ∨ 𝑞) ∨ 𝑟 ≡ 𝑝 ∨ (𝑞 ∨ 𝑟 )
3. Distributive laws: 𝑝 ∧ (𝑞 ∨ 𝑟 ) ≡ (𝑝 ∧ 𝑞) ∨ (𝑝 ∧ 𝑟 ) 𝑝 ∨ (𝑞 ∧ 𝑟 ) ≡ (𝑝 ∨ 𝑞) ∧ (𝑝 ∨ 𝑟 )
4. Identity laws: 𝑝 ∧𝑡 ≡ 𝑝 𝑝 ∨𝑐 ≡ 𝑝
5. Negation laws: 𝑝 ∨ ¬𝑝 ≡ 𝑡 𝑝 ∧ ¬𝑝 ≡ 𝑐
6. Double negative law: ¬(¬𝑝) ≡ 𝑝
7. Idempotent laws: 𝑝 ∧𝑝 ≡𝑝 𝑝 ∨𝑝 ≡𝑝
8. Universal bound laws: 𝑝 ∨𝑡 ≡𝑡 𝑝 ∧𝑐 ≡ 𝑐
9. De Morgan’s laws: ¬(𝑝 ∧ 𝑞) ≡ ¬𝑝 ∨ ¬𝑞 ¬(𝑝 ∨ 𝑞) ≡ ¬𝑝 ∧ ¬𝑞
10. Absorption laws: 𝑝 ∨ (𝑝 ∧ 𝑞) ≡ 𝑝 𝑝 ∧ (𝑝 ∨ 𝑞) ≡ 𝑝
11. Negations of 𝑡 and 𝑐: ¬𝑡 ≡ 𝑐 ¬𝑐 ≡ 𝑡

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 8 of 21


(b) Throughout this part of the problem we consider the following statement:

For any 𝑥 ∈ Z, if 𝑥 . 2 (mod 3) or 𝑥 . 2 (mod 5) , then 𝑥 . 2 (mod 75) .

(i) Write down the logical structure of a proof of the statement under consideration that
proceeds directly.

(ii) Write down the logical structure of a proof of the statement under consideration that
proceeds via the contrapositive.

(iii) Prove or disprove the statement under consideration.

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 9 of 21


Problem 5 (13 marks)

(a) A web-banking password is always 8 characters long and it always comprises two upper-case
letters from the standard English alphabet, two digits, and four lower-case letters from the
standard English alphabet. How many different passwords can be created that follow these
rules?
Give your answer in the form of an expression that uses only arithmetic operations (possibly
including factorial and exponentiation) and numbers.

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 10 of 21


(b) Consider a probability experiment in which we roll a six-sided die. The outcome of the ex-
periment is the number facing up on the die after it is rolled. Let 𝑆 = {1, 2, 3, 4, 5, 6} and let
𝑋, 𝑌 : 𝑆 → {0, 1} be random variables such that for all 𝑠 ∈ 𝑆 we have
(
0 if 𝑠 ≤ 3,
𝑋 (𝑠) = 𝑠 mod 2, and 𝑌 (𝑠) =
1 otherwise.

Determine whether or not 𝑋, 𝑌 are independent. Justify your answer.

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 11 of 21


Problem 6 (6 marks)

(a) A 4-tuple (𝑥 1, 𝑥 2, 𝑥 3, 𝑥 4 ) ∈ Z≥0 × Z≥0 × Z≥0 × Z≥0 is valid if 𝑥 1 + 𝑥 2 + 𝑥 3 + 𝑥 4 = 50. If a valid


4-tuple is chosen at random, what is the probability that it will contain only the numbers 5, 10,
15 and 20 in some order?
Give your answer in the form of an expression that uses only arithmetic operations (possibly
including factorial and exponentiation) and numbers.

In an excellent response, each of the following will be clearly identified: the experiment, the
sample space, how probabilities will be computed, and any events of interest.

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 12 of 21


(b) A mechanic is working on a car because the front collision detection (FCD) warning light is
illuminated and will not turn off. The mechanic looks up the online manual for the make of car
and reads

“When the FCD warning light is illuminated and will not turn off, 90% of the time
the cause is a faulty wire, and the other 10% of the time the cause is a faulty front
collision sensor.”

The online manual suggests that the mechanic should run a diagnostic test on the front collision
sensor. The diagnostic test will result in one of two possible messages being displayed on the
diagnostic machine: “Fault Found” or “No Fault Found”. Regarding the accuracy of the diagnostic
test, the online manual says the following:

“This highly accurate diagnostic test gives the message ‘Fault Found’ 94% of the
time when the front collision sensor is faulty, and just 4% of the time when there is
no fault with the front collision sensor.”

The mechanic runs the diagnostic and the machine displays the message “Fault Found.” What is
the probability that the front collision sensor is faulty?

Give your answer in the form of an expression involving decimals and arithmetic operations.

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 13 of 21


Problem 7 (6 marks)

(a) Your friend tries to define the term “graph” and writes the following:

“A graph 𝐺 is an ordered pair 𝐺 = (𝑉 (𝐺), 𝐸 (𝐺)) comprising: a set of vertices


𝑉 (𝐺) ; and a set of edges 𝐸 (𝐺) , with each edge being a set of 2 vertices.”

Looking at our lecture notes, you see that we defined the term “graph” as follows:

“A graph 𝐺 is an ordered pair 𝐺 = (𝑉 (𝐺), 𝐸 (𝐺)) comprising: a set of vertices


𝑉 (𝐺) ; and a multiset of edges 𝐸 (𝐺) , with each edge being a size-2 multiset of vertices.”

In no more than three sentences and using appropriate examples, identify the effective differ-
ence(s) between the two definitions.

(b) Let 𝐺 be the weighted graph

A 7 B 1 F
2 3 5 6 4
C 2 D 4 E
.

Draw a minimal spanning tree for 𝐺 in the space below.

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 14 of 21


(c) Let

𝐸 = {(𝑚, 𝑛) ∈ N × N | 𝐾𝑚, 𝑛 has an Euler circuit and 𝑚 + 𝑛 ≥ 3}


𝐻 = {(𝑚, 𝑛) ∈ N × N | 𝐾𝑚, 𝑛 has a Hamilton circuit and 𝑚 + 𝑛 ≥ 3}.

(i) Describe 𝐻 in set-roster notation. Prove that your description gives 𝐻 .

(ii) Use set-roster notation to describe 𝐸 ∩ 𝐻 . Justify your answer.

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 15 of 21


Problem 8 (6 marks)

(i) In no more than three sentences, describe a physical system that may be reasonably
modelled by a transport network. In your description, clearly state what it is about the
physical system that the vertices and directed edges and capacities represent.

(ii) The following is a quote from our lecture slides:


“Given a relation 𝑅 ⊆ 𝑆 ×𝑇 , a matching problem seeks an injective function
𝑓 : 𝑆 ′ → 𝑇 with domain 𝑆 ′ ⊆ 𝑆 as large as possible subject to 𝑚 being an injective
subset of 𝑅 .”
In no more than three sentences explain how a matching problem for 𝑅 ⊆ 𝑆 × 𝑇 may
be converted to the maximum flow problem for a transport network (so that the vertex-
labelling algorithm may be used to solve the matching problem).

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 16 of 21


(iii) Indicate a minimum cut on the following transport network.

a 12 c
16 20
s 4 9 7 t
13 4
b 14 d

(iv) Use the vertex-labelling algorithm described in the course to find a maximum flow function
for the transport network in part (iv). The first incremental flow 𝑓1 is shown in the first
row of the table at the bottom of the page, and the cumulative flow 𝐹 1 is shown in the
graph below. Write down the subsequent incremental flows in the table (use only as many
rows as you need).

a 12, 12 c
16, 12 20, 12
s 4, 0 9, 0 7, 0 t
13, 0 4, 0
b 14, 0 d

incremental path of volume of


flow label incremental flow incremental flow

𝑓1 𝑠𝑎𝑐𝑡 12

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 17 of 21


Problem 9 (6 marks)

(a) We consider population movement within a geographic region comprising a city, its suburbs,
and the hinterland. We aim to understand the relative populations of the city, the suburbs, and
the hinterland as they will change over time. Suppose that the annual migration between the
three parts of the geographic region obeys the following. Each year: 4% of the city residents
move to the suburbs and 2% move to the hinterland; 7% of the suburban residents move to the
city and 2% move to the hinterland; 4% of hinterland residents move to the city and 6% move to
the suburbs; all other residents stay in the region they were in.

(i) Draw a transition diagram for a Markov process model of the population movement.

(ii) Write down a transition matrix 𝑇 for your model.

(iii) List all of the properties a 3 × 1 vector v must satisfy in order to be a steady state of your
model?

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 18 of 21


(b) In this problem we consider applying Google’s PageRank algorithm to a small webgraph 𝑊 .
The adjacency matrix for 𝑊 is


 0 1 0 0 1 1 0 

1 0 0 1 0 1 0
 
 
 

 0 1 0 1 1 0 1 

𝐴= 0 0 0 0 0 0 0
 
.
 

 1 0 1 0 0 0 0 

0 1 0 1 1 0 0
 
 
 

 0 1 1 0 1 1 0 

(i) Write down the basic transition matrix 𝑇 when Google’s PageRank algorithm is applied to
𝑊.

(ii) Write down an expression for the modified transition matrix 𝑀 when Google’s PageRank
algorithm is applied to 𝑊 . Use a damping factor of 85% (that is, 𝛼 = 0.15) .

(iii) In no more than three sentences, explain how to use the matrix 𝑀 to rank the pages in
our small web in order of “awesomeness” (or importance).

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 19 of 21


Vertex-labelling algorithm for finding a maximum flow function for a transport network

Input: Transport network 𝐷 with capacity function 𝐶 .


Output: A maximum flow function 𝐹 max for the network.
Method: Initialise 𝐹 to the zero flow 𝐹 0 . Initialize 𝑖 to 1.
For 𝑖 = 1, 2, . . . carry out stage 𝑖 below to attempt to build an incremental flow 𝑓𝑖 .
If stage 𝑖 succeeds, define 𝐹𝑖 = 𝐹𝑖−1 + 𝑓𝑖 and proceed to stage 𝑖 +1 .
If stage 𝑖 fails, define 𝐹 max = 𝐹𝑖−1 and stop.
Stage 𝑖 :
(a) If 𝑖 > 1 , mark up the amended edge flows for 𝐹𝑖−1 .
(b) Mark up the levels for 𝐹𝑖−1 , as explained below.
(c) If t is assigned a level, stage 𝑖 will succeed, so continue.

If not, then stage 𝑖 fails, so return above to define 𝐹 max and terminate.
(d) Mark up labels for 𝐹𝑖−1 as follows until t is labelled:

(i) Label each level 1 vertex v with s𝑘 v , where 𝑘 v = 𝑆 ((𝑠,𝑣)) . (see below for definition of 𝑆 )
(ii) If t has level 2 or more now work through the level 2 vertices in alphabetical order, labelling each vertex v
with u𝑘𝑢 , where
• u is the alphabetically earliest level 1 vertex with (𝑢,𝑣) ∈ 𝐸 (𝐷) and 𝑆 ((𝑢,𝑣)) > 0 ,
• 𝑘 v is the minimum of 𝑆 ((𝑢,𝑣)) and the value part of u’s label.
(iii) If t has level 3 or more now work through the level 3 vertices in a similar manner and so on.

(e) Let 𝑝𝑖 be the path u0 u1 . . . u𝑛 where u 𝑛 = t and for 0 < 𝑗 ≤ 𝑛


u 𝑗 has label u 𝑗−1𝑘 𝑗 .

Define 𝑓𝑖 to be the incremental flow on 𝑝𝑖 with flow value 𝑘𝑛 .


End of Method
Levels and labels: At each stage of the vertex labelling algorithm levels and labels are associated afresh with the vertices
of the network.

The level of a vertex is determined iteratively as follows:


• The source vertex s always has level 0.
• If 𝑒 = (𝑠, 𝑥) and 𝑆 (𝑒) > 0 then x has level 1.
• If x has level 𝑛 and 𝑆 ((𝑥, 𝑦)) > 0 then y has level 𝑛 + 1 provided it has not already been assigned a lower level.

The label on a vertex v of level 𝑛 ≥ 1 has the form u𝑘 , where u is a vertex of level 𝑛 − 1 and (𝑢, 𝑣) ∈ 𝐸 (𝐷) is an edge on
the path for a potential incremental flow through v with flow value 𝑘 .
The algorithm assigns labels in ascending order of levels, and in alphabetical order within levels.

The spare capacity function 𝑆


For vertices u,v of 𝐷 , where 𝐷 has capacity and flow functions 𝐶, 𝐹 :





𝐶 ((u,v)) −𝐹 ((u,v)) if (u,v) ∈ 𝐸 (𝐷)


𝑆 ((u,v)) = 𝐹 ((v,u)) if (v,u) ∈ 𝐸 (𝐷)



0
 otherwise.

When (v,u) ∈ 𝐸 (𝐷) , 𝑆 ((u, v)) is called a virtual capacity.

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 20 of 21


This page is intentionally blank. If necessary, you may use this space for extra working.

MATH1005/MATH6005 Final Exam, Semester 1, 2024, Page 21 of 21

You might also like