Sefirs

A Simple and Efficient Framework for Infinite Resolution Simulation

Introduction

Sefirs provides a Java Thread-like class that executes over simulated time. Time units are user-definable, there is no time quanta, and neither changes to the VM nor pre-processing (like bytecode re-writers) are required. Sefirs accomplishes this by providing a framework for native thread-based continuations in Java.

This project is basically the extraction and generalization of the simulation kernel of MATES. MATES' simulation kernel is novel; it provides similar functionality to JiST but has a much simpler/cleaner API and does not require a re-writer. It is anticipated that Sefirs will be very useful to both the discrete event simulation and software engineering communities (the kernel can also be used for debugging parallel processing code). Once the Sefirs project is started and stable, the kernel will be removed from MATES and MATES will use Sefirs as its kernel. Technically speaking, Sefirs will provide an extension of the Java "Thread" class. When a Sefirs thread is run in a Sefirs Simulation object, the thread will run in simulated time. Say "thread" is an instance of a Sefirs thread class; one could use the semantics "thread.sleep(new Minutes(3))" and the thread would sleep for 3 simulated minutes. The time units are also user-definable and infinitely scalable (meaning the developer could extend the Minutes class into a Seconds class, which could be extended to a Milliseconds class, et cetera, ad infinitum). The resolution at which the threads/events are scheduled has little effect on the efficiency of the simulation.

Example

Sefirs is best demonstrated by example:

CodeOutput
Odd: 1 second
Even: 2 seconds
Odd: 3 seconds
Even: 4 seconds
	
. . .
Even: 1 minute
Odd: 1 minute 1 second
	
. . .
Even: 1 hour
Odd: 1 hour 1 second
	
. . .
Even: 1 day
        

Current Status

Sefirs is currently in BETA, but is completely functional and usable. Since Sefirs is an offshoot of a preexisting project, much of the code has already been implemented; most of the remaining work lies in documentation.

Downloads

Files and screen shots are available at our SourceForge page.

The latest release of Sefirs is always available here.

Sefirs is under active development; many features are often available directly from CVS well before they make their way to an official release version. The latest CVS snapshot can be downloaded with the following commands:

cvs -d:pserver:anonymous@sefirs.cvs.sourceforge.net:/cvsroot/sefirs login
(Enter a blank password)
cvs -z3 -d:pserver:anonymous@sefirs.cvs.sourceforge.net:/cvsroot/sefirs co -P sefirs

Projects Currently Using Sefirs

If you are currently using Sefirs for your research and your project/name is not listed above, please let us know!

People

Sefirs was originally developed and is maintained by Evan Sultanik. Rob Lass is also a lead developer.




This project is generously hosted by SourceForge:

SourceForge.net Logo