Top Banner
Pia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete Mathematics (English) Duration: 5 hours Date: 13 March 2012 The compulsory part of this examination consists of 8 questions. The maximum number of points available is 24. The points for each part of a question are indicated at the end of the part in [ ]-brackets. The final grade on the course is determined by how well the candidates demonstrate that they have met the learning outcomes on the course. Provided all learning outcomes have been met, the following guide values will be used to set the course grade: E: 9p D: 10p C: 14p B: 18p A: 22p The final question on the paper is the Aspect Question, it is optional and carries no value in terms of marks, but a good solution of this Aspect Question may raise a candidate’s grade by one grade. The candidates are advised that they must always show their working, otherwise they will not be awarded full marks for their answers. The candidates are further advised to start each of the nine questions on a new page and to label all their answers clearly. This is a closed book examination. No books, notes or mobile telephones are allowed in the examination room. Note that Mathematical Formula Collection Edition 2 is allowed on this tenta and will be available in the examination room. Electronic calculators may be used provided they cannot handle formulas. The make and model used must be specified on the cover of your script. GOOD LUCK!! c NAT, Mid Sweden University 1 PLEASE TURN OVER
14

MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete

Apr 18, 2020

Download

Documents

dariahiddleston
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete

Pia Heidtmann

MID SWEDEN UNIVERSITY

NAT

Examination 2012

MA095G/MA098G Discrete Mathematics (English)

Duration: 5 hours

Date: 13 March 2012

The compulsory part of this examination consists of 8 questions. The maximumnumber of points available is 24. The points for each part of a question are indicatedat the end of the part in [ ]-brackets.

The final grade on the course is determined by how well the candidates demonstratethat they have met the learning outcomes on the course. Provided all learningoutcomes have been met, the following guide values will be used to set the coursegrade:

E: 9p D: 10p C: 14p B: 18p A: 22p

The final question on the paper is the Aspect Question, it is optional and carries novalue in terms of marks, but a good solution of this Aspect Question may raise acandidate’s grade by one grade.

The candidates are advised that they must always show their working, otherwisethey will not be awarded full marks for their answers.

The candidates are further advised to start each of the nine questions on a newpage and to label all their answers clearly.

This is a closed book examination. No books, notes or mobile telephonesare allowed in the examination room. Note that Mathematical FormulaCollection Edition 2 is allowed on this tenta and will be available in theexamination room.

Electronic calculators may be used provided they cannot handle formulas.The make and model used must be specified on the cover of your script.

GOOD LUCK!!

c© NAT, Mid Sweden University 1 PLEASE TURN OVER

Page 2: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete

Question 1

(a) Express the binary number (10101011100101)2

(i) in base 10;(ii) as a hexadecimal number. [1]

(b) Let p and q be the following propositions concerning positive integers n.

p : n < 20 q : gcd(n, 20) < 20.

Say whether the following propositions are true or false, and give acounterexample to each false proposition.

(i) p⇒ q;(ii) q ⇒ p;(iii) p if q;(iv) p only if q. [2]

Question 2Let R be the relation on S = {w, x, y, z} which only contains the following relatedpairs:

wRw, wRx, wRy, wRz, xRx, yRw, yRz, zRw.

(a) Draw a directed graph modelling the relation R.

(b) The relation R is not symmetric. Which minimal set of pairs should be addedto R to make it symmetric?

(c) The relation R is not reflexive. Which minimal set of pairs should be added toR to make it reflexive?

(d) The relation R is not transitive. Which minimal set of pairs should be addedto R to make it transitive? [2]

Question 3

Consider the sequence defined by the recurrence relation

xn = 4(xn−1 − xn−2) for n ≥ 2,

and initial terms x0 = 1 and x1 = 1.

(a) Showing your working, compute x2, x3, x4 and x5. [0.5]

(b) Prove by induction that xn = (2− n)2n−1 for all n ≥ 0. [2]

c© NAT, Mid Sweden University 2 MA095G/MA098G

Page 3: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete

Question 4

(a) A PIN-code for a credit card consists of an ordered sequence of 4 digits fromthe set {0, 1, 2, 3, 4, 5, 6, 7, 8, 9}. How many such PIN-codes have precisely twoidentical digits? [1]

(b) How many partitions of the set {1, 2, . . . , 10} exist with each part containingexactly two elements? [1]

(c) How many positive integers less than 700 are

(i) a multiple of 7?

(ii) a multiple of 3, 5 or 7? [1]

