Class Solver
java.lang.Object
solvers.queueingnet.amva.Solver
Solver is an abstract class, which contains the methods to initialize and
solve models with a single class of jobs.
- Version:
- Date: 8-set-2003; Time: 9.43.21
- Author:
- Federico Granata
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intconstant for delay centerstatic final intconstant for Load Dependent service centerstatic final intconstant for Load Independent service centerprotected String[]array containing the names of the stationsprotected double[]array containing the queue length of each service centerprotected double[]array containing the residence time of each service center.protected double[][]array of array (i.e.protected intnumber of resourcesprotected double[]array containing the throughput of each service centerprotected doubletotal response timeprotected doubletotal throughputprotected doubletotal number of usersprotected int[]array containing the types of the stationsprotected double[]array containing the utilization of each service centerprotected double[]array containing the number of visits to each service center -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondouble[]returns the queue length of each service centerdoublegetQueueLen(int serv) returns the queue length for the requested stationdouble[]return the residence time of each service centerdoublegetResTime(int serv) returns the residence time for the requested stationdouble[]returns the throughput of each service centerdoublegetThroughput(int serv) returns the throughput for the requested stationdoublereturns the response time for the systemdoublereturns the throughput of the systemdoublereturns the mean number of customers in the systemdouble[]returns the utilization of each service centerdoublegetUtilization(int serv) returns the utilization for the requested stationabstract booleanA system is said to have sufficient capacity to process a given loadlambdaif no service center is saturated as a result of such a load.booleanInitializes the solver with the model parameters.voidprints all the calculated indices in the system.out it is used to debug or test the class.abstract voidsolve()Must be implemented to create a single class model solver.
-
Field Details
-
LD
public static final int LDconstant for Load Dependent service center- See Also:
-
LI
public static final int LIconstant for Load Independent service center- See Also:
-
DELAY
public static final int DELAYconstant for delay center- See Also:
-
stations
protected int stationsnumber of resources -
name
array containing the names of the stations -
type
protected int[] typearray containing the types of the stations -
servTime
protected double[][] servTimearray of array (i.e. matrix) containing the service rates of the service centers [station] [population] -
visits
protected double[] visitsarray containing the number of visits to each service center -
throughput
protected double[] throughputarray containing the throughput of each service center -
utilization
protected double[] utilizationarray containing the utilization of each service center -
queueLen
protected double[] queueLenarray containing the queue length of each service center -
residenceTime
protected double[] residenceTimearray containing the residence time of each service center. residence time = time spent in queue + time spent in service -
totThroughput
protected double totThroughputtotal throughput -
totRespTime
protected double totRespTimetotal response time -
totUser
protected double totUsertotal number of users
-
-
Constructor Details
-
Solver
public Solver()
-
-
Method Details
-
input
Initializes the solver with the model parameters. It must be called before trying to solve the model.- Parameters:
n- array of n of service centers.t- array of the types (LD or LI) of service centers.s- matrix of service time of the service centers.v- array of visits to the service centers.- Returns:
- true if the operation is completed with success
-
printIndices
public void printIndices()prints all the calculated indices in the system.out it is used to debug or test the class. -
getTotThroughput
public double getTotThroughput()returns the throughput of the system- Returns:
- the throughput
-
getThroughput
public double getThroughput(int serv) returns the throughput for the requested station- Parameters:
serv- the number of the service center- Returns:
- the throughput
-
getThroughput
public double[] getThroughput()returns the throughput of each service center- Returns:
- the throughput
-
getUtilization
public double[] getUtilization()returns the utilization of each service center- Returns:
- the utilization
-
getUtilization
public double getUtilization(int serv) returns the utilization for the requested station- Parameters:
serv- the number of the service center- Returns:
- the utilization
-
getQueueLen
public double getQueueLen(int serv) returns the queue length for the requested station- Parameters:
serv- the number of the service center- Returns:
- the queue length
-
getQueueLen
public double[] getQueueLen()returns the queue length of each service center- Returns:
- the queue length
-
getResTime
public double getResTime(int serv) returns the residence time for the requested station- Parameters:
serv- the number of the service center- Returns:
- the residence time
-
getResTime
public double[] getResTime()return the residence time of each service center- Returns:
- the residence time
-
getTotResTime
public double getTotResTime()returns the response time for the system- Returns:
- the residence time
-
getTotUser
public double getTotUser()returns the mean number of customers in the system- Returns:
-
hasSufficientProcessingCapacity
public abstract boolean hasSufficientProcessingCapacity()A system is said to have sufficient capacity to process a given loadlambdaif no service center is saturated as a result of such a load.
WARNING: This method should be called before solving the system.- Returns:
- true if sufficient capacity exists for the given workload, false otherwise
-
solve
public abstract void solve()Must be implemented to create a single class model solver.
-