You are on page 1of 8

Questions on Heuristics for ZITE3109

(NOTE: some questions are easy, some are hard, some are ridiculously hard)

1. What does the term “heuristic” mean?


2. What are the two reasons for using heuristics in AI applications?
3. What makes heuristics fallible?
4. What is a domain-dependent heuristic?
5. What is an admissible heuristic?
6. How could you adapt the hill-climbing algorithm to find the minimum rather than
the maximum?
7. What heuristics could you use in the game of tic-tac-toe?
8. Describe how hill-climbing works.
9. What are the problems with hill-climbing?
10. Use hill-climbing to solve y = x2 + 3sin(2x). Start at x = 4 and use step = 1.0 to
begin with, then reduce the size of the steps as you approach the minimum. What
value for x gives the minimum value of y?
11. Why is dynamic programming sometimes called the forward-backward
algorithm?
12. Write an algorithm for solving a crossword puzzle using best-first search.
13. What is the time complexity of your algorithm, assuming c clues, and a dictionary
list of length w?
14. What is depth-first search and what its advantages and disadvantages?
15. In the graph below, ignore the arrows, and use a brute-force search to find the
most efficient route (lowest cost) between S and G.
16. Repeat the previous question using best-first search.
17. Repeat the previous question using the A* algorithm.
18. Repeat using dynamic programming.
19. Repeat using hill-climbing.
Questions on State space search for ZITE3109

1. A Hamiltonian path is one that visits each node of a graph once only. What are the
characteristics of a graph having such a path?
2. Draw a representation of the farmer, wolf, goat, and cabbage problem as a state space
graph. (The problem is stated below.)
3. Try breadth-first, depth-first, best-first and A*-search on the farmer, wolf, goat, and
cabbage problem and see which one is the most efficient.
4. Repeat Q3 for the bridge-crossing problem.
5. Solve the traveling salesman problem using nearest-neighbour search. Does it provide the
optimum solution?
6. Determine whether goal-driven or data-driven search would be preferable in each of
situations:
a. Diagnosing mechanical problems in a car.
b. You meet someone who claims to be your distant cousin with a common ancestor
whom you know of.
c. A program for examining sonar readings and distinguishing between a submarine a a
school of fish.
d. An expert system that will classify plants by genus, species, etc.

The Bridges of Königsburg problem

The farmer, wolf, goat, and cabbage problem

“The farmer wants to get his goat, wolf and cabbage to the other side of the river. His boat
isn't very big and can only carry him and either his goat, his wolf or his cabbage. Now.....if
he leaves the goat alone with the cabbage, the goat will gobble up the cabbage. If he leaves
the wolf alone with the goat, the wolf will gobble up the goat. When the farmer is present, the
goat and cabbage are safe from being gobbled up by their predators.
How does the farmer manage to get everything safely to the other side of the river?”

- from http://math.about.com/od/weeklyproblem/a/ps4.htm
The Bridge-crossing problem

“A group of four people has to cross a bridge. It is dark, and they have to light the path with
a flashlight. No more than two people can cross the bridge simultaneously, and the group
has only one flashlight. It takes different time for the people in the group to cross the bridge:
Annie crosses the bridge in 1 minute,
Bob crosses the bridge in 2 minutes,
Cecil crosses the bridge in 5 minutes,
Dorothy crosses the bridge in 10 minutes.”
A person cannot cross without the flashlight. When two people cross together, they travel at
the speed of the slowest person. What is the minimum time for them all to get safely across?

- based on the version at http://www.math.utah.edu/~cherk/puzzles.html

Traveling salesman problem


A
A B C D E
A 10 12 10 75
0 5 0
E B B 10 50 75 125
0
C 12 50 10 125
5 0
D 10 75 10 50
0 0
E 75 12 12 50
5 5
Table of distances between cities

D C

- from Luger, Artificial Intelligence.


Questions on Expert Systems for ZITE3109

1. Give an example of a simple rule. Label the antecedent and consequent of the rule.
2. How can an expert system make mistakes?
3. In an expert system, what is the purpose of
a) The inference engine?
b) The explanation facilities?
c) The user interface?
4. Describe the difference between an expert system and a conventional program using
simple examples.
5. What is forward chaining, and what are its disadvantages?
6. What is backward chaining?
7. Explain, using a simple example, how you might choose forward or backward chaining
given a problem.
8. Give an example of a set of rules that can lead to a conflict. List four ways in which a
conflict could be resolved.
9. What is metadata? Give examples of metadata that are relevant to conflict resolution in
expert systems.
Describe some advantages and disadvantages of expert systems over conventional programs.
Machine learning (symbolic) Questions

