0% found this document useful (0 votes)
43 views23 pages

B.Tech & M.Tech Soft Computing Exams

Uploaded by

Mooom
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)
43 views23 pages

B.Tech & M.Tech Soft Computing Exams

Uploaded by

Mooom
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/ 23

Total No. of Pages 2 Roll no…………….

VIth SEMESTER

B.Tech.

MID-TERM EXAMINATION (March-2023)

COURSE CODE: EC 320 COURSE TITLE: Soft Computing

Time: 1:30 Hours Max. Marks: 25


Note: All questions are compulsory.
Assume suitable missing data, if any.

Q.1 (a) Illustrate the use of predicate logic to represent the knowledge with
suitable example.
(b) Explain the depth-first search for the graph shown in Figure 1. Taking
starting node as D

A
B D

C
E
F
Figure 1
[2+3][CO1]
Q.2 (a) Explain the AO* algorithm. Using suitable example show how the AO*
algorithm is used for problem reduction.
(b) For the graph shown in Figure 1, let the start and goal node as D and F,
respectively, and the heuristics of each node as h(A), h(B), h(C), h(D), h(E)
and h(F) as 10, 5, 6, 20, 3, 0, respectively. Explain the working of the hill
climbing algorithm for this scenario.
[3+2][CO1]
Q.3 (a) Write and explain the backpropagation algorithm.
(b) Consider the network given below with input x = (x1, x2). Each neuron
has the rectified linear unit h(z)=max(0, net) as the activation function. Let
the input to the network be x = (2, 4) and d = 1 be the desired output. The
1
loss function is given as J  ( y  d )2 . Compute the loss after the first forward
2
pass.
b1 = 0

x1 w11 = -1
1 b3 = 0

y
3

x2
2
w22 = -2

b2 = 0
Figure 2
[3+2][CO2]
Q.4 A perceptron is needed to classify two sets of patterns given as:
Class (1): T = [-1, -1]’, U = [-1, 1]’, target value −1
Class (2): X = [1, 1]’, Y = [1, -1]’, target value 1
Choose learning rate ‘η’ as 0.5 and get the boundary line that separates the
two classes. Take initial weight as [1 1]’ and activation function as signum
with output as 1 for ‘net’ greater than zero and -1 for ‘net’ less than and
equal to zero.
[5][CO2]
Q.5 Find the weight matrix that is needed to store a fundamental pattern
(memory) given by the vector A = [1 1 1 1]T in a four-node binary Hopfield
network. Also, determine energy associated with the stored pattern and the
pattern given by P = [-1 1 1 1]T. Take bias and external input to the network
as zero.
[5][CO2]
Total No. of Pages 3 Roll no…………….
Ist SEMESTER, M.Tech. (SPD)
END TERM EXAMINATION (December-2023)

SPD5407, Soft Computing

Time: 3:00 Hours Max. Marks: 40


Note: All questions are compulsory.
Assume suitable missing data, if any.

Q.1 Evaluate the weight matrix that is needed to store the following
associative patterns (Ai with Bi for i = 1, 2, 3) in a bidirectional
associative memory (BAM).
A1  [1  1  1  1  1]T B1  [1  1  1  1  1 1]T
A2  [1  1  1  1 1]T B2  [1  1  1  1  1  1]T
A3  [1  1 1  1  1]T B3  [1  1 1 1  1 1]T
If an input A1 = [1 1 -1 -1 -1]T, is applied at the BAM. Find where the
output of the designed BAM will converge.
[8][CO1, 2]
Q.2 (a) A single layer perceptron (SLP) is needed to classify two set of
patterns located in a 2-dimensional vector space for the following
problems:
Problem Set I Set II
(i) A=[-2 2]T, B=[1 1]T, C=[2 -2]T D=[2 2]T, E=[-1 -1]T
(ii) A=[1 1]T, B=[-1 -1]T C=[1 -1]T, D=[-1 1]T
(iii) A=[2 2]T, B=[1 1]T, C=[-1 1]T D=[-1 -1]T

Identify and classify which of these problems can be solved by using a


