Simulate value distribution in maker networks
The model in this repository is not validated economic model, but serves as a tool to generate thoughts.
Our world is inspired by the DIDO/Fablabs model. There are 2 types of agents:
- Designers create designs from scratch or modify existing designs
- Producers use a design to create a product
All designs are public so that they can be modified or used for a product
Designers and producers have:
- A high (2) or low (1) skill level/quality (influences the quality of the design/product)
- A high (2) or low (1) sustainability (influences the consumption of resources)
- An hour fee which is (quality+sustainability)/2
- An initial amount of money
They act at random:
- Designers randomly choose to generate a new design or modify an existing one
- Producers randomly choose a design to produce (if possible)
The environment where the agents act has 2 properties:
- Cost of living: how much wealth each agent spends for each step of the simulation
- Resources: the amount of resources that can be used to produce a product
The market buys the products from the producers, subject to these properties:
- How important the price of the product is, with respect to its quality/sustainability
- Whether quality is more important than sustainability or vice versa
- How high the threshold to buy a product is
There are 3 redistribution schemes:
- Only producers are rewarded (the one who sells keeps the profit)
- Each designer involved in the design and the producer get an equal share of the profit
- Each designer involved in the design and the producer get a share of the profit proportional to their hour fee
Depending on the redistribution scheme, the price of the product is
- Only the fee of the producer
- A sum of an average fee per participant
- The sum of the actual fees of each participant
There is also a material cost per product that increases the more the resources are consumed.
- Clone this repository to a directory and cd to it.
- Install python if not present. It is suggested to do so via virtual environment manager such as miniconda.
- If using conda, create an environment, e.g.
conda create -n econsim python==3.11
and activate itconda activate econsim
. - Install Jupyter notebook:
pip install notebook
- Install various dependencies:
pip install mesa numpy pandas seaborn
- Run the notebook
jupyter notebook
and from the browser page that it launches open the filefaircontr_int.ipynb
, which is the main simulation - Run the notebook and at the last cell you can run the simulation, change the parameters, etc.
The repository also contains two other notebooks:
faircontr_expl.ipynb
, run simulations as a batch and displays some graphs, work in progressmoney_model.ipynb
is the simulation taken from the mesa tutorial on the Boltzmann model of wealth distribution
Batch simulations can also be run with python main.py
, have a look at the code to see what parameters can be given.