Class SingleThreadTCSolver
java.lang.Object
solvers.queueingnet.treeAlgorithms.TreeTraverser
solvers.queueingnet.treeAlgorithms.treeConvolution.SingleThreadTCSolver
- All Implemented Interfaces:
IThreadedTCSolver
Tree Convolution solver that uses a single thread.
- Author:
- Ben Homer, 2014.
-
Field Summary
Fields inherited from interface IThreadedTCSolver
normalisationConstantTimer, queueLengthTimer, throughputTimer -
Constructor Summary
ConstructorsConstructorDescriptionSingleThreadTCSolver(QNModel qnm, ConvolutionLayer cl, TreePlanter tp) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionBigRational[][]Calculates per class and per station mean queue lengths using methods outlined in LamLien83 paper.Calculates per class throughputs using methods outlined in LamLien83 paper.computeG(Node node, PopulationVector pv) Computes G using postorder tree traversal.voidcomputeSubnetNode(Node node, PopulationVector pv) Computes results at subnetwork node by delegating to the convolution layer.voidinitLeafNode(Node node, PopulationVector pv) Computes results at leaf node by delegating to the convolution layer.Methods inherited from class TreeTraverser
iterativeTraverse, recursiveTraverse
-
Constructor Details
-
SingleThreadTCSolver
Constructor.- Parameters:
qnm- The queueing network model to solve.cl- The convolution layer to delegate to.tp- The tree planter.
-
-
Method Details
-
computeG
Computes G using postorder tree traversal.- Specified by:
computeGin interfaceIThreadedTCSolver- Parameters:
node- The current node to compute the normalisation constant G for.pv- The population vector to be used during the computation.- Returns:
- The normalisation constant G at the given node, calculated using the specified population vector.
-
initLeafNode
Computes results at leaf node by delegating to the convolution layer.- Specified by:
initLeafNodein classTreeTraverser- Parameters:
node- The leaf node.pv- The population vector to use for the computation.
-
computeSubnetNode
Computes results at subnetwork node by delegating to the convolution layer.- Specified by:
computeSubnetNodein classTreeTraverser- Parameters:
node- The subnetwork node.pv- The population vector to use for the computation.
-
calculateThroughputs
Calculates per class throughputs using methods outlined in LamLien83 paper.- Specified by:
calculateThroughputsin interfaceIThreadedTCSolver- Parameters:
p- The full population vector.- Returns:
- The per class throughputs as an array of BigRationals.
-
calculateMeanQueueLengths
Calculates per class and per station mean queue lengths using methods outlined in LamLien83 paper.- Specified by:
calculateMeanQueueLengthsin interfaceIThreadedTCSolver- Parameters:
p- The full population vector.- Returns:
- The per class per station mean queue lengths as a 2D array of BigRationals.
-