Hi everybody!

I am back with another small game dev exercise, and this time, I am tackling a fascinating piece of physics.

Showing a strange behavior, also referred to as chaotic motion, the double pendulum will be our simulation for today. This simulation is said to have a "sensitive dependence to initial condition", meaning that the slightest alteration in the position, length, and/or mass of any pendulum or pretty much anything else (gravitational constant, air pressure, rigidity of the string, etc...) at the beginning of the simulation will have a huge impact on the evolution of that said simulation. Of course, we won't be able to change the air pressure or the rigidity of the string here (sadly), but we will be able to modify the core components of the pendulum.

*This simulation is not using the default Unity physics system. Instead, it is simply calculating the position of each pendulum depending on the velocity and angular acceleration of both pendulums, each frame.*

The controls are very simple and will require a keyboard (pretty much only the [Space] key) and a mouse. In this simulation, you will be able to modify the position, length, and mass of each pendulum.

*I feel like this project is finished but I may end up adding a couple features in the future, like a way to come back to the previous initial state of the pendulum to be able to observe the differences when modifying some initial conditions, a way to modify the gravitational constant (G), or modifying a dampening value (used here is this simulation) in-game, or even different presets for the trail...*

This small project has been developed using Unity 2019.3.

You can 100% use this project, without any limitation. (...credits are still appreciated though :))

Stay safe and thank you for taking a look at this very cool simulation!

Hope to see you on the next project.

Sincerely,

PtitPoly

PS: I am thinking about starting a Youtube channel with some tutorials on the development process of those little exercises. Leave me some comments if that is something you might enjoy or not...

StatusReleased
PlatformsWindows, HTML5
Rating
Rated 5.0 out of 5 stars
(3 total ratings)
AuthorPtitPoly
GenreSimulation
Made withAdobe Photoshop, Unity
Tags2D, animated-background-worthy, chaos, chaos-motion, double-pendulum, pendulum, Physics, Relaxing, Unity
Average sessionA few minutes
LanguagesEnglish
InputsKeyboard, Mouse

Download

Download NowName your own price

Click download now to get access to the following files:

DoublePendulum_Standalone.zip 19 MB

Comments

Log in with itch.io to leave a comment.

(+1)

So, uh, you can make the masses negative, and uh.. oh god...

(1 edit)

Lol! So yeaaaaah... there is definitely things I should have been addressed but it has been so long since I worked on this project that I kinda gave up updating it.

I am actually thinking of getting back onto two of my projects on here (this one and Conway's Game of Life) and give them the love they deserve. I had a blast working on these in the past and I believe I can improve both of these in many ways.

I am thinking of using ECS and especially DOTS for Conway's Game of Life to drastically improve the performances, while optimizing the simulation with some new ideas.
*I would love to create a little tutorial on the whole process (from the project creation to the end) since I haven't found many project-length ECS tutorials out-there... Since ECS is still quite new in Unity, I think this could be a great way to get some people more familiar with the technology and a great challenge for me all-together!

For this one in particular, I would like to improve the controls and add what this whole simulation is about: a way to visualize the difference in the sightliest change in initial properties (bob mass, string length, etc...). And... I have a few other ideas to improve the simulation overall.

Stay tuned for (probably) a massive overhaul of both projects (if you are still interested..) :)

(+1)

yeah can you like make a tutorial or summin

So, I am currently almost done re-working the whole simulation. I added many features and ways to add new double pendulums to the simulation. There will be a list of all the controls/shortcuts available and the opening message will also state the changes and what can be done in the simulation.

I think I will be done with everything by the end of the week and thank you for checking the game out !! :D

(+1)

cool i was trying to understand double pendulums and found this gem

(1 edit)

After re-reading my sum up for this project again, I believe you were referring to the YouTube video showing the development process of this simulation.

And to that, I will say YES ! Definitely ! :)

It will take me a little while to make because I am not a video editor but that can be a very good challenge. And if that can help someone in the process, definitely !