Utilities and Constants
Constants and enumerations
These modules provide utility functions, constants, and enumerations.
Constants and Enumerations (matlab/src/lang/constant/)
The constants module defines enumerations and global constants used throughout the LINE Solver package.
Scheduling Strategies (SchedStrategy)
FCFSFirst-Come First-Served
LCFSLast-Come First-Served (non-preemptive)
LCFSPRLast-Come First-Served Preemptive-Resume
LCFSPILast-Come First-Served Preemptive-Independent
PSProcessor Sharing (egalitarian)
DPSDiscriminatory Processor Sharing
GPSGeneralized Processor Sharing
INFInfinite Server (delay station)
HOLHead-of-Line priority (non-preemptive)
SJFShortest Job First
LJFLongest Job First
SEPTShortest Expected Processing Time
LEPTLongest Expected Processing Time
SIROService In Random Order
POLLINGPolling-based service
EXTExternal (arrivals from outside)
FORKFork behavior
REFReference (for reference stations)
Routing Strategies (RoutingStrategy)
DISABLEDRouting disabled
FIRINGPetri net transition firing
JSQJoin Shortest Queue
KCHOICESPower of k choices
PROBProbabilistic routing
RANDRandom (uniform) routing
RROBINRound-robin routing
WRROBINWeighted round-robin
Process Types (ProcessType)
EXPExponential
ERLANGErlang
HYPEREXPHyperexponential
APHAcyclic Phase-Type
PHPhase-Type
COXIANCoxian
DETDeterministic
UNIFORMUniform
GAMMAGamma
PARETOPareto
WEIBULLWeibull
LOGNORMALLog-normal
MAPMarkovian Arrival Process
MMPP2Two-state MMPP
REPLAYERTrace replayer
TRACEGeneric trace
DISABLEDDisabled process
IMMEDIATEInstantaneous
Node Types (NodeType)
SOURCEArrival source
SINKDeparture sink
QUEUEService queue
DELAYInfinite server station
ROUTERRouting node
FORKFork node
JOINJoin node
CACHECache station
CLASSSWITCHClass-switching node
LOGGERLogging node
PLACEPetri net place
TRANSITIONPetri net transition
Job Class Types (JobClassType)
OPENOpen class (external arrivals)
CLOSEDClosed class (fixed population)
DISABLEDDisabled class
Service Strategies (ServiceStrategy)
LILoad-Independent service
LDLoad-Dependent service
Solver Types (SolverType)
MVAMean Value Analysis
CTMCContinuous-Time Markov Chain
FLUIDFluid approximation
MAMMatrix-Analytic Methods
NCNormalizing Constant
SSAStochastic Simulation Algorithm
JMTJava Modelling Tools
AUTOAutomatic selection
LQNSLayered QN Solver
QNSQN Solver
LNLayered Network
ENVRandom Environment
Metric Types (MetricType)
ArvRArrival rate
DropRateDrop rate
FCRMemOccFCR memory occupation
FCRWeightFCR total weight
FJQLenFork-join number of customers
FJRespTFork-join response time
QLenNumber of customers (queue length)
QueueTQueue time
ResidTResidence time
RespTResponse time
RespTSinkResponse time per sink
SysQLenSystem number of customers
SysRespTSystem response time
SysTputSystem throughput
TputThroughput
TputSinkThroughput per sink
TranQLenTransient number of customers
TranRespTTransient response time
TranTputTransient throughput
TranUtilTransient utilization
UtilUtilization
Drop Strategies (DropStrategy)
WAITQWaiting queue (infinite buffer)
DROPDrop arriving customers when full
BASBlocking after service
Replacement Strategies (ReplacementStrategy)
LRULeast Recently Used
FIFOFirst-In First-Out
RRRandom Replacement
SFIFOStatic FIFO
MRUMost Recently Used
LFULeast Frequently Used
Join Strategies (JoinStrategy)
STDStandard join (wait for all)
PARTIALPartial join (k-of-n)
GUARDGuarded join
Call Types (CallType)
SYNCSynchronous call
ASYNCAsynchronous call
Activity Precedence Types (ActivityPrecedenceType)
PRE_SEQSequential precedence
PRE_ANDAND split/join
PRE_OROR split/join
POST_SEQPost-sequential
POST_ANDPost-AND
POST_ORPost-OR
POST_LOOPPost-loop
Polling Types (PollingType)
EXHAUSTIVEExhaustive polling
GATEDGated polling
KLIMITEDK-limited polling
Verbose Levels (VerboseLevel)
SILENTNo output
STDStandard output
DEBUGDebug output
GlobalConstants
The GlobalConstants class provides global configuration options:
CoarseTolCoarse tolerance for comparisons (default: 1e-3)
FineTolFine tolerance for comparisons (default: 1e-6)
ZeroNear-zero threshold (default: 1e-14)
ImmediateImmediate service rate (default: Inf)
MaxIntMaximum integer value (default: 2147483647)
Usage Examples
Setting Scheduling Strategy
model = Network('Example');
queue = Queue(model, 'Queue1', SchedStrategy.PS); % Processor Sharing
Setting Routing Strategy
model.link(Network.serialRouting(source, queue, sink));
% or use probabilistic routing
P = model.initRoutingMatrix();
P{class1}(source, queue) = 1.0;
P{class1}(queue, sink) = 1.0;
model.link(P);
Setting Distribution Type
queue.setService(jobclass, Exp(1.0)); % Exponential
queue.setService(jobclass, Erlang(2, 0.5)); % Erlang
queue.setService(jobclass, HyperExp([0.5 0.5], [1.0 2.0])); % Hyperexponential