SLP. If not give reason?
(b) Let X = {1, 2, 3}, Y = {1, 2}, Z = {1, 2} are three crisp set. Form
fuzzy relations ‘R’ on X Y and ‘S’ on Y  Z such that membership
grades of these relations are as follows:
R ( x, y)  e( x y ) , S ( y, z)  e y  z
2

Find the relation T  R  S using max min and max product


composition.
[4+4=8][CO1, 3]
Q.3 (a) Explain the following with an example related to fuzzy set theory:
(i) Core of a set, (ii) Crossover point, (iii) Law of excluded middle.
(b) Explain min-max method of fuzzy implication with a suitable
example.
(c) The membership function of a fuzzy set ‘A’ is assumed to follow a
Gaussian distribution with mean m = 100 and standard deviation 𝜎 =
10. Gaussian membership function distribution is expressed as
follows:
1
 A ( x)  1  xm 
2
 
2  
e
Find α-cut, A0.5
[3+3+2=8][CO3]
Q.4 (a) In Mamdani approach of fuzzy implication, let us assume that two
rules are getting fired for a set of inputs. The combined fuzzified
output considering these two fired rules is shown in Fig. 1. Find the
defuzzified value using centre of sum, first of maxima and mean of
maxima methods.
μ(x)

0.7

0.5

0 4 6 7 9 11 13 15 x
Fig. 1.
(b) A binary-coded genetic algorithm (GA) is used to optimize a
function f(x). The optimized value of ‘f’ represented by a binary string
is obtained as: 1000110100. The range in which f can varies is of (1,
20). The real value of f is found to be equal to
[6+2=8][CO3, 4]
Q.5 (a) Suppose a GA uses chromosomes of the form n = abcdef with a
fixed length of six genes. Each gene in n can have value between 0
and 9. Let the fitness of individual ‘n’ in the population be evaluated
by the fitness function to be maximized as:
F (n)  (a  b)  (c  d )  (e  f )
Let the initial population consist of four individuals chromosomes as
given in table below. Fill in the rest of the tables and comment on the
result obtained.

String String Fi(n) Fi No. Mating


No.  Fi Surviving Pool
1 123456
2 989898
3 245245
4 636363

Mating Mate Crossover New New Fi(n)


Pool point Population

(b) Explain the following related to Genetic algorithm


(i) Fitness function
(ii) Selection
[6+2=8][CO4]

-----END-----
Total No. of Pages 2 Roll no……………. Q.5 (a) Consider a (Kohonen self-organizing map) network as shown in Fig. 1.
Ist SEMESTER, M.Tech. (SPD) The connections form two weight column vectors: w1 and w2. Given the
initial weight vectors as w1 = (0, 1, 1); w2 = (1, 1, 0) and the training input
MID-TERM EXAMINATION (September, October-2023) vectors as: x1 = (0, 0, 1); x2 = (0, 1, 0); x3 = (1, 0, 0). Calculate the updated
weight vectors resulting from training with each successive training input
SPD5407, Soft Computing vector and enter them in a table given below. Use a constant learning rate, α
= 1.0, and assume a neighbourhood of zero (only one weight vector can be
Time: 1:30 Hours Max. Marks: 25
updated).
Note: All questions are compulsory.
Assume suitable missing data, if any. w11
x1 1
w12 w21
Q.1 (a) Design a NAND gate with Mc Culloch - Pitts neuron.
.
w31
(b) An activation function is expressed as𝑦(𝑥) = 𝑒 , ∀𝑥, where μ, σ
represent some positive scalar values. Find the range of variation of y.
x2
[3+2][CO1]
w22
Q.2 (a) Assume a network with single neuron having four input with the initial x3 2
weight vector as W = [1 -1 0 0.5]T, needs to be trained using set of three w32
input vectors as x1 = [1 -2 1.5 0]T, x2 = [1 -0.5 -2 -1.5 ]T and x3 = [0 1 -1
Fig. 1.
1.5]T, taking learning rate = 1, find the weight vector after one Epoch of
training the neuron through Hebbian learning. (Assume neuron to be bipolar Table 1
binary) w1 w2
(b) Discuss about the role of learning rate in different learning rules After training with x1
[3+2] [CO1, 2] After training with x2
After training with x3
Q.3 (a) Explain how back propagation algorithm can be used to solve Ex-OR
problem.
(b) Find the Euclidean distance between two points in 4-D space, namely A
(b) Explain the significance of momentum in training feed-forward neural
and B having the coordinates (2, 1, 2, 2) and (4, 3, 4, 4).
network.
[3+2][CO1, 2]
[3+2][CO1, 2]

