VBASim in MATLAB This is README.TXT Oct.01.2012 README for "VBASim in MATLAB" package ================================= "VBASim in MATLAB" is a MATLAB version of orginal VBASim in VBA. The orignal VBA code can be found on Barry Nelson's homepage http://users.iems.northwestern.edu/~nelsonb/ VBASim in MATLAB is a collection of MATLAB Scripts, Functions and Class M-files that aid in developing discrete-event simulations. They are entirely open source and can be modified to suit the user. The random-number and random-variate generation routines are MATLAB translations of the corresponding routines in simlib (Law 2007) which is written in \texttt{C}.\index{Law, A. M.}\index{simlib} VBASim is designed to be easy to understand and use, but not necessarily efficient. The package contains the following files/folder: ========================================================== Examples ===== Asian Simulate Asian option example FaxCenter Fax center case study MG1 M/G/1 using event-based simulation MGLindley M/G/1 using Lindley's formular MtMInifinty Simulating M(t)/M/inf queue SAN Discrete-event Simulation of the SAN SANMax Maximum Path Simulation of the SAN TTF Simulating time-to-failure examples ========================================================== ========================================================== Core Files ========================================================== Class Definitions ==== Activity.m Activity class definition CTStat.m Continuous time statistic definition DTStat.m Discrete time statistic definition Entity.m Entity class definition EventCalendar.m EventCalendar class definition EventNotice.m EventNotice class defintion FIFOQueue.m FIFOQueue class definition MyGVar.m MyGVar class definition Stores VBASim global variables as its properities Resource.m Resource class definition Task related functions ==== ClearStats.m Clear VBASim statistics Report.m Write results to text files Schedule.m Schedule a future event Scheduleplus.m Schedule a future event and pass the object property along with the event VBASimInit.m Intialize VBASim event related variables Random number generator related functions ==== Erlang.m Generate a pseudo random number with erlang distribution Expon.m Generate a pseudo random number with exponential distribution --------------------------------------------------------------------- InitializeRNSeed.m Intialize random number generator lcgrand.m Generate a pseudo random number between 0 and 1 NOTE: To produce the same result as in the book, use the commented version of InitializeRNSeed and lcgrand --------------------------------------------------------------------- Lognormal.m Generate a pseudo random number with lognormal distribution Normal.m Generate a pseudo random number with normal distribution Random_integer.m Generate a pseudo random integer between a and b Triangular.m Generate a pseudo random number with triangular distribution Uniform.m Generate a pseudo random number with uniform distribution ========================================================== Installation ============ To execute VBASim related functions/classes, VBASim core files need to be placed under a MATLAB path folder (e.g. \toolbox\ folder) or the same folder with the user defined functions/scripts