0% found this document useful (0 votes)
10 views

#Discrete

Uploaded by

Rameshwar Poudel
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)
10 views

#Discrete

Uploaded by

Rameshwar Poudel
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/ 33

i

TRIBIIWAI{ UMVERSITY Exarn. Rcgular'


INSTITUTE OF ENGINEERING Level BE FulI Marks 80

Examination Control Division Prograname BEI, BEX, BCT Pass Mar}s 32


-t
2080 Chaitra Year / Part il/II Time : .t.

Subject: - Discrete Structure (Cr551)


Candidates aic required to give their answers in their own rvords
Attempt 4$ questirsns.
The figwres in tlte *targin indicate Fqtl Mqrks.
Assume suitable data if necessary,.

1. Using mies of inference, derive the conclusicn to the given !:ypothesis: Ilypothesis:"If
today is Sunday ihen I rviil hav* a test in l)iscrete Structurg and l,{iuoprocessor. If my
N{icroprocessor insir'.rctor is busy then tr will not have a test i* lr4icroprocesscr" 1-oday is
Sunday and my Microprocessor instrucior is busy". Coneiusion: "I rvill iaave a test in
Discrete Structure" Show each step and give reasons for th*se steps. i8l
2" What do you mcan by tautology, contradiciion anri contingency? Let Q(x) be the
statement"x { 2." What is t}re iirrth value of the quantification Vx Q(x}. where the
ciomaln consists of all real nrimbers? Frove thar lQ is irrational using proof by
contra<liction. []r 2 i3l
Use rnathematical induction to show thatl2 4"22 .+
, 2 n(n+1)(2n+1)
6
positive integer. l8l
+. Define Non-I)eterministic Finite State Automata. I)raw a transition diagram for
Deterministic and Non-deterministic finite automata which accept a string containing
"ing" at the end of a string in a string of {a-z}, e.g., o'anything" but not'oanywhere". L2+61
5. Consider the regular grammar defined by T = {q b}, N : {S, A} with production mle:
S*-bS,
S--*aA,
A*-+bA,
A-|b.
Where T is Set of Tenninals, N is Set of Non-Terminals and S is a -qtarting symboi.
Construct a Non-deterministic Finite Automata equivalent to the above given regular
gmmmar and convert it into Deterministic Finite Automata. L4+41

6. Find all the solution of recurrenoe relaticn: an=Ban-2 *. 16ua with idtial conditions
as:1,a1:4, a2:28 and a3:32. IS]
7. Use Dijkstra's algorithm to find the cost of shortest path from ata z and also find the
shortest path. tgl

vt s J

-\--l/
,/ ,* z./ t
?

8. Explain the Euler circuit and Hamilton circuit ',vith an examptre. State if there is/are any
nec€ssary and the sufficient conditions for a graph to have Euler's and Ftramilton's paths
and circuits. {Z+Z+Zt2}
9. Define Binary Tree, M-ary tree and Spanning tree. Find the minimal spanning tree from
the graph given below. [3+sl

10. Write short ndtes on: [2x4]


a) Max-flow rnin-cut theorem
b) Graph Coloring
TRIBHUVAN LINIVERSITY :
Uxarn.
INST{TLTTE OF ENGINEERING
t.....

Level BH Full Markr 80


Examination Control Division BEI, BEX, BCT P{sf Msrlffi 32
2079 Chaftra Year/Part II/[ Time 3hrs,
cl: - Discrete Structure (cr s5!)
Candidates are reqnired to give their answers in their own words as far as practicable.
Attempt 4ll qne s tion,s.
The.figures in the margin indicate Full Matltq
Assttme suituble data if necess{u'):.
1. Construct an argument using rules of inlerence to shou' that the hypotheses "if it does not
rain or if it is not foggy, then the sailing race w'ill be held and the lifesaving
demonstration w'ill go on. " "If the sailing race is heici. then the trophy will be awarde<l"
and "The trophy \.vas not awarded" imply the conclusion "It rained". Yt'ru are required to
show each step and give reasons lor those steps Lrelbre you come to the desired
conclusion from the h,vpotheses [8]
2. Use mathematicai induction to pro\,e that 7n'2 '' 82n+l is divisiblc b,v 5V for every
nr:nnegative integer n. 18]

l. State the converse, contrapositive" and inverse of the statement, "Tlie automated repiy
cannot be sent when the file system is full. 14]

4. Let P(x, y) be the propositional fr-mction x > y. ]-he domain of discourse is set of all the
positive integers. Now tell whether the proposition is true or thl1 with reasoning. l2+2i
(a) 3r,YxP (x, y) (b) VyixP (x, y)
5. a) Design a Finite State automata that accepts precrselv those strings over {a, b} that
contains the substring "bba' . \'our .lesrgn shouid include the proper definition of the
flnite-staie ar,rtcmation. transition tat ie and the transition diagrarn. 16]

