Sociodynamica: Basic version (SD0)

Sociodynamica: Intermediate version (SD1)

Sociodynamica: Advanced version (SD3)

Alternate hosting at CheeseGames

Run the game by clicking on the preferred version

It may take several minutes to load the first time

It might require Firefox to run



Para la versión en Español pincha aqui

Sociodynamica simulates the economy of a territory with two resources, (Sugar and Salt; or Food and Minerals). The inhabiting agents have to consume continually both resources to survive. Agents are omnipotent if they collect and market both resources. If division of labor is implemented, farmers specialize in collecting and selling food, miners collected and sell minerals, and traders buy and sell food and minerals but do not collect resources. Commerce consists of barter (among altruists) and the use of a virtual currency for the purchase and sale of resources (among non-altuists). Altruistic agents donate their excess of resources to agents in need of that resource and use no money.

The game displays a series of unintuitive complex interactions, between pricing, maximizing wealth (accumulating resources) and maximizing health (measured by average lifespan agents achieve).

The basic version, SD0, simulates economies without price signals, as no money is involved. Simulations with agents dividing their labor show that they accumulate more resources, despite living less, compared to simulations with only omnipotent agents. Specialized agents have more restrictions in managing resources.

Important differences between altruistic-socialist economics and market-price economics arise only in more complex economic settings, such as presented in SD2. Here, the positive effect of the division of labor can be observed in more detail.

The full model, SD3 allows the design your own experiments.


Recommended Games

With SD0 you can explore the behaviour of a moneyless economy (only altruists) and evidence the synergies that arise from division of labor as compared to economies run by omnipotent agents.


With SD2 you can explore the effect of some variabes: You can play it in solitary or in pairs.


  1. Find the optimal conditions of the variables, fixing the amount of minerals and food for different run times.

  2. Find the optimal conditions of the variables, fixing the amount and price of minerals for different run times.

  3. Design a temporary program in the value of the variables to optimize vital wealth and welfare simultaneously. Optimum = average life * (amount of mineral + amount of food)

Two players:
A player sets economic variables minerals, other economic variables fixed meal. Farmers and miners competing to get the most of your resource (Food and minerals, respectively).

World Competition

Be recognized as the best gamer in the World (Emperor, Sultan, King, President or Chancellor of Sociodynamica) by sending the combination of variables that optimize the game for 60 # areas of Minerals and 90 # areas of Food. Send your chosen values to with your name. Tournaments with 100 randomly selected scenarios will update the winner every month.


With SD3 you can design and execute your own experiments by exploring the effect of different variables on the accmulation of resources, prices and the average life-expetancy of ach type of agents. If you want to go back to the initila defoult values, press RST.


Sociodynamica (detailed description)

Input data:

The left vertical bar allows to input the parameters for the simulation using the slider controls. The first is the "Contact radius”, or the radius of the area where the agent can perform commercial transactions. The second indicates the amount to be used for the "Price adjustment" after a failed transaction, where 0 is used to simulate fixed controlled prices. The third variable is a 'check-box' or control to chose whether "Division of labor" will be simulated. That is, whether all agents have the same characteristics (they are all Omnipotent), or the roles as a Farmer, Miner or Trader are performed by different agents. Farmer can only collect food, Miners collect only minerals and Traders trade but do not collect any resource. Then there are two sets of controls: one for "Minerals" and another for "Food". In each case you can set the starting “Price” of the resource; the minimum amount of resource that is never traded because it is maintained as a "Reserve" by the agents; and the number of "areas" that contain the resource.


Displaying the Simulation

In the simulation, areas with food and minerals are shown in orange and blue respectively. These are randomly generated in each simulation according to the "# areas of food and minerals" defined in the input data. A button allows you to "Create" a new simulation scenarios whenever you want, and another one allows you to "Run" or "Stop" the simulation. In "Steps"the number of iterations performed in the simulation is shown.


Viewing Results

On the right side of the screen three graphs summarize the relevant average parameters for all active agents shown. The figures for food are in orange and blue (yellow) figures correspond to minerals. The first chart from top to bottom, shows the accumulated wealth for food and minerals at the end of each iteration. The second chart shows the average price of food and minerals used b agents in their commercial interactions. The third figure shows the average age of the surviving agents (low average age is due to high mortality).



Each agent at birth has 10 units of money, and as much wealth in minerals and food. It is located in a randomly selected place and does not move. When the coordinates coincide with a food source or mineral resource, the agents may collect 2 units in each iteration. The resources are inexhaustible. Baseline consumption for each agent for both mineral and food is 1 unit for each iteration. If the agent is left without food or mineral, it dies and their values are discarded. If the agent remains alive and has an excess supply of food and/or minerals, it look for neighbors in the "Radio contact" for commercial transactions. In each transaction it tries to buy/sell under the following conditions:


- Food, if the seller is omnipotent and buyer is omnipotent.

- Food, if the seller is a farmer and the buyer is a miner or trader.

- Food, if the seller is a trader and the buyer is a miner.

- Minerals, if the seller is omnipotent and buyer is omnipotent.

- Minerals, if seller is a miner and the buyer a farmer or trader.

- Minerals are sold by trader to farmers and other traders.

The transaction is completed if the seller has more goods than it has in reserve, if the buyer has enough money and if the price at which the seller is willing to sell is less than or equal to the price the buyer is willing to pay. In this case, goods between seller and buyer are exchanged: the seller's resource maney is increased and that of the buyer decreased. The simulation shows the aggregate amount of food and minerals held by agents. The agent's width is proportional to the square root of it food. The height of the agent is proportional to the square root of its mineral wealth.

When simulation altrusits, each collector of a given product donates to an agents within their contact radius that has less than half the amount of the given resource 2 units of it.


Market Rules

If a commercial transaction failed, prices are adjusted: Te seller lowers its price in the amount indicated by the variable "price adjustment" and the buyer raises its price it is willing to pay in the same amount.



Maximizing the average life of the agents, and the accumulated amount of food and minerals.



Klaus Jaffe. First version in Unity by Noel Ramirez.

A complete versions of Sociodynamica and Biodynamica compiled in VB can be downloaded from:

Source code for Unity is at:


Academic references:
Agent based simulations visualize Adam Smith's Invisible Hand by solving Friedrich Hayek's Economic Calculus. Arxiv

Visualizing the Invisible Hand of Markets: Simulating complex dynamic economic interactions. Jaffe K. Intelligent Systems in Accounting, Finance and Management 22(2) 115-132. 2015.