a barnsley fern rendered in python's matplotlib
I saw an interesting post on /r/factorio where a user had made a display out of lamps, and used them to plot a Barnsley fern.
Seeing that it could be achieved in Factorio’s circuit system, I thought it wouldn’t be too hard to try and render a Barnsley Fern in python’s popular plotting library, matplotlib. These are the results of those efforts.
I read a lot for this project, here’s a short list of links that I found particularly useful.
- The wikipedia article on Barnsley ferns
- Python’s generator documentation
- matplotlib’s animation documentation
- This matplotlib tutorial which also plots a Barnsley fern
view the code on github
You can view the code for this project in its repository on github, here.