b) Give regular expressions for follor,i.'ing language [2]


1:{ W€ {a, b}E: contains at-most 2'a'}
6. Given a grammar make NDF;\ and convert it to equivalent DF'A:
A+ sA, A+bll. A-*b, P-rsP, P -+bA, P'+s [2+6]
7. Find all soh-rtions of the recuffence relation: t8l
an:2an-1* 2n2 with initial condition al : 4.

8. Use Dijkstra's aigorithm to find the length of shortest path liom veftex a to ve$ex e in the
following weightecl graph. Also highlight the shortest patlvpaths in graph. I8l
c5
z/ \7
I 9\
5

S\ 'rr/ r

g. I)raw clear and labeled diagrams of Complete graph lvith S Vertices (K6) and
3-dimensional Hypercube (Q:). Also u'rite ttreir Chrornatic Num"oers. Are the graphs K6
and Q3 planar? Give proof lbr your answer. 14"t2-r4)

10. Define Spanning Tree u,ith example. What are the conditions for Euler's circuit and path
in a graph? [2+3]
11. Write short notes on: l3x3]
a) Max Flow and Min cut Theroem
b) Hamiltonian path and circuit
c) Cut sets and cut vertices
:&$E
TRIBHWAN LNIVERSITY
ENGINEERING ii"o"r -*
INSTITUTE oF FuIl Marks 80
Examination controt Division
amination Control Division i ;Ei B#,bci *- ;;fi;;;;; 32
2078 Chatra l *"*i l"p'i4^ ti' rir*^

$yo-iSS!,: ; Disglgte $truct3re ( cr sst )


,/ Candidates are required to give their answers in their own icable.
./ Attempt Att questiotrs.
'/
,/
The figures in the ntargin indicate Full Marks.
As,ct4me suitable data if necessary"
ryxNc
IIMRARY
Use rules of inf'erence to shorr that the hl,pothesis ,'No hurnarls can fly.", "Tweety is a
,I

bird or a human.", "Tweet,v can fly" irnplies the conclusion "Trveety is a bird,'.
[8
2. Write the inverse, covers and contrapositive of the statement" If Covici Spreads then we
rvill have online classes". Use a mathematical induction to prove, if n is non-negative
integer, then (n5-n) is ctrivisible by 5.
a l3+5
J. Define consistencv and Compieteness of the Logical System. Drarv Tableau for formula
set:

0 = {(P
",
-+-e,-p}
Q)" R. p
lz+6
A
+. Given a Language L: { We {a,b} x :\\r ends q,ith'ba'}. Write a regular expression and
design a Finite state automata tirat accepts the language L. Your design shbuld ilclude
proper definition of finite- state automation. transition tabie and transition diagram.
[2+6
5 Consider the regular grammar
i+*+
G:$i,T,P,o) where,
Set of Non-Terminals. N: {o,A,B}
Set of 'ferminais, T: {a.b}
Set of productions, P : {o-+ bE, o -+ bA, A -- ao,E -+ bB, B -+ a,B -; ).}
and starling symbol o.
Construction a Non- Deterministic Finite State .t\utomata eqnivalent to the above given
regular grammff and convert this into DFA,
6. Find all tlre solution of the recurrence relation: irn:6n-l -8r_z + 3", where the initial
conditions: as:4 and a1 : 10.
tg_
7 . Use Dijktra's algorithm to find the length of shortest path between vertices 'a' and 'z' in the
graphs belorn. Also highlighi the shortest path.
ig.

