m865.simulation
Class PassengerFactory

java.lang.Object
  extended by m865.simulation.PassengerFactory

public class PassengerFactory
extends java.lang.Object

The PassengerFactory class will create a user specified number of passengers for the elevator system. Each passenger will have a Poisson arrival time, a schedule of two task to complete, and a random balk time.


Field Summary
protected  java.util.Random generator
           
protected  double lambda
           
protected  double meanBalk
           
protected  double meanTask
           
protected  int n
           
protected  double stdBalk
           
protected  double stdTask
           
 
Constructor Summary
PassengerFactory(int num, double lambda, long seed, double mt, double st, double mb, double sb)
          Constructor for objects of class PassengerFactory
 
Method Summary
 void schedulePassengers(DepartmentStore dept)
          Generates each passenger and generates a personal schedule for each, consisting of an arrival time, two tasks with times and a balk time for that particular customer.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

n

protected int n

generator

protected java.util.Random generator

lambda

protected double lambda

meanTask

protected double meanTask

stdTask

protected double stdTask

meanBalk

protected double meanBalk

stdBalk

protected double stdBalk
Constructor Detail

PassengerFactory

public PassengerFactory(int num,
                        double lambda,
                        long seed,
                        double mt,
                        double st,
                        double mb,
                        double sb)
Constructor for objects of class PassengerFactory

Parameters:
num - The number of people to create
lambda - The arrival rate for the Poisson Process
seed - The seed for the RNG.
mt - The mean amount of time spent on a floor
st - The standard deviation for the time spent on a floor
mb - The mean amount of balking time
sb - The standard deviation for the balking time
Method Detail

schedulePassengers

public void schedulePassengers(DepartmentStore dept)
Generates each passenger and generates a personal schedule for each, consisting of an arrival time, two tasks with times and a balk time for that particular customer.