Q.4 Store a pattern represented by a vector A= [1, 1, 1, -1]’ in a Hopfield net.


Derive the output at steady state of this net when it is excited by an input
vector given as D = [-1 -1 -1 -1]’. Also, discuss about the stability of this
network.
[5][CO1, 2]
Q.5 (a) Consider a (Kohonen self-organizing map) network as shown in Fig. 1. Total No. of Pages 2 Roll no…………….
The connections form two weight column vectors: w1 and w2. Given the Ist SEMESTER, M.Tech. (SPD)
initial weight vectors as w1 = (0, 1, 1); w2 = (1, 1, 0) and the training input
vectors as: x1 = (0, 0, 1); x2 = (0, 1, 0); x3 = (1, 0, 0). Calculate the updated MID-TERM EXAMINATION (September, October-2023)
weight vectors resulting from training with each successive training input
vector and enter them in a table given below. Use a constant learning rate, α SPD5407, Soft Computing
= 1.0, and assume a neighbourhood of zero (only one weight vector can be
Time: 1:30 Hours Max. Marks: 25
updated).
Note: All questions are compulsory.
w11 Assume suitable missing data, if any.
x1 1
w12 w21
Q.1 (a) Design a NAND gate with Mc Culloch - Pitts neuron.
w31 .
(b) An activation function is expressed as𝑦(𝑥) = 𝑒 , ∀𝑥, where μ, σ
x2 represent some positive scalar values. Find the range of variation of y.
[3+2][CO1]
w22
x3 2 Q.2 (a) Assume a network with single neuron having four input with the initial
w32 weight vector as W = [1 -1 0 0.5]T, needs to be trained using set of three
input vectors as x1 = [1 -2 1.5 0]T, x2 = [1 -0.5 -2 -1.5 ]T and x3 = [0 1 -1
Fig. 1.
1.5]T, taking learning rate = 1, find the weight vector after one Epoch of
Table 2 training the neuron through Hebbian learning. (Assume neuron to be bipolar
w1 w2 binary)
After training with x1 (b) Discuss about the role of learning rate in different learning rules
After training with x2 [3+2] [CO1, 2]
After training with x3
Q.3 (a) Explain how back propagation algorithm can be used to solve Ex-OR
problem.
(b) Find the Euclidean distance between two points in 4-D space, namely A
(b) Explain the significance of momentum in training feed-forward neural
and B having the coordinates (2, 1, 2, 2) and (4, 3, 4, 4).
network.
[3+2][CO1, 2]
[3+2][CO1, 2]

Q.4 Store a pattern represented by a vector A= [1, 1, 1, -1]’ in a Hopfield net.


Derive the output at steady state of this net when it is excited by an input
vector given as D = [-1 -1 -1 -1]’. Also, discuss about the stability of this
network.
[5][CO1, 2]
Name _____________ Roll No…………………
SEMESTER- VI B.Tech. (ECE)
CLASS TEST-1 (SET-A) (March. 2022)

EC-320 SOFT COMPUTING


Time: 1 Hour Max. Marks: 20
Note: Answer all questions. Assume suitable missing data, if any.

1. The depth first search traversal order of the graph shown in Figure 1 is. (Take starting node as A)

(1)

A
B D

C
E
F

Figure 1

Ans. _________________________________________________________________________________________

2. The breadth first search traversal order of the graph shown in Figure 1 is. (Take starting node as F).
(1)
Ans. _________________________________________________________________________________

3. What is the end node starting from node ‘U’ in the graph shown in Figure 2 for the hill climbing
algorithm?
(1)
S