8. State Handshaking Algorithm for directed graph. Define Biparite graph with a suitable
example. Draw a figure for complete biparite graph Ks.s and determine its chromatic
number.
12+2+2+2]
9. l)efine spanning tree with a suitable exampie. Prove that K3,3 is non-planar graph. [3 f5]
10. Write shofi notes on:
{4-r4)
a) Breadth First and Depth First Traversal
b) Cut Edges and Cut Vertices
TRIBHUVAN T]NIVERSITY
INSTITUTE OF ENGINEERING
Examination Control Division BEI, BEX, BCT
2A77 Ch*itra

_ _**____ _$ynlgt:!-,_: p_j1gtql. st j,9$l9_7a_ry1r,


r' candidates are required to give their
t, Attempt Al!questions-
answers in their own words as far
as practicable.
t, fhefigtres in the margin indicate Full *torks.
y' Assume suitable datalf necessary.#

1' Define valid Argument in Logic.


"somebody in this class enjoys whale watching.
person who eqioys whale wa-tching Every
.*.
ubort Therefore, there is a
"*;;lftron.
il'ffiff t H: *ffi *:.t#:iaboui bcean pollution. " sh'ow whether,rr"-d;
;;;"r,
2. what are "counterexampres,,, explain wi&
example- use mathematicar induction
12+61

prove: 13 +23 +3i +...+n3 to


=n2(n+I34 tl foratrr"rrrrurrr*o".
t2+s1
3. Prove that if n:ab, where a and b are positive
integers, then a<Ji or b<Ji.
Determine whether t\ -or
eiven expression is consistent inconsistent using method of
Tableaux: (f n g-+ n)n (_,f + S)" g
_/Q n _^9
4' " [3+5]
Define finite *,:_luffi",tt exampre. Design a Finite state
Auromara that acceprs
ptecisely those strings over
{a,b} that dies not end with the substring ,,abbn. yoqr
should include the proper dehnition design
ofthe finite-** uo,o*"tion, tmnsition
transition diagram. tabre and the

5. consider the regular gramnar defined by T:{ab}, N={s, A} with productions


L2+61
s_+bs,
a) Construct a NDI A equivalen ta the above given [4+4]
regular grammar.
b) Convert the NDF A into equivatent nfa.
Find all solutions of recurrence relation:
arr: 4a*y4a*-a+3n; Also, find the solution
initial conditions: a6:l and a1=2. with
7. state and describe briefly the chromatic l8l
of comprete bipartitie graph Kg.+ and
cycle C5. Define planar graph and show qyb.er
thai Ks ilnoi;;ffi;.i#i,
use Dijkstra's algorithm to find the length [4+41
ofshortest path form vertex ,a, to vertex ,2,
the following weighted graph.arso rrigfii;hi in
the shortest path in the graph.
t8I

.c.
9. Define spannrng T.*."
Td Minimum spanning
form the given graph below.
r"u the
' -----oTree. Find ru',r'l*rr spanning
urw minimum {nuxrlngilee
U+l+s]
AlnSclD

I
a 1

4p 3C 3g

I
1L
I0. Write short notes on:
[3x3]
a) Max flowand Min eut theorem
b) Cut edges and Cut vertices
c) Euler graptr
't*+
. TRTBHWANUNTVERSITY Exam, Back
TNSTITUTE OF ENGINEERING Level BE Full Marks 80
Examination Control Division Programme BCT, BEX Fass Marks 32
2076 Baisakh Year / Part II/u Time 3 hrs.

