org.simnet.neurons
Class BinaryNeuron

java.lang.Object
  extended by org.simnet.interfaces.Neuron
      extended by org.simnet.neurons.BinaryNeuron
All Implemented Interfaces:
GaugeSource

public class BinaryNeuron
extends Neuron

BinaryNeuron type to be used in creating different types of networks.


Field Summary
 
Fields inherited from class org.simnet.interfaces.Neuron
activation, fanIn, fanOut, lowerBound, upperBound
 
Constructor Summary
BinaryNeuron()
          Default constructor needed for external calls which create neurons then set their parameters.
BinaryNeuron(Neuron n)
          This constructor is used when creating a neuron of one type from another neuron of another type Only values common to different types of neuron are copied.
 
Method Summary
 Neuron duplicate()
           
 double getBias()
           
static String getName()
           
 double getThreshold()
           
 int getTimeType()
           
 void setBias(double bias)
           
 void setThreshold(double threshold)
           
 void update()
          Updates the neurons as inputs change.
 
Methods inherited from class org.simnet.interfaces.Neuron
addActivation, addSource, addTarget, checkBounds, clear, clip, connectedToWeight, containsString, debug, decrementActivation, deleteConnectedSynapses, deleteFanIn, deleteFanOut, duplicate, getActivation, getAverageInput, getBuffer, getFanIn, getFanOut, getGaugeValue, getHelp, getId, getIncrement, getInputValue, getLowerBound, getMotorCoupling, getNeuronTypeIndex, getNumberOfActiveInputs, getParentNetwork, getSensoryCoupling, getSummedIncomingWeights, getToolTipText, getTotalInput, getType, getTypeList, getUpperBound, getWeightedInputs, getX, getY, incrementActivation, initCastor, isInput, isOutput, randomize, randomizeBuffer, round, setActivation, setBuffer, setFanIn, setFanOut, setId, setIncrement, setInputValue, setLowerBound, setMotorCoupling, setParentNetwork, setSensoryCoupling, setTypeList, setUpperBound, setX, setY, toString, updateConnectedOutward
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BinaryNeuron

public BinaryNeuron()
Default constructor needed for external calls which create neurons then set their parameters.


BinaryNeuron

public BinaryNeuron(Neuron n)
This constructor is used when creating a neuron of one type from another neuron of another type Only values common to different types of neuron are copied.

Parameters:
n - Neuron to be made the type
Method Detail

getTimeType

public int getTimeType()
Specified by:
getTimeType in class Neuron
Returns:
time type of binary neuron.

duplicate

public Neuron duplicate()
Specified by:
duplicate in class Neuron
Returns:
a duplicate BinaryNeuron (used, e.g., in copy/paste).

update

public void update()
Updates the neurons as inputs change.

Specified by:
update in class Neuron

getThreshold

public double getThreshold()
Returns:
Returns the threshold.

setThreshold

public void setThreshold(double threshold)
Parameters:
threshold - The threshold to set.

getName

public static String getName()
Returns:
the name of the neuron.

getBias

public double getBias()
Returns:
the bias of the neuron.

setBias

public void setBias(double bias)
Parameters:
bias - sets the bias of the neuron.