org.yccheok
Class Weight

java.lang.Object
  extended by org.yccheok.Weight

public class Weight
extends java.lang.Object

The weight which will be used in SOM.


Constructor Summary
Weight(int numOfInput)
          Creates a new instance of Weight.
 
Method Summary
 int getNumOfInput()
          Get the number of input.
 double getValue(int index)
          Get index th of weight value.
 void setValue(double value, int index)
          Set index th weight value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Weight

public Weight(int numOfInput)
Creates a new instance of Weight.

Parameters:
numOfInput - The number of input connected by the weights.
Method Detail

getValue

public double getValue(int index)
Get index th of weight value.

Parameters:
index - index th of weight value.
Returns:
index th of weight value.

setValue

public void setValue(double value,
                     int index)
Set index th weight value.

Parameters:
value - Value to be set.
index - Index th weight value.

getNumOfInput

public int getNumOfInput()
Get the number of input.

Returns:
The number of input.