Package jline.solvers

Class SolverOptions

  • All Implemented Interfaces:

    public class SolverOptions
    
                        

    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.

    • Constructor Detail

      • SolverOptions

        SolverOptions()
        Creates SolverOptions with default settings.
      • SolverOptions

        SolverOptions(SolverType solverType)
        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 Detail

      • copy

         SolverOptions 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

         SolverOptions cutoff(int s)

        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

         SolverOptions cutoff(double s)

        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

         SolverOptions cutoff(Matrix cutoffMatrix)

        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

      • getCutoffMatrix

         Matrix getCutoffMatrix(int nstations, int nclasses)

        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 network
        nclasses - Number of job classes in the network
        Returns:

        The properly dimensioned cutoff matrix

      • keep

         SolverOptions keep(boolean s)

        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

         SolverOptions method(String s)

        Sets the solution method/algorithm (builder pattern).

        Parameters:
        s - method name (e.g.
        Returns:

        this SolverOptions instance for method chaining

      • samples

         SolverOptions samples(int s)

        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

         SolverOptions seed(int s)

        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

         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

         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

         SolverOptions verbose(VerboseLevel s)

        Sets the verbosity level for solver output (builder pattern).

        Parameters:
        s - verbosity level
        Returns:

        this SolverOptions instance for method chaining

      • verbose

         SolverOptions verbose(boolean s)

        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

         SolverOptions force(boolean 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