You are on page 1of 4

THE OPEN UNIVERSITY OF SRI LANKA

DEPARTMENT OF ELECTRICAL AND COMPUTER ENGINEERING


BACHELOR OF SOFTWARE ENGINEERING

ECX 6240 Knowledge Engineering

Answers to this assignment should be sent by registered post to the following address or should be placed in the
relevant box provided at Block No. 12 of Colombo Regional Centre.

The Course Co-ordinator ECX 6240
Faculty of Engineering Technology
The Open University of Sri Lanka
Nawala, Nugegoda.

(Answers should be clear, and readable. Use A4 paper. Unclear, unreadable, copied and direct reproduction from the textbook
will not gain any points for the answers. Delayed submissions will count minus marks.)

Assignment 3 Submit on or before: 9
th
J une 2013

Answer all Questions.

Question 1 (21 marks)
(a) Translate the formula Q (given below) in first-order logic into natural English.
Q: (x) (y)( p)(Speak-language(x, p) Speak-language(y, p) Understand (x,y) Understand (y,x)

Predicates Speak-language and Understand are defined as;
Speak-language(x,p) x speaks the language p
Understand(x,y) x understand y

Please state your assumptions if there are any.

(b) Translate following declarative sentences into first-order logic
(i) Some Sri Lankan citizens live in Middle East
(ii) All Calculators contain batteries.

(x for all, y - there exists, - or, - and, - material implication)



Question 2 (24 marks)
Consider the following information:
Dilum likes only easy courses.
Electrical courses are not easy.
All Law courses are easy.
LW1201 is Law course. EC2330 is an Electrical course.

{Hint: Electrical course can be written as elec-course(x) }

(a) Write each sentence given above in first-order logic (FOL).

(b) Convert each FOL sentence into clausal form.

(c) Use resolution refutation to show that Dilum does not like EC2330.







Question 3 (15 marks)

(a) Given the MINIMAX search tree with the leaf values shown below, complete the values for
the nodes in the upper levels of the tree. What is the best value that the MAX player can obtain?
Assume N1 is a maximizing node.


N1
N2
N6 N5
N3
N4 N7
N8
N9
N10 N11 N12 N13 N14 N15
N16
N17 N18 N19 N20 N21 N22 N23 N24 N25 N26 N27 N28 N29 N30 N31

1 3 2 4 2 5 4 9 3 4 3 5 4 6 2 9
Figure 1

(b) In the MINMAX tree given as figure 1, specify which nodes would not be visited if the
alpha-beta pruning method is used.







Question 4 (40 marks)

The problem here is to estimate the level of risk involved in a software engineering project. For
simplicity we will consider only two inputs: project funding and project staffing.
The sets defined for project_funding are inadequate, marginal and adequate. The sets defined for
project_staffing are small and large.
Suppose our inputs are project_funding = 25% and project_staffing = 55%. Following example show
the calculation to get the fuzzy values for these crisp values by using the membership functions of the
appropriate sets.



25 0.5
25 0.2
25 0.0


55 0.1
55 0.7

If project funding is x% where x is the last 2 digits of your registration number and project staffing is
y% where y is the last 2 digits of your registration number reversed, find the fuzzy values for risk in
following rules ( =low(z), = normal(z), = high(z)).
(Note: Please use a graph paper and draw the diagram to scale) (30 marks)
Fuzzy Rules
1. If project_funding is adequate or project_staffing is small then risk is low.
2. If project_funding is marginal and project_staffing is large then risk is normal.
3. If project_funding is inadequate then risk is high.




Output graph for Risk is given below. After finding the fuzzy values for risk, illustrate how to defuzzify the
values to find a crisp value for risk. Calculation is optional. (10 marks)

You might also like