Subjeet: - Discrete Structure pf 550


Candidates are required to give their answers in their own words as far as practicable.
Attempt AU questions.
Thetigures inthe margin indicate Fall Marlw.
Assume suitable data if necessary.
1. a) 'A student in this class has not read the book" and *Everybhg in this class pqpsed the
fitst exam" implies that conclusion "someone who passed thifirst exam has not read
the boolc" ts]
b) Let Q(x,V) denote (x+y0). What is tnrth values of quantification 3yVxQ(x,y) and
VxIyQ(x,y). t3I
2. Show thac {aaC,(-A,vB)n(-ev-Ci} are unsatisfiability of the given set using
method of tableaux. Prove that " [f n is an integer and 3n+2 is od4 then n is odd." [s+3]
3. Use mathematical induction to prove that 7n+2*g2rrl is divisible by 57 for every non
negative irrteger n. t8l
4. Desigi a FSA kansition diagram that accepts the given set of string over {4b}, [4+4]
i) which starts with ab and ends with baa.
ii) where every b is followed by a.
5. Design a Grammm to generate Palindrome for Binary Number. Consider the right linear
Grammar N:{N, T, P, S}, where N:set of non-terminal = {A, n, S}, T=Set of
Terminal:{a, bo c}, and P consists of the following rules: {S +abA/bbBla, A-+aA/bB/b,
B-+baBiaaaA). Construct the NDFA equivalent to the given grammax. [4+4]
6. Find all the solutions ofrecurrence relation: t8l
an=3ar-1+4an-2+Jn with initial conditions ao=l and ag}.

7. Are Cr and C6 bipartite, explain with figures. If G is a connected planar simple graph with
E edges and V vertices, where V>3, then prove that ES 3V-6. L4+41
8. Define Binary tree, M-ary tree and Spanning tree. Find the minimal spanning tee from
the graph given below [3+5J
9. Use Dijkstra's Algorithm to find the length of shortest path from vertex a to vertex f in
&e following weighted Saph. Also highlight the shortest patlr/paths in graph.

2
c
10. Write short notes on: [4+4]
a) Regular Graph with example.
b) Max Flow and Min Cut Theorem
1 RII]H UVAN UNI V EII..(i I'}'Y Exam.
INSTTTI-J'TE OF ENGINEEI{IN G Level tsE Full Marks 80
Examinatian Control Division Programme i BEX, BCT Pass Marks -x2
2076 llhadra Year / Fart il/fi Time *1 ltrs.

Swbject:* I)iserste Sh'uctl"rre (CT SSi)


r' Candidates are required to give their answers in their o'*vn words as far as practicable.
/ Attempt4!!questions:
'/ Tne figures in the margin indicqte Fult!{urttq.
{ Assurne suitoble data f necesscry.

1. f .ise r*!*s of inference to show that th* hypothesis "lf you have password tlien yau can log
on to faceboq:k." "li'you can iog cin tc iace'ocok then you cantieate your page.,'n'If you
can crea{e .Vour page then you can post adl'efiisement ar ycili car; create an event." o'You
eamoi post advertisement or -/oil cannct create a:: event.'' Irnpll,the concLusion th?.t "Yo*
,-ic;rct have passv.,ord. "
l8l
a Ilefine Uiriversai and Exister{ial quantifiers with exampie. llse mathematicai ir:rluciir:n to
t-7 +" .., + (jn-2) -- n(3n -1"\ l2 forall rion-ncrg:itir,e inlcgers n.
pi"r-iv*tira.t 7 +.4
12+6J
state ccwerse, contrapositive and Inverse for tire conditional statements: "I will go for
sw-imming only if it is a su.nny day."
13l
4. Define satisfiablc aad unsaiisfial:le ionuuia. Draw Tableau tbr fbrrnutra set:
&={P^-+Q v E, P v-R, -(QvR}} [2+3 j
5, *i'i+ L ={we {4, b}*:w contain substring 'a'oa'}. write the regular expression
a language,
fcr L and design a Finite State Auiomaia that:;..;cepts the language L. Your Design should
include the proper eefinition ri F:init* State Automation, transition table and hansition
dlagram" t2+61
6. Consider the regular grammar

G: (N, T, P, o) where s
Set ofNon-Terminals, N: {o, A, B},
Set cf Terminals, T = {a, b}
Set of produetions, P = io'+aB, o'+bA, o-rl, A+aA, B-)aA, B-+a)
and starting symbol o.
Construct a Non-Deterministic Finite State Automata equivalent to the above given
reguiar grammer and convert this into equivalent DFA. t4+4]
't. Find all the solutions cf recurrence relaiion: ig]
a,, = 3&n-1 t- 4an-2+ 3n with iuitial conditions aa = I and ar:2.
State and Explain Handshaking Theorem with exampie. Describe Cycle and Complete
Bipartite Graphs along with their ehromatic numbers. [4+4]
9. Use Dijksira's algoiithrn to find the lengfh of sl:ortest Dath fiom vertex a to vertex e in the
follor.viirg weighted graph. AIso higldighi the sliortest patLrpaths ingpaph. tsl