V W X
T
P Y
U
Objective Function

Q R

State Space

Figure 2

Ans. __________________________________________________________________________________________
4. The best first search traversal order of the graph shown in Figure 3 is. (Take start and goal node as S
and G, respectively.)
(1)

Figure 3

Ans. ________________________________________________________________________________________
5. The A* search traversal order of the graph shown in Figure 3 is. (Take start and goal node as S and G,
respectively.)
(1)

Ans. _________________________________________________________________________________

6. Which search strategy is also called as blind search?


(0.5)

Ans. _________________________________________________________________________________

7. What is the main task of a problem-solving agent?


(0.5)
a) Solve the given problem and reach to goal

b) To find out which sequence of action will get it to the goal state

c) Both A and B

d) None of the Above

8. Depth-First Search is implemented in recursion with _______ data structure (0.5)

a) LIFO

b) FIFO

c) FILO

d) LILO
9. Which data structure conveniently used to implement BFS?
(0.5)
a) Stacks

b) Priority Queues

c) Queues

d) None of the Above

10. Greedy search strategy chooses the node for expansion in


(0.5)
a) Shallowest

b) The one closest to the goal node

c) Minimum heuristic cost

d) Deepest

11. What is disadvantage of Greedy Best First Search?


(0.5)
a) This algorithm is neither complete, nor optimal.

b) It can get stuck in loops. It is not optimal.

c) There can be multiple long paths with the cost ≤ C*

d) may not terminate and go on infinitely on one path

12. An AI system is composed of?


(0.5)
a) Agent

b) Environment

c) Both A and B

d) None of the Above

13. Which instruments are used for perceiving and acting upon the environment?
(0.5)
a) Sensors and Actuators

b) Sensors

c) Perceivers

d) Perceivers and Sensor

14. What is not represented by using propositional logic?


(0.5)
a) Objects

b) Relations

c) Both Objects & Relations

d) None of the Above


15. Who initiated the idea of Soft Computing
(1)
a) Charles Darwin

b) Lofti A Zadeh

c) Rechenberg

d) Mc_Culloch

16. Which search strategy is also called as blind search?


(0.5)
a) Uninformed search

b) Informed search

c) Simple reflex search

d) All of the mentioned

17. Which search is implemented with an empty first-in-first-out queue?


(0.5)
a) Depth-first search

b) Breadth-first search

c) Bidirectional search

d) All of the mentioned

18. When breadth-first search is optimal?


(0.5)
a) When there is less number of nodes

b) When all step costs are equal

c) When all step costs are unequal

d) None of the mentioned

19. Which algorithm can solve any kind of problem?


(0.5)
a) Depth-first search

b) Breadth-first search

c) Bidirectional search

d) None of the mentioned

20. Which search implements stack operation for searching the states?
(0.5)
a) Depth-first search

b) Breadth-first search

c) Depth-limited search

d) None of the mentioned


21. Which search is complete and optimal when h(n) is consistent?
(0.5)
a) Depth-first search

b) Breadth-first search

c) Both Best-first & Depth-first search

d) A* search

22. Which is used to improve the performance of heuristic search?


(1)
a) Quality of nodes

b) Quality of heuristic function

c) Both Best-first & Depth-first search

d) A* search

23. When will Hill-Climbing algorithm terminate?


(0.5)
a) Stopping criterion met

b) Global Min/Max is achieved

c) No neighbor has higher value

d) All of the mentioned

24. What are the main cons of hill-climbing search?


(0.5)
a) Terminates at global optimum & Does not find optimum solution

b) Terminates at local optimum & Does not find optimum solution

c) Fail to find a solution

d) Does not find optimum solution & Fail to find a solution

25. Hill-Climbing approach stuck for which of the following reasons?


(1)
a) Local maxima

b) Ridges

c) Plateau

d) All of the mentioned

26. Translate the following statement into predicate logic. “For every a, if a is a philosopher, then a is
a scholar”
(1)
a) ∀ a philosopher(a) scholar(a)

b) ∃ a philosopher(a) scholar(a)

c) Both A and B

