0% found this document useful (0 votes)
4 views15 pages

Chapter 3

The document outlines a project for a fruit sorting machine that utilizes various sensors to classify fruits based on shape, texture, and weight. It describes the implementation of a single-layer perceptron for classification, along with the Hamming and Hopfield networks for pattern recognition. Key properties, limitations, and operational details of each network type are also discussed.

Uploaded by

zippitti0000
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)
4 views15 pages

Chapter 3

The document outlines a project for a fruit sorting machine that utilizes various sensors to classify fruits based on shape, texture, and weight. It describes the implementation of a single-layer perceptron for classification, along with the Hamming and Hopfield networks for pattern recognition. Key properties, limitations, and operational details of each network type are also discussed.

Uploaded by

zippitti0000
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

Illustrative Example

Who? UBC4006-01

From? Underwood International College, Yonsei University

When? Spring Semester 2026


Problem Statement: The Fruit Sorter

The Scenario A produce dealer needs a machine to automatically sort


mixed fruit on a conveyor belt. Three primitive sensors
measure specific properties:
Shape: 1 (round), −1 (elliptical)
Texture: 1 (smooth), −1 (rough)
Weight: 1 (> 1 lb), −1 (< 1 lb)

Goal: Classify the fruit based on these three binary inputs.


Problem Statement: System Overview

Figure: Conveyor belt and sensor system.


Problem Statement: Data Representation

The input vector p represents the three sensor readings:


   
p1 shape
p = p2  = texture
p3 weight

Target Prototype Vectors:


Orange: porange = [1, −1, −1]T
Apple: papple = [1, 1, −1]T
The Perceptron Network

We first use a single-layer perceptron.


It utilizes the hardlims (Symmetrical Hard Limit)
transfer function.

a = hardlims(Wp + b)
The Two-Input Case: Linear Separation

Perceptrons classify inputs into two distinct regions.


For a 2D case where W = [−1, 1] and b = −1:

n = [−1, 1]p − 1 = 0 =⇒ −p1 + p2 − 1 = 0

The decision boundary is where the net input n = 0.


Key Properties of Perceptrons

The decision boundary is always orthogonal to the


weight matrix W.
The bias b shifts the position of the boundary away
from the origin.
Limitation: Perceptrons can only classify patterns that
are linearly separable.
Wp + b = 0
Example: Separating Apples and Oranges

We aim for: Orange → −1 and Apple → 1.


Looking at the prototypes, texture (p2 ) is the
distinguishing factor.
We choose W = [0, 1, 0] and b = 0.
Testing the Perceptron

Perfect Apple: hardlims([0, 1, 0][1, 1, −1]T + 0) = 1 ✓


Perfect Orange:
hardlims([0, 1, 0][1, −1, −1]T + 0) = −1 ✓
Elliptical Orange: Input p = [−1, −1, −1]T :

a = hardlims(−1) = −1 (Classified as Orange)

Result: Any vector closer to the prototype in the feature


space is correctly classified.
The Hamming Network

Designed for binary pattern recognition.


Consists of two layers:
1 Feedforward Layer: Calculates correlation with prototypes.
2 Recurrent Layer: A competitive layer (MaxNet) to find the
”winner.”
Hamming Layer 1: Feedforward

Weights are set to the prototype patterns:


 T   
1 porange 1 −1 −1
W = =
pTapple 1 1 −1

Bias b1 is set to R (number of elements, here 3):


 
1 1 3
a =W p+
3

The output is maximum for the prototype with the


smallest Hamming Distance.
Hamming Layer 2: Recurrent (MaxNet)

Neurons compete; only the one with the highest initial


value survives.
Dynamics:

a2 (0) = a1 , a2 (t + 1) = poslin(W2 a2 (t))

Lateral Inhibition: W2 has 1 on the diagonal and −ϵ


elsewhere.
 
2 1 −ϵ 1
W = , ϵ<
−ϵ 1 S −1
The Hopfield Network

A recurrent network that acts as an associative memory.


Unlike Hamming (which outputs a class index), the
Hopfield network outputs the reconstructed prototype
pattern itself.
Hopfield Operation

Update Rule: a(t + 1) = satlins(Wa(t) + b)


Example Weight/Bias for a specific problem:
   
0.2 0 0 0.9
W = 0 1.2
 0 , b =  0 
0 0 0.2 −0.9

Behavior: Values saturate at 1 or −1. a2 acts as a


decision maker because its weight (1.2) is > 1.
Summary of Pattern Recognition Networks

Network Type Function


Perceptron Feedforward Linear decision boundary
Hamming FF + Recurrent Finds closest Hamming distan
Hopfield Recurrent Pattern reconstruction (Assoc

You might also like