#Discrete
#Discrete
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
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]
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*^
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
.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.
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.
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