d) None of the Above


27. First Order Logic is also known as ___________
(0.5)
a) First Order Predicate Calculus

b) Lower Order Calculus

c) Quantification Theory

d) All of the mentioned

28. Which is created by using single propositional symbol?


(0.5)
a) Complex sentences

b) Atomic sentences

c) Composition sentences

d) None of the mentioned

29. How many proposition symbols are there in artificial intelligence?


(0.5)
a) 1

b) 2

c) 3

d) 4

30. What is the logical translation of the following statement? "None of my friends are perfect."
(1)
a) ∃x ( F ( x ) ∩ ¬P ( x ) )

b) ∃x ( ¬F ( x ) ∩ P ( x ) )

c) ∃x ( ¬F ( x ) ∩ ¬P ( x ) )

d) ¬∃x ( F ( x ) ∩ P ( x ) )

**********************END*************************
Name _____________ Roll No…………………
SEMESTER- VI B.Tech. (ECE)
CLASS TEST-2 (SET-A) (March. 2022)

EC-320 SOFT COMPUTING


Time: 1 Hour Max. Marks: 20
Note: Answer all questions. Assume suitable missing data, if any.

1
1. Consider a two input neuron as shown in figure 1 with activation function f (v) = . Let the
1 + e −2 v
inputs be [-1, 1] and the weights are [0.1, 0.5] respectively. The output of the neuron is 0.8. The value
of the bias b1 is
(2)

x1 = -1 b1 = ?
v1 f(v1) =0.8
Ʃ f(.)

x2 = 1
Figure 1

Ans. _________________________________________________________________________________________

2. Consider a fully connected feedforward network with one hidden layer. The network takes the input of
vector with dimensions [1000 X 1] and consists of 50 hidden neurons. What are the total number of
connections between the input and the hidden layer?
(a) 5000 (b) 5100
(c) 50000 (d) 1005
(1)
Ans. _________________________________________________________________________________

3. Consider four corners of a unit square where each corner can be coloured by either red or blue. Out of
the 16 possible combinations, how many combinations to separate corners with the same colours are
not linearly separable?
(a) 1 (b) 2
(c) 4 (d) 14
(1)
Ans. __________________________________________________________________________________________

4. Consider the perceptron in two dimensions: h(x) = sign(wTx) where w = [ w0 , w1 , w2 ] and


x = [ x1 , x2 , − 1] . The regions on the plane where h ( x ) = + 1 and h ( x ) = − 1 are separated by a line.
If we express this line by the equation=
x2 ax1 + b , then a and b are
(a) a = w1/w2 and b = w0/w2 (b) a = -w1/w2 and b = -w0/w2
(c) a = -w0/w1 and b = w2/w1 (d) a = -w0/w1 and b = -w2/w1
(2)
Ans. ________________________________________________________________________________________
5. Consider the network given below with input x = (x1, x2). Each neurons has the rectified linear unit
h(z)=max(0, net) as the activation function. Let the input to the network be x = (2, 2) and d = 1 be the
1
desired output. The output unit is linear with loss function=
J ( y − d ) 2 . Compute the loss after the
2
first forward pass.
(2)

b1 = 0

x1 w11 = -1
1 b3 = 0

y
3

x2
2
w22 = -2

b2 = 0

Figure 2

Ans. _________________________________________________________________________________

6. Consider a set of data points x ∈  as given in the figure below.

-2 -1 0 1 2 3
The data points given are not linearly separable in the input space. If we transform the input data into a
higher dimension feature space using φ (⋅) function such that φ :  →  2 and defined as φ ( x) = ( x, x 2 ).
Choose the correct statements from the options.
(a) The feature space is not linearly separable
(b) The feature space is linearly separable
(c) There exist only a single hyperplane which can classify the data points in feature space
(d) Multiple hyperplane exists which can classify the data points in feature space
(1)

Ans. _________________________________________________________________________________

7.
(2)

Ans. _________________________________________________________________________________
8.

(2)

Ans. _________________________________________________________________________________

9.

(1)

Ans. _________________________________________________________________________________

10.

(1)

