CC6052 Week 12 slides

28
Week 12 Other intelligent systems 1

Transcript of CC6052 Week 12 slides

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 1/56

Week 12

Other intelligent systems

1

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 2/56

   T   h  e

   d   i  s  c   i  p   l   i  n  e  s  o   f   A   I   (   t

   h  e

  r  o  o   t  s   )  a  n   d   t   h  e

  a  p  p   l   i  c  a   t   i  o  n  s

   S  o  u  r  c  e  :   T  u  r   b  a  n

   (   2   0   0   1   )

2

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 3/56

This week

Last week – expertise and expert systems

Overview of concepts and technologies being used in the

development of intelligent systems

(Artificial) Neural Networks

Genetic algorithms

Fuzzy logic

Intelligent agents

Game theory

Brief introduction to the concepts, and how these ideas

are being applied in MSS contexts 3

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 4/56

Artificial Neural Networks

4

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 5/56

Neural networks - introduction

 Artificial neural networks (ANN) 

◦ system of programs and data structures

◦ “imitates” the operation of the human brain

(as so many new technologies are said to do...)

◦ theoretically involves many parallel processors  

◦ in practice, neural networks are often simulated  

5

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 6/56

Neural network is initially trained  

i.e. fed large amounts of training data

(inputs produce a known set of outputs)

Neural network uses rules learned  from patterns

in the data to construct a hidden layer  of logic

Hidden layer(s) processes inputs, classifying according

to the experience of the model

Neural networks - introduction

6

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 7/56

Neural networks - structure

Input layer   Hidden layer   Output layer  

Income 

Debt 

 Age 

Residence 

Source: Laudon & Laudon, 2004 

Goodcredit risk 

Bad credit

risk 

7

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 8/56

Machine learning

Supervised mode

o uses inputs for which desired outputs  are known e.g. a historical set of loan applications

o difference between desired  and actual  output used to correct weights  on neural network

Unsupervised mode

o  only the inputs  are known!

o the network is self-organising  

o  outputs derived by the network may not be meaningful to the user...

For artificial neural networks identifying tanks…or not!

See: http://neil.fraser.name/writing/tank/ 

8

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 9/56

Classification problem

Man on the left

does  match

Neural networks  – template matching (1)

based on Aleksander & Morton (1991)

9

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 10/56

Classification problem

Man on the left

does not  match 

based on Aleksander & Morton (1991)

Neural networks  – template matching (2)

10

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 11/56

Classification problem

 Does  the man on the left

match the template?

based on Aleksander & Morton (1991)

Neural networks  – template matching (3)

11

What  are we trying to match?

Smile

Eyes

Hair 

Tie

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 12/56

Neural networks - benefits

Good at some tasks that people are good at  

Suitable for solving unstructured & semi-structured problems  

Pattern recognition , even from incomplete information

Classification , abstraction and generalisation   In theory, processing can be in parallel for faster computations

 Ability to adapt to new data: learning  

Exhibit fault-tolerant behaviour 

12

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 13/56

Neural networks - limitations

Not good at tasks that people are not good at  

Not suitable for basic data processing or conventional

arithmetic calculations (conventional computer system better)

Need a vast amount of data

Might not ‘learn’ what is expected  

Limited to classification and pattern recognition  

Lack of explanatory capabilities Not economically viable  for parallel processing

13

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 14/56

Neural networks - applications

 Applications of neural networks include: ◦ oil exploration data analysis

◦ weather prediction

◦ interpretation of nucleotide sequences in biology labs

◦ identifying credit card fraud by spotting changes in patternsof customer spending behaviour, e.g. Visa

◦ credit card approval

◦ bankruptcy prediction

Optical Character Recognition (OCR)◦ speech recognition

◦ stock market predictions

14

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 15/56

Genetic Algorithms

15

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 16/56

Genetic algorithms - introduction

Genetic algorithms also called 

◦ adaptive computation 

evolutionary programming   problem-solving techniques

conceptually based adaptation to environment

process of evolution

16

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 17/56

programmed to work the way populations solve problems:

changing and re-organising their component parts using

reproduction

crossover  mutation

solutions alter and combine

worst ones are discarded  

better ones go on to produce even better  solutions 

Genetic algorithms - introduction

17

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 18/56

Genetic algorithms - a simple example (1)

Example based on the board game ‘Mastermind’ 

Imagine we are trying to guess a 6-digit binary number 

The number that has been set by our opponent is:001010

but we don’t know this 

18

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 19/56

We make guesses and get scores for what is right

e.g. 111101 scores 1 because one digit is correct,

but we don’t know which  one

Then we guess again and get another score… 

… how many guesses before we get it right? 

There are 64 possible combinations… 

With random guessing:

