|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.joone.structure.AbstractNode
public class AbstractNode
An abstract node class, used to represent a general node type.
Field Summary | |
---|---|
protected java.util.List<Connection> |
connections
List of input connections |
protected DoubleFunction |
derivativeFunction
The function that calculates the derivative |
protected double |
lastDerivative
The derivative value at the last pattern |
protected int |
lastDerivativePattern
Last pattern at which derivative was calculated |
protected double |
lastInputValue
The calculated input value at this pattern |
protected double |
lastOutputValue
The calculated output value at this pattern |
protected int |
lastPattern
The most recent pattern number seen |
protected int |
order
The node order |
protected DoubleFunction |
transportFunction
The function that transforms the input into the output value |
Constructor Summary | |
---|---|
AbstractNode()
Constructor - creates a linear node |
|
AbstractNode(DoubleFunction transportFunction,
DoubleFunction derivativeFunction)
Constructor |
Method Summary | |
---|---|
int |
calculateOrder()
Calculate and set the node's order and return it, or 0 if it was not able to calculate it yet |
java.util.List<Connection> |
getConnections()
Retrieve the list of connections that fire into this node |
double |
getDerivative(int pattern)
The node's current derivative value |
double |
getInputValue(int pattern)
The node's input value at the given pattern number |
int |
getOrder()
The node's order |
double |
getOutputValue(int pattern)
The node's current output value |
javax.swing.tree.MutableTreeNode |
getTreeNode()
Return a suitable treeview description of the node |
void |
setOrder(int order)
Set the node's order |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected int lastPattern
protected double lastInputValue
protected double lastOutputValue
protected int lastDerivativePattern
protected double lastDerivative
protected int order
protected DoubleFunction transportFunction
protected DoubleFunction derivativeFunction
protected java.util.List<Connection> connections
Constructor Detail |
---|
public AbstractNode()
public AbstractNode(DoubleFunction transportFunction, DoubleFunction derivativeFunction)
Method Detail |
---|
public double getInputValue(int pattern)
getInputValue
in interface Node
pattern
- the pattern number, 1 for the first patternpublic double getOutputValue(int pattern)
Node
getOutputValue
in interface Node
pattern
- the pattern number, 1 for the first patternpublic double getDerivative(int pattern)
Node
getDerivative
in interface Node
pattern
- the pattern number, 1 for the first patternpublic int getOrder()
getOrder
in interface Node
public void setOrder(int order)
public int calculateOrder()
public java.util.List<Connection> getConnections()
getConnections
in interface Node
public javax.swing.tree.MutableTreeNode getTreeNode()
getTreeNode
in interface Node
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |