Adaptive Resonance Theory .*;

ART1 Example 1

based on articles by Laurene Fausett, and Carpenter and Grossberg

As you experiment with different constants, you'll see some interesting things happen; especially when you raise the VIGILANCE value. When you raise the vigilance, this means that the algorithm will be more "picky" about assigning input vectors to clusters (i.e., the definition of similarity is MORE strict). When you lower the vigilance, the algorithm will be more willing to accept input vectors into clusters (i.e., definition of similarity is LESS strict).

NOTE: One problem you'll run into with this code is when the loop in the ART1() function starts running in an infinite loop. The reason for this is because this code isn't set up to create new cluster nodes to satisfy "picky" vigilance values. When constrained with too few clusters, the algorithm can easily decide it doesn't want to put a particular input vector in any of the clusters, but not know what to do with it. You can get around this (at least in this example) by manually increasing the number of clusters (m) so a "picky" vigilance value will be able to intensely discriminate among clusters for placing each input vector and not run out of cluster nodes to do it.

Example Results

With the constant set as shown above, this code will print the following results. This a fairly verbose way to present the results, but it allowed me to view the changes of the weights step by step.

Weights initialized to:
0.2, 0.2, 0.2, 0.2, 
0.2, 0.2, 0.2, 0.2, 
0.2, 0.2, 0.2, 0.2, 
1, 1, 1, 1, 
1, 1, 1, 1, 
1, 1, 1, 1, 

Begin ART1:

Vector: 0

InputSum (si) = 2

0.2, 0.4, 0.4, 0.4, 
0.2, 0.4, 0.4, 0.4, 
0.2, 0.4, 0.4, 0.4, 

1 * 1 = 1
1 * 1 = 1
0 * 1 = 0
0 * 1 = 0
ActivationSum (xi) = 2

0.66666667, 0.66666667, 0, 0, 
0.2, 0.2, 0.2, 0.2, 
0.2, 0.2, 0.2, 0.2, 

1, 1, 0, 0, 
1, 1, 1, 1, 
1, 1, 1, 1, 

Vector #0 belongs to cluster #0

Vector: 1

InputSum (si) = 1

0, 0, 0, 0, 
0, 0, 0, 0.2, 
0, 0, 0, 0.2, 

0 * 1 = 0
0 * 1 = 0
0 * 1 = 0
1 * 1 = 1
ActivationSum (xi) = 1

0.66666667, 0.66666667, 0, 0, 
0, 0, 0, 1, 
0.2, 0.2, 0.2, 0.2, 

1, 1, 0, 0, 
0, 0, 0, 1, 
1, 1, 1, 1, 

Vector #1 belongs to cluster #1

Vector: 2

InputSum (si) = 1

0.66666667, 0.66666667, 0.66666667, 0.66666667, 
0, 0, 0, 0, 
0.2, 0.2, 0.2, 0.2, 

1 * 1 = 1
0 * 1 = 0
0 * 0 = 0
0 * 0 = 0
ActivationSum (xi) = 1

1, 0, 0, 0, 
0, 0, 0, 1, 
0.2, 0.2, 0.2, 0.2, 

1, 0, 0, 0, 
0, 0, 0, 1, 
1, 1, 1, 1, 

Vector #2 belongs to cluster #0

Vector: 3

InputSum (si) = 2

0, 0, 0, 0, 
0, 0, 0, 1, 
0, 0, 0.2, 0.4, 

0 * 0 = 0
0 * 0 = 0
1 * 0 = 0
1 * 1 = 1
ActivationSum (xi) = 1

1, 0, 0, 0, 
0, 0, 0, 1, 
0.2, 0.2, 0.2, 0.2, 

1, 0, 0, 0, 
0, 0, 0, 1, 
1, 1, 1, 1, 

Vector #3 belongs to cluster #1

Vector: 4

InputSum (si) = 1

0, 0, 0, 0, 
0, 0, 0, 0, 
0, 0.2, 0.2, 0.2, 

0 * 1 = 0
1 * 1 = 1
0 * 1 = 0
0 * 1 = 0
ActivationSum (xi) = 1

Vector #4 belongs to cluster #2

Vector: 5

InputSum (si) = 1

0, 0, 0, 0, 
0, 0, 0, 0, 
0, 0, 0.2, 0.2, 

0 * 1 = 0
0 * 1 = 0
1 * 1 = 1
0 * 1 = 0
ActivationSum (xi) = 1

Vector #5 belongs to cluster #2

Vector: 6

InputSum (si) = 2

1, 1, 1, 1, 
0, 0, 0, 0, 
0.2, 0.2, 0.4, 0.4, 

1 * 1 = 1
0 * 0 = 0
1 * 0 = 0
0 * 0 = 0
ActivationSum (xi) = 1

Vector #6 belongs to cluster #0

1, 0, 0, 0, 
0, 0, 0, 1, 
0.2, 0.2, 0.2, 0.2, 

1, 0, 0, 0, 
0, 0, 0, 1, 
1, 1, 1, 1,

 

public void footer() {
About | Contact | Privacy Policy | Terms of Service | Site Map
Copyright© 2009-2012 John McCullock. All Rights Reserved.
}