All simulation programming projects must meet these requirements.

  1. Submitted as a .zip or .tar.(Z|gz|bz2) compressed archive.

    If you are generating an archive with symbolic links from another *nix box, just use tar --- the invocation of zip seems to be tricky (or there are inconsistent zip versions in Linux land).

  2. The archive file submitted must have one of the following in its root (top) directory:

    1. A Makefile compatible with GNU make (this is the standard make on a Linux box)

    2. A Build.sh Bourne (sh) or bash script

      This is a 400 level course in a CS program, I think it is reasonable to expect students to be able to either

      1. develop in a Unix environment
      2. transport a system independent code base1 from Windows or MacOS X to a Unix environment.

      If you need help doing this please let me know, I'm happy to help out. In extreme cases, I could see myself allowing Windows specific sims, but I really don't want to go there...

    In either case, after running
    $ make
    or
    $ bash Build.sh

    there should be an application2 named SIM that is your simulator for the assignment.3 That's all capitals, SIM.

  3. SIM will be invoked with the appropriate command line arguments for the assignment, results required by the assignment should be printed on stdout. Any output line with an assignment required result must have OUTPUT as the first word (token).

  4. All numerical values required by an assignment must have whitespace (which includes end of line) around them.
  5. (Added -- khellman 2013-09-28 14:01:25) Required textual output should be surrounded by single colons (:).

  6. The order for results is assignment specific and important, they must emanate from the application in the order dictated by the assignment.

  7. Your submitted archive should not contain unnecessary files (.o, .pyc, *.h~, ...)

  8. Files and directories that begin with an underscore are reserved for use by your instructor, TA, or grader.

    1. Your submitted archive file should not have any entries that begin with an underscore.
    2. Your SIM should not use or create files or directories that begin with an underscore.

  9. (Update -- khellman 2013-09-28 13:44:44) Written answers or graphs should always be provided in a doc subdirectory. (Update for clarity -- khellman 2013-11-15 15:27:06) The doc directory should be in the same location as your Makefile or Build.sh file, which is to say in the top, root, of your archive.

    1. Prose should be provided in either a text file, an HTML file, or a PDF file.
    2. Graphs may be embedded in your written answers (if you provide HTML or PDF). If your answers are written in a simple text file, provide your graphs in a common raster image file format (PNG, JPEG, ...), SVG, or (preferably) PDF. Refer to the graphs by name in your answer write-up.
    3. Graphs provided for assignments without a required written component should be in appropriately named files (still, of course in doc) and should be self-explanatory on viewing.4

    4. Students may always feel free to submit a README file for any assignment, but it needs to be in doc and follow these conventions.

Examples

Submission Templates

Here are example trees for submissions, one each for the most common languages used by students. If you are using another language, look at one of the templates for a similar language.

Templates with a Makefile: edit Project.mak instead --- much easier.

If like to use use IDEs such as Eclipse or MsVs:

  1. do your work in the IDE with a simple source layout
  2. copy your code into the appropriate extracted template on alamode

  3. test to make sure it builds and runs correctly

  4. clean it out (there is a clean target in the provided Makefiles, otherwise remove residual files by hand)

  5. tar or zip it up and submit.

Output Formatting

Suppose a simulation assignment dictates:

  • Your SIM should accept two arguments. The first argument is the seed for your pRNG, the second argument is the number of experimental runs.

    Your SIM should display 3 numerical results: the average theta, the minimum theta, and the median alpha across all the experimental runs.

Then all of the following outputs would be acceptable:

  • $ ./SIM 38478 1000
    OUTPUT 7.43  -2.1113  7483
    $
    $ ./SIM 38478 1000
    OUTPUT 7.43
    OUTPUT -2.1113
    OUTPUT 7483
    $
    $ ./SIM 38478 1000
    OUTPUT Average theta 7.43 minimum theta -2.1113  middle alpha 7483
    $
    $ ./SIM 38478 1000
    1000 experimental runs beginning!
    ... half-way there
    ... woot! look at us go
    OUTPUT Average theta 7.43 minimum theta -2.1113
    maximum theta 32.874
    OUTPUT middle alpha 7483
    whew.
    $
    $ ./SIM 38478 1000
    OUTPUT Average theta 7.43 minimum theta -2.1113 maximum theta =32.874= middle alpha 7483
    $

But this one is not acceptable for two different reasons:

  • $ ./SIM 38478 1000
    OUTPUT Median alpha=7483     Average theta=7.43     Minimum theta=-2.1113
    $
  1. Sims should be pretty OS agnostic (1)

  2. This means the Unix executable bit is set. (2)

  3. This does not preclude SIM existing before make or Build.sh are run, and a build script might be a mere placeholder. Such a setup is applicable for certain languages. (3)

  4. Heaven forbid, don't forget a graph title. (4)