Create Your Own Spring Network Simulation (With Python)
4 min readMar 20, 2021
For today’s recreational coding exercise, we will simulate a spring network: an array of nodes connected by springs that obey Hooke’s Law. The spring system will fall down due to gravity and bounce off the floor. We use a particle algorithm similar to our N-body simulation.
You may find the accompanying Python code on github.
Before we begin, below is a gif of what running our simulation looks like: