Setting up your agent laboratory

To take part in this course, you'll need to install a number of programs. They are all free to use.

This sketch gives you a general idea of the overall setup. In the following, I describe how to install all the software needed to successfully synchronize your code.

Install the Java 8 Development Kit. Note that the JRE which users sometimes already have installed is not enough. The difference between the JRE and the JDK is that the JRE lets you run Java programs, while the JDK comes with a compiler and lots of documentation for programmers, allowing you to create Java programs. Also note that the simulation is not compatible with Java 9 yet, which was released after the course has started.

Install Source Tree. If you have a Google account, you can authenticate with that one. When asked for connecting with a Git account, provide your Github account and clone your team repository (e.g. "team003"). You can also clone your repository manually after the installation completed. The repository URL looks like, depending on your team number. If you cannot access this URL with a web browser, try to login at and visit the page again. If that does not work, something went wrong and you should contact me.

Once you have cloned your team repository, add remote repository "" and name it "upstream" as shown above. Upstream is the original repository that always hosts the latest version of the simulation and the latest exercises.

To download the latest exercises to your computer, you first need to click "fetch" to "fetch from all remotes". This will make SourceTree show the latest available versions. To actually get them, you further need to click "pull" and then select upstream master as shown above. If you are lucky, everyhing works fine. If not, there are probably some conflicts, i.e. files that you changed locally and that also changed in the upstream repository in a conflicting way. The easiest way to resolve these conflicts, is to discard your local changes. But as long as you only change things in the exercise folders, there should not be any conflicts.

Once you have made some changes (more about that in a minute), you can either discard them or upload them to your own repository named origin. To do so, commit the changes and push them to origin as shown above. It is highly recommended to always pull the latest changes from origin before you do anything in order to avoid conflicts with your teammate. Also do this before pulling from upstream in case your teammate already did so.

To check whether your changes have been properly uploaded, you can browse your repository in the web. Once the changes are there, the simulation server will pick them up and update the simulation.

Install the latest version of eclipse.

After having installed and started eclipse, make sure it points to the latest Java JDK. If it did not detect the JDK automatically, you need to add it manually.

In the JDK settings, you should add the "-ea" flag. This enables assertions by default, making the simulations fail faster on errors, thereby making it easier to detect them. (The fail fast principle.)

Import the four agent-based simulation projects as shown above.

Congratulations, you are ready to run your first simulation locally! This will be explained in a separate document that does not exist yet. :)

“What I cannot create, I do not understand.”
Richard Feynman