Spartacus Developer Notes

This file provides information for Spartacus developers. If you re looking for information on how to install, use, or program with Spartacus, consult the user guide in doc/index.html

Project management

The Spartacus project is maintained by Harold Fellermann (harold@ifk.sdu.dk). The project uses mercurial for version control of the source code, ditz for bug tracking, and distutils for distributing.

Content of the distribution

CHANGES.txt - release history
LICENSE.txt - GPL license file
README.txt  - summary from the Python package index
PKG-INFO    - distutils distribution information
bin         - executable python scripts
setup.py    - distutils setup tool
doc         - user guide
spartacus   - spartacus python API
src         - C sources for time critical code used by the API
The development version additionally includes the following:
bugs         - database for ditz
MANIFEST.in  - information for setup.py sdist
TODO         - some notes

Outline of the code

The Spartacus program is an executable python script located in scripts/spartacus. The script provides a Controller that reads in a model definition file and initializes a Simulation object with the data in the definition. The controller provides a graphical or batch interface to generate graphics, load/save simulations, etc.

The simulation object holds the system state (simulation.space, simulation.time, etc), an instance of the physics class used to generate trajectories (simulation.physics), a list of analyzers used to observe the system (simulation.analyzers), and a bunch of other information about the physical system.

                     +-- controller --+     +-- GUI ----------+
                     |                |     |                 |
   model definition ---> simulation   |<--------- control     |
                     |     object --------------> display     |
                     |                |     |                 |
                     +----------------+     +-----------------+

The executable script is just a thin wrapper around a library, which is a python package located in the folder spartacus. Documentation of the library is provided by pydoc. Start pydoc in server mode with

	$ pydoc -p 8002

and navigate your web browser to http://localhost:8002/