Question 5Use Dijkstra’s algorithm to find the shortest path from vertex x to vertex y in thefollowing weighted graph. Show carefully the order in which the vertices are beingprocessed by the algorithm, how the vertices are labelled and how these labels change.Give also the length of the shortest path. [2]

sx

sg

sd

sa sb

s e

si

sh

sf

sc

sy

������������

������

������

@@@@@@@@@@@@

@@@@@@

@@@@@@

4

2

6

4

6

1

1

6

2

1

1

4 4

3

7

1

7

1

6

2

7

1

Question 6

(a) Consider the function f : Z→ Z given by the rule

f(x) = 3x− 17.

(i) Give the range of f .

(ii) Show that f is O(x). [1.5]

(b) (i) State the Pigeonhole Principle.

(ii) Suppose that A and B are finite sets such that |A| > |B|.Explain why there does not exist a function g : A→ B whichis one-to-one (injective). [1.5]

c© NAT, Mid Sweden University 3 PLEASE TURN OVER

Page 4: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete

Question 7

(a) Use Euclid’s Algorithm to show that there are integers s and t such that

3021s + 1203t = 6.

[2]

(b) Showing your working, find all solutions [x] ∈ Z3012 to the equation

[1203]� [x] = [6].

[1]

(c) Say whether the following propositions are true or false, giving a counterex-ample to each false proposition.

(i) For all positive integers a, b we have that if 3021|ab then 3021|a or 3021|b.(ii) If 15x ≡ 15y (mod 3021) then x ≡ y (mod 3021);

(iii) If 15x ≡ 15y (mod 1013) then x ≡ y (mod 1013).

[1.5]

Question 8

(a) For each of the following statements, decide whether it is true or false. Justifyyour answers.

(i) There exists a simple graph with degree sequence 2,2,3,3,3,4,4;

(ii) There exists a simple graph on 7 vertices and 20 edges. [1]

(b) When is a graph called a tree? [0.5]

(c) Suppose that G is a connected, simple graph on n vertices.How many edges are there in a spanning tree of G? [0.5]

(d) Let G be a connected, simple graph on n vertices and n− 1 edges.Explain why G is a tree. [1.5]

(e) Construct an example of a simple graph H on 7 vertices and 6 edges that isnot a tree. [0.5]

Uppgift A

Prove that your answer to Question 8(c) is correct.

c© NAT, Mid Sweden University 4 END OF EXAMINATION

Page 5: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete

Pia Heidtmann

MITTUNIVERSITETET

NAT

Tentamen 2012

MA095G/MA098G Diskret Matematik (svenska)

Skrivtid: 5 timmar

Datum: 13 mars 2012

Den obligatoriska delen av denna tenta omfattar 8 fragor. Delfragornas poang starangivna i marginalen inom [ ]-parenteser. Maximalt poangantal ar 24.

Betyg satts efter hur val larandemalen ar uppfyllda. Riktvarden for betygen ar:

E: 9p D: 10p C: 14p B: 18p A: 22p

Darutover innehaller skrivningen en frivillig aspektuppgift som kan hoja betyget omden utfors val med god motivering.

Behandla hogst en uppgift pa varje papper!

Till alla uppgifter skall fullstandiga losningar lamnas. Resonemang, ekvationslosningaroch utrakningar far inte vara sa knapphandiga att de blir svara att folja. Brister iframstallningen kan ge poangavdrag aven om slutresultatet ar ratt!

Hjalpmedel: Matematisk Formelsamling (delas ut), skriv- och ritmaterialsamt miniraknare som ej ar symbolhanterande. Ange marke och modellpa din miniraknare pa omslaget till tentamen.

LYCKA TILL!!

c© NAT Mittuniversitetet 1 VAND

Page 6: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete

Uppgift 1

(a) Uttryck det binara talet (10101011100101)2

(i) i basen 10;(ii) som ett hexadecimaltal. [1]

(b) Lat p och q vara foljande tva pastaenden om positiva heltal n:

p : n < 20 q : sgd(n, 20) < 20.

Ange om foljande pastaenden ar sanna eller falska och ge ett motexempel tillalla falska pastaenden.

(i) p⇒ q;(ii) q ⇒ p;(iii) p om q;(iv) p endast om q. [2]

Uppgift 2Lat R vara relationen pa mangden S = {w, x, y, z} som endast innehaller foljanderelaterade par:

wRw, wRx, wRy, wRz, xRx, yRw, yRz, zRw.

(a) Rita en riktad graf som beskriver relationen R.

(b) Relationen R ar inte symmetrisk. Ange den minsta mangden av par som mastelaggas till R for att R skall bli symmetrisk.