Ans. _________________________________________________________________________________

11.

(1)

Ans. _________________________________________________________________________________
12.

(1)

Ans. _________________________________________________________________________________

13.

(1)

Ans. _________________________________________________________________________________

14.

(1)

Ans. _________________________________________________________________________________

15. Euclidean distance between two points in 4-D space, namely A and B having the coordinates (1, 1, 2,
2) and (3, 3, 4, 4) is

(a) 6 (b) 4
(c) 9 (d) 16
(1)

Ans. _________________________________________________________________________________

**********************END*************************
Name _____________ Roll No…………………
SEMESTER- VI B.Tech. (ECE)
CLASS TEST-3 (May 2022)
EC-320 SOFT COMPUTING
Time: 1 Hour Max. Marks: 20
Note: Answer all questions. Assume suitable missing data, if any.
1.

(2)

2.

(2)

3. 4.

(1)

(1)
5.

(1)
6.

(1)
7. For the given membership function as shown in Fig. below determine the defuzzified
output value using Centroid (centre of gravity) method.

Figure 1

(2)
ANS:_________________________________________________

8. For the given membership function as shown in Figure 1 determine the defuzzified
output value using first of maxima method.
(1)
ANS:___________________________________________

9. For the given membership function as shown in Figure 1 determine the defuzzified
output value using mean of maxima method.
(1)
ANS:________________________________
10.

(1)
11.

(1)
12.

(1)
13.

(2)
14.

(1)
15.

(2)
ANS:

**********************END*************************
Total no. of Pages: 2 Roll no….………….………
VIth SEMESTER
B.Tech.
END TERM EXAMINATION (May-2023)
EC320 (Soft Computing)

Time: 03:00 Hours Max. Marks: 50


Note : All questions carry equal marks.
Assume suitable missing data, if any.

Q.1 (a) List and explain in brief various heuristic search algorithms used
in artificial intelligence.
(b) For the graph shown in Figure 1, let the start and goal node as S
and G, respectively, and the heuristics of each node as h(S), h(A),
h(B), h(C), h(D) and h(G) as 5, 3, 4, 2, 6, 0, respectively. Explain the
working of A* search algorithm for this scenario.

2 5
D
A
1 3
1 2
C 4
S
10 G

Figure 1
[5+5=10][CO1]
Q.2 (a) Assume a network with single neuron having four input with the
initial weight vector as W = [1 -1 0 0.5]T, needs to be trained using set
of three input vectors as x1 = [1 -2 1.5 0]T, x2 = [1 -0.5 -2 -1.5 ]T and
x3 = [0 1 -1 1.5]T, taking learning rate =1, find the weight vector after
one Epoch of training the neuron through Hebbian learning. (Assume
neuron to be bipolar binary)
(b) Explain in detail the architecture and working of Bi-directional
associative memory.
[5+5=10][CO2]
Q.3 Explain the following related to fuzzy set theory:
(a) Support of a set, (b) Crossover point, (c) α-cut and strong α-cut,
(d) Intersection and union of two sets and (e) Law of contradiction.
[2*5=10][CO3]
Q.4 (a) The fuzzy sets P and Q are defined on X as follows.
µ(x) x1 x2 x3 x4 x5
P 0.1 0.2 0.7 0.5 0.4
Q 0.9 0.6 0.3 0.2 0.8
Find the following.
(i) P0.2 and Q0.3 (ii) ( P Q)0.6 (iii) ( P P )0.8 (iv) P  Q
(b) Explain Mamdani method of fuzzy implication with a suitable
example.
[2*5=10][CO3]
Q.5 (a) Table below shows a population of four strings. Assuming that the
string represents a binary encoding of a number ‘n’, and that the
fitness function is given by Fi=100/n, fill in the rest of the tables
String String n Fi Fi No. Mating
No.  i Surviving Pool
F

1 10111 23
2 00111 7
3 01001 9
4 01010 10

Mating Mate Crossover New n New Fi


Pool point Population

(b) Explain the following related to Genetic algorithm


(i) Crossover
(ii) Encoding
[6+4=10][CO4]

You might also like