average 32 attempts to guess the right number…  but it could take the full 64 guesses

How it could be done using genetic algorithms …? 

Genetic algorithms - a simple example (2)

19

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 20/56

The secret number we are trying to guess is 001010

With GA approach, we present random guesses, say◦  A – 110100 (scores 1)

◦ B – 111101 (scores 1)

◦ C – 111111 (scores 2)◦ D  – 000000 (scores 4)

◦ E  – 011011 (scores 4)

◦ F  – 101010 (scores 5)

◦ G – 010101 (scores 1)

Discard the lowest scoring guesses, A, B, C and G

Now we have D, E and F to use

Genetic algorithms - a simple example (3)

20

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 21/56

Try splits... first 2 digits from one parent , last four digits from the other 

D and E

H – 010000 (scores 3)

I  – 001011 (scores 5)

E and F

J - 011010 (scores 4) 

K- 101011 (scores 4)

D and F

L  – 100000 (scores 4) 

M  – 001010 (scores 6)  –  !

Genetic algorithms - a simple example (4)

21

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 22/56

Genetic algorithms - terminology

Set of instructions performed to solve a problem◦ ‘algorithm’  

Each iteration◦ ‘generation’  

Score calculated◦ ‘fitness function’  

22

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 23/56

Methods used to reproduce (generate new offspring)

are genetic operators and include:

splitting and mating is called crossover   some genes from "mother", some genes from "father"

unique individual created with some inheritance from parents

(sometimes twins might occur  – same pattern of 0s and 1s)

more rarely might also introduce mutation  

(randomly changing one of the digits)

Genetic algorithms - applications

23

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 24/56

Genetic algorithms - applications

Genetic algorithms have been applied to 

◦ Large-scale combinatorial mathematical programming problems

◦ Dynamic process control

◦ Scheduling problems and production planning

◦ Transportation and routing problems◦ Optimisation of complex machine design

e.g. General Electric used GA to optimise jet turbine aircraft engine

design (each design change required changes in up to 100 variables)

◦ Producing police sketches of criminals

24

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 25/56

Fuzzy Logic

25

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 26/56

Fuzzy logic ◦  based on "degrees of truth” 

◦ rather than "true or false" (1 or 0) Boolean logic

Can everything be described in binary terms? 

◦  A philosophical question...

Yes? (true)

No? (false)

Sometimes? Maybe? It depends... ( fuzzy )

“Are we nearly there yet...?” 

the answer could be just yes  or  no ...

...or it depends whether we have just left, are half-way

there, or expect to arrive in 5 minutes...

Fuzzy logic - introduction

26

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 27/56

Fuzzy logic - introduction

In practice, data in use might be uncertain some state between true and false

Fuzzy logic

allows 1 (true) and 0 (false) as extreme cases of truth

encompasses various states of truth in between

e.g. cold, cool, warm, hot might have overlappingtemperature ranges…

room temperature is ‘cool’ is between 50ºF and 70ºF,so we can definitely say 60ºF - 67ºF is ‘cool’ 

but 70ºF is on the cusp between warm and cool (like the Grand Old Duke of York…) 

27

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 28/56

“If temperature cool or cold and humidity low while outdoor wind high

and outdoor temperature low, raise heat and humidity in the room.” 

- example taken from Laudon & Laudon (2004)

0.75 

0.5 

0.25 

0 40  50  60  70  80  90  100 

Cold  Warm Cool Norm 

Hot 

temperature

ce

r

t

a

i

n

t

y

Upper 

limit

ce

t

a

i

n

t

y

28

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 29/56

Fuzzy logic - example

0.75 

0.5 

0.25 

0 40  50  60  70  80  90  100 

Cold  Warm Cool Norm 

Hot 

temperature

ce

r

t

a

i

n

t

y

Upper 

limit

ce

t

a

i

n

t

y

70o F degrees is the norm:

a comfortable temperature 29

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 30/56

Fuzzy logic - example

0.75 

0.5 

0.25 

0 40  50  60  70  80  90  100 

Cold  Warm Cool Norm 

Hot 

temperature

ce

r

t

a

i

n

t

y

Upper 

limit

ce

t

a

i

n

t

y

40o F degrees is too cold:

an uncomfortable temperature 30

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 31/56

Fuzzy logic - example

0.75 

0.5 

0.25 

0 40  50  60  70  80  90  100 

Cold  Warm Cool Norm 

Hot 

temperature

Upper 

limit

ce

t

a

i

n

t

y

100o F degrees is too hot:

an uncomfortable temperature 31

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 32/56

Fuzzy logic - example

0.75 

0.5 

0.25 

0 40  50  60  70  80  90  100 

Cold  Warm Cool Norm 

Hot 

temperature

ce

r

t

a

i

n

t

y

