2D physics simulator
- 2 Devlogs
- 7 Total hours
A 2D free body diagram physics simulator I saw on Instagram.
A 2D free body diagram physics simulator I saw on Instagram.
I’m trying to recreate a 2D physics simulator I saw on Instagram consisting of spring, solid hallow semi circle that rocks and rolls and a sphere inside the hollow semi-circle attached to mass with gravity. Today, I couldn’t get done much since I didn’t have enough knowledge so I had to learn many new things like weighted average, moment of inertia and finally derived equation for COM (Center of mass) of the hollow solid semi-circle after watching some physics video in YouTube.
look I made a tiny physics simulator of spring-mass system under the influence of gravity. I took me 5hrs as I was learning python as well, while struggling with logic. All the graphics here is created using code using libraries like pygame and numpy and to create that spring coil I have to use cosine and sine function which was hard to visualize in 2D as school only taught us to click it in calculator. That really fried my brain.