                                                       KJC (03/07/99)



This directory contains the SMPL "language: as described in the book,
"Simulating Computer Systems, Techniques and Tools" by M. H. MacDougall
(MIT Press, 1987).  Sample programs from the book have not been included.
Changes have been made, and noted in each file, to make compiling
possible with gcc on UNIX machines.  Everything here should work with
Borland and Microsoft compilers on a PC and gcc on UNIX machines.  On
a bcc compile on Solaris no warnings will be flagged.  On a bcc32 compile
two warnings will be flagged:

#
#Borland C++ 5.2 for Win32 Copyright (c) 1993, 1997 Borland International
#mm1.c
#smpl.c:
#Warning smpl.c 71: 'i' is assigned a value that is never used in function smpl
#Warning smpl.c 504: Call to function 'exit' with no prototype in function error
#bmeans.c:
#rand.c:
#Turbo Link  Version 2.0.68.0 Copyright (c) 1993,1997 Borland International
#

To build myprog.exe on a PC using a Borland compiler do the following:

  bcc myprog.c smpl.c rand.c bmeans.c

where myprog.c is a simulation model using SMPL.

To build a.out on a UNIX machine using the cc or gcc compilers do the
following (the "-lm" links the math library):

  gcc myprog.c smpl.c rand.c bmeans.c -lm

where myprog.c is a simulation model using SMPL.

The following files are needed for a simulation model using SMPL:

  myprog.c  - - - A simulation program that you write
  smpl.c  - - - - SMPL functions
  smpl.h  - - - - Include file for SMPL
  rand.c  - - - - Random number generators
  bmeans.c  - - - Batch means functions (stat.c merged into this file)

Note that if stdlib.h needs to be included in the main simulation program,
it must be done so *after* #include "smpl.h" to prevent any redefinition
problems.

---
Ken Christensen
christen@csee.usf.edu
http://www.csee.usf.edu/~christen