(c) Relationen R ar inte reflexiv. Ange den minsta mangden av par som mastelaggas till R for att R skall bli reflexiv.

(d) Relationen R ar inte transitiv. Ange den minsta mangden av par som mastelaggas till R for att R skall bli transitiv. [2]

Uppgift 3

En talfoljd definieras genom rekursionsformeln

xn = 4(xn−1 − xn−2) dar n ≥ 2,

och begynnelsevillkoren x0 = 1 och x1 = 1.

(a) Bestam x2, x3, x4 och x5. Visa dina utrakningar. [0.5]

(b) Bevisa med induktion att xn = (2− n)2n−1 for alla n ≥ 0. [2]

c© NAT Mittuniversitetet 2 MA095G/MA098G

Page 7: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete

Uppgift 4

(a) En PIN-kod for ett kreditkort bestar av en ordnad sekvens av 4 siffror franmangden {0, 1, 2, 3, 4, 5, 6, 7, 8, 9}. Hur manga PIN-koder har precis tva siffrorsom ar lika? [1]

(b) Hur manga partitioner finns det av mangden {1, 2, . . . , 10} om varje del skainnehalla precis tva element? [1]

(c) Hur manga positiva heltal mindre an 700 ar

(i) en multipel av 7?

(ii) en multipel av 3, 5 eller 7? [1]

Uppgift 5Anvand Dijkstras algoritm for att bestamma en kortaste stig fran horn x till horny i foljande viktade graf. Redovisa gangen i losningen, dvs. ur din losning ska detframga i vilken ordning hornen behandlas, hur hornen marks och hur markena andrasnar du arbetar dig igenom algoritmen. Ange ocksa kortaste stigens langd. [2]

sx

sg

sd

sa sb

s e

si

sh

sf

sc

sy

������������

������

������

@@@@@@@@@@@@

@@@@@@

@@@@@@

4

2

6

4

6

1

1

6

2

1

1

4 4

3

7

1

7

1

6

2

7

1

Uppgift 6

(a) Lat f : Z→ Z vara funktionen

f(x) = 3x− 17.

(i) Ange vardemangden till f .

(ii) Visa att f ar O(x). [1.5]

(b) (i) Formulera Dirichlets Ladprincip.

(ii) Antag att A och B ar andliga mangder sadana att |A| > |B|.Forklara varfor det inte existerar en funktion g : A→ B som ar injektiv.

[1.5]

c© NAT Mittuniversitetet 3 VAND

Page 8: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete

Uppgift 7

(a) Anvand Euklides algoritm for att visa att det finns heltal s och t sadana att

3021s + 1203t = 6.

[2]

(b) Bestam alla losningar [x] ∈ Z3012 till ekvationen

[1203]� [x] = [6].

Visa dina utrakningar. [1]

(c) Ange om foljande pastaenden ar sanna eller falska och ge ett motexempel tillalla falska pastaenden.

(i) For alla positiva heltal a, b galler att om 3021|ab sa 3021|a eller 3021|b.(ii) Om 15x ≡ 15y (mod 3021) sa ar x ≡ y (mod 3021);

(iii) Om 15x ≡ 15y (mod 1013) sa ar x ≡ y (mod 1013).

[1.5]

Uppgift 8

(a) Ange om foljande pastaenden ar sanna eller falska. Motivera dina svar.

(i) Det finns en enkel graf med gradfoljden 2,2,3,3,3,4,4;

(ii) Det finns en enkel graf med 7 horn och 20 kanter. [1]

(b) Definiera vad som menas med att en graf ar ett trad. [0.5]

(c) Antag att G ar en sammanhangande enkel graf med n horn.Hur manga kanter finns det i ett uppspannande trad for G? [0.5]

(d) Antag att G ar en sammanhangande enkel graf med n horn och n− 1 kanter.Forklara varfor G ar ett trad. [1.5]

(e) Konstruera en enkel graf H med 7 horn och 6 kanter som inte ar ett trad. [0.5]

Uppgift A

Bevisa att ditt svar pa uppgift 8(c) ar korrekt.

c© NAT Mittuniversitetet 4 SLUT PA TENTAMEN

Page 9: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete
Page 10: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete
Page 11: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete
Page 12: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete
Page 13: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete
Page 14: MID SWEDEN UNIVERSITY NAT Examination 2012 ...apachepersonal.miun.se/~piahei/adm/res/tentor/dma1203.pdfPia Heidtmann MID SWEDEN UNIVERSITY NAT Examination 2012 MA095G/MA098G Discrete