ContactCenters
V. 0.9.9.

umontreal.iro.lecuyer.contactcenters.contact
Class Busyness

java.lang.Object
  extended by umontreal.iro.lecuyer.contactcenters.contact.Busyness

public class Busyness
extends Object

FOR NOW, THIS CLASS IS UNUSED. THE BUSYNESS FACTOR IS SET AND KEPT IN CLASS ContactArrivalProcess.

This class implements the busyness factors that allows us to stretch or compress arrival rates or counts. It can be a global factor or a set of specific factors for each period of the day or both.

Author:
Richard Simard

Constructor Summary
Busyness(double b)
          Constructor with common busyness factor b.
Busyness(double[] B)
          Constructor with busyness factors B[j] for each period j.
Busyness(double b, double[] Bs)
          Constructor with busyness factors B[j] for each period j, and common busyness factor b.
 
Method Summary
 double getBusyness(int j)
          Returns the total busyness of period j.
 RandomVariateGenParams getBusynessGen()
          Returns the random number generator used for busyness.
 double getExpectedFactor()
          Returns the expected value of the busyness factor.
 double getFactor()
          Returns the common busyness factor B.
 double getFactor(int j)
          Returns the busyness factor Bj of period j.
 void setBusynessGen(RandomVariateGenParams gen)
          Sets the random number generator for busyness to gen.
 void setExpectedFactor(double bMean)
          Sets the expected busyness factor to bMean.
 void setFactor(double b)
          Sets the common busyness factor to b.
 void setFactors(double[] B)
          Sets the busyness factor to B[j] for each period j.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Busyness

public Busyness(double b)
Constructor with common busyness factor b. It must be greater than or equal to 0. The default value is 1.

Parameters:
b - busyness factor

Busyness

public Busyness(double[] B)
Constructor with busyness factors B[j] for each period j. Each factor must be greater than or equal to 0. The factor of the preliminary period B[0] and the wrap-up period B[p + 1] are usually set to 0.

Parameters:
B - busyness factors for each period

Busyness

public Busyness(double b,
                double[] Bs)
Constructor with busyness factors B[j] for each period j, and common busyness factor b. Each factor must be greater than or equal to 0.

Parameters:
b - common busyness factor
Bs - busyness factors for each period
Method Detail

getFactor

public double getFactor()
Returns the common busyness factor B.

Returns:
the common busyness factor.

setFactor

public void setFactor(double b)
Sets the common busyness factor to b. It must be greater than or equal to 0, and defaults to 1.

Parameters:
b - common busyness factor

getFactor

public double getFactor(int j)
Returns the busyness factor Bj of period j. If it is undefined, this method returns 1.

Parameters:
j - index of period
Returns:
the busyness factor of period j.

setFactors

public void setFactors(double[] B)
Sets the busyness factor to B[j] for each period j. Each must be greater than or equal to 0. The factor of the preliminary period B[0] and the wrap-up period B[p + 1] are usually set to 0.

Parameters:
B - busyness factors

getExpectedFactor

public double getExpectedFactor()
Returns the expected value of the busyness factor.

Returns:
the expected value of the busyness factor.

setExpectedFactor

public void setExpectedFactor(double bMean)
Sets the expected busyness factor to bMean.

Parameters:
bMean - the new value of the expectation.
Throws:
IllegalArgumentException - if bMean is negative.

getBusyness

public double getBusyness(int j)
Returns the total busyness of period j. It is the product of the common factor B with the specific factor Bj of period j.

Parameters:
j - index of period
Returns:
the busyness multiplier of period j.

getBusynessGen

public RandomVariateGenParams getBusynessGen()
Returns the random number generator used for busyness.


setBusynessGen

public void setBusynessGen(RandomVariateGenParams gen)
Sets the random number generator for busyness to gen.

Parameters:
gen -

toString

public String toString()
Overrides:
toString in class Object

ContactCenters
V. 0.9.9.

To submit a bug or ask questions, send an e-mail to Richard Simard.