Upper 

limit

ce

t

a

i

n

t

y

60o F degrees is cool:

but not an uncomfortable temperature 32

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 33/56

Fuzzy logic - example

0.75 

0.5 

0.25 

0 40  50  60  70  80  90  100 

Cold  Warm Cool Norm 

Hot 

temperature

ce

r

t

a

i

n

t

y

Upper 

limit

ce

t

a

i

n

t

y

80o F degrees is warm:

but not an uncomfortable temperature 33

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 34/56

Fuzzy logic - example

0.75 

0.5 

0.25 

0 40  50  60  70  80  90  100 

Cold  Warm Cool Norm 

Hot 

temperature

Upper 

limit

ce

t

a

i

n

t

y

Is 90o F degrees warm or hot?34

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 35/56

Fuzzy logic - example

0.75 

0.5 

0.25 

0 40  50  60  70  80  90  100 

Cold  Warm Cool Norm 

Hot 

temperature

ce

r

t

a

i

n

t

y

Upper 

limit

ce

t

a

i

n

t

y

Is 55o F degrees cool or cold?35

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 36/56

Fuzzy logic - example

0.75 

0.5 

0.25 

0 40  50  60  70  80  90  100 

Cold  Warm Cool Norm 

Hot 

temperature

ce

r

t

a

i

n

t

y

Upper 

limit

?  ? 

ce

t

a

i

n

t

y

Is 75o F degrees warm or the norm?

Is 65o F degrees cool or the norm? 36

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 37/56

Fuzzy logic - applications

Fuzzy logic applied in Japan:◦ Sendai’s subway system used fuzzy logic controls to accelerate smoothly 

◦ Mitsubishi Heavy Industries implemented fuzzy logic controls in air 

conditioners (reducing power consumption by 20%)

◦  Auto-focus device in cameras relies on fuzzy logic

… and in the US ◦  A Wall Street firm uses a system based on fuzzy logic to select companies

for potential acquisition

37

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 38/56

Intelligent Agents

38

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 39/56

Intelligent agents - introduction

Intelligent agents are programs that...◦ work in the background without direct human intervention...

◦ perform specific, repetitive, and predictable tasks...

◦ for an individual user, business process, or software application...

◦ with some degree of independence

 Agents use in-built/learned knowledge to

accomplish tasks/make decisions for the user 

39

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 40/56

Intelligent agents - levels

Level 0 - e.g. web browsers  

◦ agents retrieve documents for user under direct orders  

e.g. user specifies URL

Level 1 - search engines  

◦ agents provide a user-initiated  search facility

Level 2 - software agents  

o maintain user’s profiles 

o monitor Internet information

o notify users  when relevant information is found

Level 3 - learning or truly intelligent agents  

o have a learning and deductive component of user profiles to help a user  

who cannot formalise a query or target for a search40

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 41/56

Intelligent agents - applications (1)

Intelligent agents◦ can be programmed to make decisions based on user's

personal preferences  e.g. 

delete junk e-mail schedule appointments

travel over interconnected networks to find the cheapest

airfare

41

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 42/56

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 43/56

Game Theory

43

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 44/56

Game theory - introduction

 Also called ‘Multi -  person Decision Theory’  

 Analyses the decision-making process when there is

more than one decision-maker (player)

Each player’s outcome (or payoff) depends on the

actions taken by the other players

44

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 45/56

Each player’s action depends on

o the actions available to each player 

o each player's preferences about the outcomes

o each player's beliefs about which actions are available to each

player and how each player ranks the outcomes

o each player’s beliefs about other player's beliefs, etc.

Cutting the (delicious chocolate) cake - ‘cutter’ and ‘chooser’  

o if the cutter makes one slice bigger than the other o the chooser will take the biggest slice!

o ...better to make slices as near equal as possible

Game theory - introduction

45

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 46/56

Game Theory (1)

Prisoner’s Dilemma ◦  Art and Don are arrested for a crime

if Art confesses and incriminates Don

 Art goes free , Don gets 5 years  

if Art does not confess, but Don incriminates Art

 Don goes free , Art gets 5 years   

if both Art and Don confess and incriminate each other 

 they both  get 4 years    

if both Art and Don do not confess

 they both  get 2 years    

◦ they are told the same thing but they cannot communicate… 

◦ could they trust each other if they could communicate...?

◦ what does each decide to do?

46

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 47/56

Game Theory (2)

Prisoner’s Dilemma 

◦ Mutual co-operation gives the best outcome for 

 Art and Don (together as a group)

minimum total time spent in jail

◦  Any other outcome less good for the group

might be better for one , but worse for the other 

might be worse for both  

total jail time overall would be greater 

◦ Selfish action (betrayal) gives the worst outcome  for Art and Don (individually and together) 47

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 48/56

