Package jline.api.wkflow
Object Wkflow_loop_detector
-
- All Implemented Interfaces:
public class Wkflow_loop_detector
Automatic loop structure detector for workflow networks.
This detector identifies loop patterns in workflow networks where service nodes are connected in cycles through router nodes.
Based on AUTO_Loop_Detector.m from the MDN toolbox.
-
-
Field Summary
Fields Modifier and Type Field Description public final static Wkflow_loop_detector
INSTANCE
-
Method Summary
Modifier and Type Method Description final static List<Integer>
detectLoops(Matrix linkMatrix, List<Integer> serviceNodes, List<Integer> routerNodes, List<Integer> joinNodes)
Detect loop patterns in a workflow network. final static Double
getLoopProbability(Integer serviceNode, Matrix linkMatrix, List<Integer> routerNodes)
Get loop probability for a service node. final static Boolean
validateLoopPattern(Integer loopNode, Matrix linkMatrix, List<Integer> routerNodes)
Validate loop pattern structure. final static Double
getExpectedLoopIterations(Double loopProbability)
Calculate expected number of loop iterations. final static Map<String, Object>
getLoopStats(List<Integer> loopNodes, Matrix linkMatrix, List<Integer> routerNodes)
Get loop pattern statistics. -
-
Method Detail
-
detectLoops
final static List<Integer> detectLoops(Matrix linkMatrix, List<Integer> serviceNodes, List<Integer> routerNodes, List<Integer> joinNodes)
Detect loop patterns in a workflow network.
- Parameters:
linkMatrix
- Matrix containing workflow link information: - Column 1: start node IDs - Column 2: end node IDs - Column 3: transition probabilitiesserviceNodes
- List of service node IDsrouterNodes
- List of router node IDsjoinNodes
- List of join node IDs (optional, for complex loops)- Returns:
List of loop patterns, where each pattern contains the loop service node
-
getLoopProbability
final static Double getLoopProbability(Integer serviceNode, Matrix linkMatrix, List<Integer> routerNodes)
Get loop probability for a service node.
-
validateLoopPattern
final static Boolean validateLoopPattern(Integer loopNode, Matrix linkMatrix, List<Integer> routerNodes)
Validate loop pattern structure.
-
getExpectedLoopIterations
final static Double getExpectedLoopIterations(Double loopProbability)
Calculate expected number of loop iterations.
-
-
-
-