tu
.l

I J
(J
A
+
o
'l
, l 15
-7
h

10. Define Spanning Tree and Minimum Spanning Tree with examples. Differentiate
between Eulerian and Hamiltonian Graphs with exanaples.
[4+4]
11. Write short notes on:
[4+4J
a) Max Flow and Min Cut Theorem
b) Cut Edges and Cut Yertices
a

21 TRIBHUVANIJNIVERSITY
INSTITUTE OF EIYGINEERING
Examination Comtrol Division
2075Ma

Candidates eErerwfu6d to give their answers in their own words as far as practicable.
Attempt All qw*timr"-
The figures i* {e wgin indieate fiull 4tIarks.
A ss ume suitMe fu if nece s sary.

1. Define the term Thutology, Contradiction and Logical Equivalences. Show that
-A -+ -B and. B-+ A are Logiiilly Equivalent. State the contrapositive and
inverse of ttm stffirt, "A positive integer is prime only if it"orui.u",
has no divisors other than I
and itself'. [3+Z+31
2. Show that the pmises "There is someone in this class who has been to pokhara.
Ey9rf91e u*mgoesto Pokhara visit the Sarankot. Therefore, someone in this class
visited the Smffiofi.ri - has
ISI
J. Use matheneticd ieduction to veri$r:' tgl
lz *22 +32 *42 +-:.*.....+(-l)(n+r)n2 -(*1)*n(n+l)i 2
4. a) State the futrneproperties of Regular Language.
t3l
b) Let L be tk sd of strings accepted Uy ff. FSA sho,nm below. Now conshuct a FSA
thataccephtheskings L* ={Xo.......X,|X,.......X" eL} tr t5l

5. i) Find the language L(G) overs, {a,b,c} generated by the grammer G rvitir production:
S+aSb, aS->Aa, Aab+c.
[4+4]
ii) trvrite a grarnmer that generates the string over {a,b} not ending with ab.
Find the solution of recurrence relation of a,, =58n_r -6?.n-, +3n+2, .rvith initial
condition
&o =Oar =l,andar=2.
t8l
Prove the theorem, "An undirected graph has ai even number of vertices of ocld
degree.,,
Describe complete graph and bipartite graph.
[3+s]
what is cluomatic number of K'K,.,, and cofor p ) 3, explain with suitable figure.
How Euler graph is different from Hamilton graph, explain? [5+3]
9 ' Use Dij kstra's algorithm to fincl the length of e shurtest path
from the vertices A to other
in the graph belolv.
tBl

10" rtrrite short notes on:


14+41
i) Mrur Flow and Min cut Theroem
ii) Plannar Graph

You might also like