<<Back

Lab 4: Discussion for Programming Assignment 1

Program Structure for Event Driven Simulation

Entities and their data structures:    

    Maintenance person

    Bulbs, Lighting Fixtures, Rooms

    Repair list

Groupings:

    Bulbs ==> Lighting Fixtures ==> Rooms    

Events:

    Bulb burning out: put itself to the repair list

    Maintenance person starting repair job: 

    Maintenance person finishing repair job: Is this event really needed ?

    Maintenance person starting check job: Is this event really needed ?

Pseudo-events: 

    end-of-simulation: scheduled during initialization, used to initiate the final output of the statistics and measurements

    progress-report: report a summary of the statistics and measurements once for a while

Random number generator:

    Multiple random number streams (following gas station example)

Statistics and Measurements

    Record all the necessary data during the simulation

 

<<Back


Last Update: 04/22/2004