1. Describe briefly, using examples, the machine learning tasks of classification and
clustering.
2. Describe briefly how Decision Tree Induction works.
3. Discuss problems that can arise when using data with continuous attributes, and what
methods could be used to overcome such problems.
4. What is the purpose of tree pruning in decision tree classification?
5. A group of friends want to play tennis together, but only when the weather is just
right. They record what the weather conditions were for several days, and weather
they played on that day or not. They compile these data into Table 1. Using the ID3
classifier algorithm, show how a decision tree can be built from these data. Show all
steps, including computation of decision gain, and show the resulting tree.
6. After the friends have recorded their weather data, they meet on a day with these
characteristics: outlook = sunny, temperature = hot, humidity = normal, windy =
false. Using the tree you created in question 5, show if the friends play tennis, or show
that no conclusive answer can be reached
7. Explain briefly, with examples, what unsupervised learning is, and why it might be
useful.
8. Briefly describe the following types of clustering algorithms, giving examples:
partitioning, hierarchical, density-based, grid-based, model-based.
9. Explain, using examples, how the k-means clustering algorithm works. Compare and
contrast with the k-modes algorithm and discuss advantages and disadvantages of
both methods.
10. Explain, using examples, another clustering algorithm.
11. Given the data in Table 2, sketch the data, and cluster the data using the k-means
algorithm.
12. Repeat question 11 using another algorithm.

Table 2. Data for


Table 1. The weather.nominal data set
clustering

outlook temperature humidity windy play x y


sunny hot high FALSE no 2.6 5.4
sunny hot high TRUE no 2 3
overcast hot high FALSE yes 3.1 2
3.6 9.3
rainy mild high FALSE yes
4.2 6
rainy cool normal FALSE yes 5 8.8
rainy cool normal TRUE no
overcast cool normal TRUE yes
sunny mild high FALSE no
sunny cool normal FALSE yes
rainy mild normal FALSE yes
sunny mild normal TRUE yes
overcast mild high TRUE yes
overcast hot normal FALSE yes
rainy mild high TRUE no
Neural network Workshop

In this workshop, you have a choice of exploring some models of networks, or of checking
your own knowledge and what you have learned from the lecture and from your reading.
Choose between exercises or written questions:

PART 1 Exercises

Check out the demo, and do the tutorial at


http://www.eee.metu.edu.tr/~alatan/Courses/Demo/Hopfield.htm

PART 2 Written questions

Access some notes at http://www.shef.ac.uk/psychology/gurney/notes/l5/l5.html, or use any


other resources you prefer. Choose some of these questions (your favourite ones?) and
attempt to answer them:

1. What is the main structural difference between the Hopfield net and the Multilayer
Perceptron net?
2. Why does the Hopfield net use an iterative process for determining its response to an
input activation?
3. Does the response of the Hopfield net always converge to a stable output?
4. What is the difference between supervised and unsupervised learning?
5. Can a single perceptron be trained to implement the XOR function? Give reasons for
your answer.
6. Using the perceptron network in the diagram below, and inputs X1 = 0.7 and X2 =
0.3, show what the output will be, assuming that each neuron uses a sigmoid
activation. Assume random values for the weights, and ignore thresholds.
7. Using the perceptron network in the diagram below, show the weight values after one
iteration of the backpropagation algorithm using the training example X1 = 0.7, X2 =
0.3, output = 1.0. Assume random starting values for the weights, and ignore
thresholds.
8. Using the perceptron network in the diagram below, show the weight values after one
complete epoch of the backpropagation algorithm using the XOR function. Assume

X
1 w
1_1
random starting values for the weights, and ignore thresholds.

w 1
1_2 w
3_1
w2_1 w3
3_2
X
2 w 2
2_2
Questions on Fuzzy Systems for ZITE3109

1. What is Fuzzy Logic and why would you use it?


2. What is a Fuzzy set and why is it useful?
3. What is a membership function?
4. Sketch a membership function for a variable representing the quality of food at a
restaurant.
5. What is fuzzy inference and how does it relate to expert systems?
6. Using the definition of the fuzzy system below, if the funding variable is 35% and the
staffing variable is 60%, estimate the membership in each category.
7. Using the values from the previous question, draw what the output function will look
like.
8. Using the values from the previous question, estimate the percentage risk for the
project.

A fuzzy system
(from Negnevitsky, Artificial Intelligence)

A software consultant estimates project risk based on funding and staffing. The membership
functions are as follows. All variables are expressed as percentages.

1.00 1.00
0.90 0.90
0.80 0.80
0.70 0.70
0.60 0.60 Small
0.50 Inad 0.50
0.40 Marginal 0.40
Large
0.30 0.30
Adequate
0.20 0.20
0.10 0.10
0.00 0.00
0.00 20.00 40.00 60.00 80.00 100.00 0.00 20.00 40.00 60.00 80.00 100.00

Project funding Project staffing


1.00
The rules used are: 0.90
0.80
0.70
IF project funding is adequate OR project 0.60 Low
staffing is small THEN risk is low 0.50
Normal
High
0.40

IF project funding is marginal AND project 0.30


0.20
staffing is large THEN risk is normal 0.10
0.00

IF project funding is inadequate THEN risk is 0.00 20.00 40.00 60.00 80.00 100.00

high Project risk

You might also like