Package jline.solvers
Class SolverOptions
java.lang.Object
jline.solvers.SolverOptions
- Direct Known Subclasses:
AUTOptions,CTMCOptions,EnvOptions,FluidOptions,JMTOptions,LDESOptions,LNOptions,LQNSOptions,MAMOptions,MVAOptions,NCOptions,SSAOptions
Configuration options for queueing network solvers.
This class contains all configurable parameters that control solver behavior, including convergence criteria, numerical tolerances, algorithmic choices, and output preferences. Options can be customized per solver type or globally across all solvers.
Many options are solver-specific and may be ignored by solvers that don't support them. The class provides builder-style setter methods for convenient configuration chaining.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classAdvanced configuration options for specialized solver features.static classConfiguration for ordinary differential equation solvers used in fluid analysis. -
Field Summary
FieldsModifier and TypeFieldDescriptionbooleanEnable result caching to avoid recomputationAdvanced configuration optionsdoubleConfidence interval level for simulation-based solvers.Cutoff threshold for numerical computations.booleanForce solver execution even when validation failsbooleanHide immediate transitions from output when possibleInitial solution for iterative solversintMaximum number of iterations for iterative algorithmsdoubleTolerance for iteration convergencebooleanKeep intermediate results and temporary filesTarget language for execution ("java", "matlab", etc.)Solution algorithm/method to useODE solver configurations for fluid analysisdouble[][]Load-dependent service rate scaling factors for QRF methods.booleanEnable remote solver executionRemote solver endpoint addressNumber of value iterations for CTMC reward computation.intNumber of samples/operations for simulation-based methods.intRandom number generator seed for reproducibilitybooleanUse stiff ODE solvers for numerical integrationdouble[]Time interval for transient analysis [start, end]Fixed timestep for transient analysis (null for adaptive stepping)doubleGeneral numerical toleranceVerbosity level for solver output -
Constructor Summary
ConstructorsConstructorDescriptionCreates SolverOptions with default settings.SolverOptions(SolverType solverType) Creates SolverOptions with defaults customized for a specific solver type. -
Method Summary
Modifier and TypeMethodDescriptionconfint(double level) Sets the confidence interval level for simulation-based solvers (builder pattern).copy()Creates a deep copy of this SolverOptions instance.cutoff(double s) Sets the numerical cutoff threshold as a scalar value (builder pattern).cutoff(int s) Sets the numerical cutoff threshold as a scalar value (builder pattern).Sets the numerical cutoff threshold as a matrix (builder pattern).force(boolean force) Forces solver execution even when validation fails (builder pattern).getCutoffMatrix(int nstations, int nclasses) Ensures the cutoff is properly dimensioned for the given network structure.keep(boolean s) Sets whether to keep intermediate results and temporary files (builder pattern).Sets the solution method/algorithm (builder pattern).samples(int s) Sets the number of samples for simulation methods (builder pattern).seed(int s) Sets the random number generator seed (builder pattern).static voidsetLsodaMaxSteps(odesolver.LSODA solver, int maxSteps) Set the maximum number of internal steps for an LSODA solver instance via reflection (the library does not expose a public setter).voidsetODEMaxStep(double odeMaxStep) Sets the maximum step size for ODE solvers and updates all integrators.voidsetODEMinStep(double odeMinStep) Sets the minimum step size for ODE solvers and updates all integrators.verbose(boolean s) Sets the verbosity level using a boolean flag (builder pattern).Sets the verbosity level for solver output (builder pattern).
-
Field Details
-
cache
public boolean cacheEnable result caching to avoid recomputation -
cutoff
Cutoff threshold for numerical computations. Can be either a scalar (uniform cutoff for all stations and classes) or a matrix (station × class specific cutoffs). Matrix dimensions should be nstations × nclasses. -
config
Advanced configuration options -
force
public boolean forceForce solver execution even when validation fails -
hide_immediate
public boolean hide_immediateHide immediate transitions from output when possible -
init_sol
Initial solution for iterative solvers -
iter_max
public int iter_maxMaximum number of iterations for iterative algorithms -
iter_tol
public double iter_tolTolerance for iteration convergence -
tol
public double tolGeneral numerical tolerance -
keep
public boolean keepKeep intermediate results and temporary files -
lang
Target language for execution ("java", "matlab", etc.) -
method
Solution algorithm/method to use -
remote
public boolean remoteEnable remote solver execution -
remote_endpoint
Remote solver endpoint address -
odesolvers
ODE solver configurations for fluid analysis -
samples
public int samplesNumber of samples/operations for simulation-based methods.Semantics by solver:
- LDES: Maximum service completion events (default: 1,000,000) - Simulation stops when this many completions are processed - 20% of events used for warmup (MSER-5 for automatic truncation)
- SSA: Maximum random number generation operations (default: 10,000) - Approximately 2 RNG ops per reaction event (Gillespie algorithm)
- JMT: Samples per performance metric, minimum 5000 (default: 10,000) - Statistical accuracy parameter, not simulation duration
- NC: Monte Carlo samples for sampling-based methods (default: 100,000)
- LQNS: Simulation length parameter for lqsim tool
- Analytical solvers (MVA, MAM, CTMC, Fluid, etc.): Not used
-
seed
public int seedRandom number generator seed for reproducibility -
stiff
public boolean stiffUse stiff ODE solvers for numerical integration -
timespan
public double[] timespanTime interval for transient analysis [start, end] -
timestep
Fixed timestep for transient analysis (null for adaptive stepping) -
verbose
Verbosity level for solver output -
rewardIterations
Number of value iterations for CTMC reward computation. Used by SolverCTMC for computing cumulative rewards via value iteration. Default is 1000 iterations. -
confint
public double confintConfidence interval level for simulation-based solvers. When set to a value between 0 and 1 (e.g., 0.95 for 95% confidence), the solver will compute and return confidence interval bounds. When set to 0 or negative, confidence intervals are disabled. Default is 0 (disabled). -
qrfAlpha
public double[][] qrfAlphaLoad-dependent service rate scaling factors for QRF methods. Dimensions: alpha[i][n] where i is station index and n is population level. When null, defaults to ones(M, N) in the QRF solver.
-
-
Constructor Details
-
SolverOptions
public SolverOptions()Creates SolverOptions with default settings. Initializes all parameters to sensible defaults suitable for most models. -
SolverOptions
Creates SolverOptions with defaults customized for a specific solver type.- Parameters:
solverType- the type of solver to configure defaults for, or null for generic defaults
-
-
Method Details
-
copy
Creates a deep copy of this SolverOptions instance. All fields including nested objects are properly cloned.- Returns:
- a deep copy of this options object
-
cutoff
Sets the numerical cutoff threshold as a scalar value (builder pattern). This creates a uniform cutoff matrix where all stations and classes use the same cutoff. The matrix will be properly dimensioned when the solver runs.- Parameters:
s- cutoff value to apply uniformly- Returns:
- this SolverOptions instance for method chaining
-
cutoff
Sets the numerical cutoff threshold as a scalar value (builder pattern). This creates a uniform cutoff matrix where all stations and classes use the same cutoff. The matrix will be properly dimensioned when the solver runs.- Parameters:
s- cutoff value to apply uniformly- Returns:
- this SolverOptions instance for method chaining
-
cutoff
Sets the numerical cutoff threshold as a matrix (builder pattern). The matrix should have dimensions nstations × nclasses where each element specifies the cutoff for a specific station-class combination.- Parameters:
cutoffMatrix- Matrix of cutoff values with dimensions nstations × nclasses- Returns:
- this SolverOptions instance for method chaining
- Throws:
IllegalArgumentException- if the matrix is null or has invalid dimensions
-
getCutoffMatrix
Ensures the cutoff is properly dimensioned for the given network structure. If cutoff is null, initializes it to POSITIVE_INFINITY for all stations and classes. If cutoff is a 1x1 matrix (scalar), expands it to full dimensions. If cutoff is already properly dimensioned, leaves it unchanged.- Parameters:
nstations- Number of stations in the networknclasses- Number of job classes in the network- Returns:
- The properly dimensioned cutoff matrix
-
keep
Sets whether to keep intermediate results and temporary files (builder pattern).- Parameters:
s- true to keep files, false to clean up- Returns:
- this SolverOptions instance for method chaining
-
method
Sets the solution method/algorithm (builder pattern).- Parameters:
s- method name (e.g., "mva", "ctmc", "ssa", "fluid")- Returns:
- this SolverOptions instance for method chaining
-
samples
Sets the number of samples for simulation methods (builder pattern).- Parameters:
s- number of samples to generate- Returns:
- this SolverOptions instance for method chaining
-
seed
Sets the random number generator seed (builder pattern).- Parameters:
s- seed value for reproducible random number generation- Returns:
- this SolverOptions instance for method chaining
-
setODEMaxStep
public void setODEMaxStep(double odeMaxStep) Sets the maximum step size for ODE solvers and updates all integrators.- Parameters:
odeMaxStep- maximum step size for numerical integration
-
setODEMinStep
public void setODEMinStep(double odeMinStep) Sets the minimum step size for ODE solvers and updates all integrators.- Parameters:
odeMinStep- minimum step size for numerical integration
-
verbose
Sets the verbosity level for solver output (builder pattern).- Parameters:
s- verbosity level- Returns:
- this SolverOptions instance for method chaining
-
verbose
Sets the verbosity level using a boolean flag (builder pattern).- Parameters:
s- true for standard output, false for silent mode- Returns:
- this SolverOptions instance for method chaining
-
force
Forces solver execution even when validation fails (builder pattern).- Parameters:
force- true to force execution despite validation failures- Returns:
- this SolverOptions instance for method chaining
-
confint
Sets the confidence interval level for simulation-based solvers (builder pattern). A value between 0 and 1 enables CI computation (e.g., 0.95 for 95% confidence). A value of 0 or negative disables CI computation.- Parameters:
level- confidence level (0-1) or 0 to disable- Returns:
- this SolverOptions instance for method chaining
-
setLsodaMaxSteps
public static void setLsodaMaxSteps(odesolver.LSODA solver, int maxSteps) Set the maximum number of internal steps for an LSODA solver instance via reflection (the library does not expose a public setter).
-