Game Theory (3)

Prisoner’s Dilemma 

◦ if Art says nothing he’ll get 2 years if Don says nothing 

he’ll get 5 years if Don confesses 

◦ if Art talks, he might go free

but if Don talks as well, they’ll both get4 years

◦ if Don says nothing he’ll get 2 years if Art says nothing 

he’ll get 5 years if Art confesses

◦ if Don talks, he might go free but if Art talks as well, they’ll both get 4

years

-2, -2 -5, 0

0, -5 -4, -4

Don 

Art Ssh  Talk 

Ssh 

Talk 

Is it better to co-operate 

or  defect (betray)?48

G Th ( )

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 49/56

  -4  -5

-5  -8

Don 

Art Ssh!  Talk 

Ssh! 

Talk 

win-win  lose-win

win-lose  lose-lose

Don 

Art Ssh  Talk 

Ssh! 

Talk 

Payoff matrix in win-lose format Payoff matrix in penalty format

Prisoner’s Dilemma 

Game Theory (4)

49

G Th ( )

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 50/56

Prisoner’s Dilemma Variation:exchange of closed bags

o bag 1 should contain goods

o bag 2 should contain payment

If both bags are full: win-win  

o What happens if one bag is empty?

o What happen if both bags are

empty?

win-win  lose-win 

win-lose lose-lose

Goods 

Cash Full  Empty 

Full 

Empty 

Game Theory (5)

50

G Th (6)

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 51/56

Prisoner’s Dilemma Variation:

exchange of closed bags, but

played every month

o bag 1 should contain goods  

o bag 2 should contain payment  

If both bags are full: win-win  

o What happens if one bag is empty?

o What happen if both bags are empty?

Introduces memory o What happened last time ? 

o What will be your strategy this time ? 

win-win  lose-win 

win-lose lose-lose

Goods 

Cash Full  Empty 

Full 

Empty 

Game Theory (6)

51

G Th l

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 52/56

Game Theory - examples

Prisoner’s Dilemma (PD) and Iterated Prisoner’s Dilemma (IPD) can be applied: 

◦ 2 salesmen selling to 2 client companies

◦ 2 military generals attacking/defending 2 locations

◦ 2 companies deciding whether to advertise competing products

◦ 2 political candidates seeking support from colleagues

(David Cameron and Nick Clegg as leaders of Con-Dem alliance)

 All examples of two-player non-zero-sum games

Game theory can be applied to

o airline competition

o coalition formation to apply political pressure

o plant location

o product diversification

o to derive optimal pricing, competitive bidding strategies and making

investment decisions52

G Th t t i

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 53/56

Game Theory: strategies

Strategies for playing IPD◦ Always co-operate  

will be beaten but “nasty” strategies 

◦ Always defect  

greedy strategies do not do well long-term

◦ Tit-for-tat 

start by co-operating, then copy opponent

◦ Spiteful  

co-operates until opponent defects, then always defects◦ Mistrust  

start by defecting, then copy opponent

53

G Th t t i

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 54/56

Successful strategies

o “nice ” 

o does not defect before opponent does

o “retaliate ” 

o punish defection - it does not pay to be too nice

o “forgive ” o will retaliate, but will then co-operate if opponent does

o avoids long-term revenge

o “non-envious ” 

o not trying to out-score opponent Could ideas from IPD show how altruism evolved?

o Sometimes it is “selfish” to appear to be “nice”! 

o Nice guys finish first...

Game Theory: strategies

54

Game theory applications

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 55/56

Game theory - applications

Game theory is

“uniquely qualified to make sense of the forces at work”

in relation to executive decision-making ,

i.e. “to the strategies of some actual corporations caught

up in conglomerate warfare” 

McDonald (1970) from Davis (1997)

55

Further reading

7/30/2019 CC6052 Week 12 slides

http://slidepdf.com/reader/full/cc6052-week-12-slides 56/56

Further reading

 Aleksander I & Morton H (1991), An Introduction to NeuralComputing, Chapman & Hall

Davis, M, 1997, Game Theory: a non-technical introduction , Dover 

Laudon, K. & Laudon, J., 2004, Management Information Systems ,8th ed., Pearson Prentice Hall

‘Other intelligent techniques’: chapter 10, pages 333-339 Turban E. & Aronson J.E., 2001, Decision Support Systems and 

Intelligent Systems , 6th ed., Prentice Hall

Neural Computing (the basics): chapter 15, pages 605-621, 634-636

Neural Computing Applications: chapter 16, pages 651-661

Genetic algorithms: chapter 16, pages 664-671

Fuzzy Logic: chapter 16, pages 672-676

Look up ‘game theory’ and/or the ‘prisoner’s dilemma’ on the web 56