Тёмный

The Double Pendulum in PYTHON 

Mr. P Solver
Подписаться 134 тыс.
Просмотров 31 тыс.
50% 1

In this video I derive the system of differential equations for the double pendulum using sympy, solve the system of equations numerically using scipy's odeint function, and create an animation of the double pendulum using matplotlib.
Code:
github.com/lukepolson/youtube...
Discord:
/ discord
Spinning Top:
• Solving The Equations ...
Double-Springed Pendulum:
• The Double-SPRINGED Pe...

Наука

Опубликовано:

 

29 июн 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 45   
@fateenahmed659
@fateenahmed659 2 года назад
This is exactly what i was looking for. Thank you for the amazing tutorial and explanation!
@blackguardian89
@blackguardian89 2 года назад
Mr. P Solver uploaded a new video... This day just becomes better :) Double pendulum - absolute classics! Thanks, man!
@adityaariewijaya9284
@adityaariewijaya9284 2 года назад
You're a very good teacher. Thanks for this. Would there be any future video on FEM on Python?
@cambridgebreaths3581
@cambridgebreaths3581 2 года назад
Man you are a blessing. Thank you a million. Can you please just recommend a perfect starting point to learn differential equations for a beginner from 0 to 1 , with the same level of depth, clarity and and an ultimate goal to master the all the variety of diff equations to the highest level possible. Thank you kindly again
@MrPSolver
@MrPSolver 2 года назад
I think for next week I'll make an entire video just about differential equations in python.
@cambridgebreaths3581
@cambridgebreaths3581 2 года назад
@Mr. P Solver Brilliant. Am sure it will be mesmerising. Thanks
@hsh7677
@hsh7677 2 года назад
@@MrPSolver can’t wait!!!
@mingshey
@mingshey Год назад
Whoa, wonderful job! I’ve been working on the same problem with Maxima. The process is essencially the same. I’ve been expanding the program to deal with generic number of multiplicity of the pendula. But the burden of symbolic manipulation of differential equations grew above the capacity of my computer when the number of bobs was larger than 4. I think I should try to attack the problem in colab with sympy. Great thanks for sharing!
@hsh7677
@hsh7677 2 года назад
Thank you so much!! Very helpful!
@julyatonon5115
@julyatonon5115 2 года назад
incredible video, i learnt a lot. thank you.
@prietjepruck
@prietjepruck Год назад
Great explanation, thanks a lot.
@alekseykozin8108
@alekseykozin8108 Год назад
You are awesome, thank you very much for your work
@agustinbrusco7173
@agustinbrusco7173 2 года назад
really good video, thanks a lot. although I must admit I arrived hoping for some insight into the physics.mechanics module of sympy. Are there any reasons you choose to do things this way? I also use sympy like you did in the video, but I'm interested in knowing if there are any advantages on learning the whole sympy.physics.vectors and .mechanics, over just implementing the sympy variables and functions like this anyway, you just earned a follower, greetings from Argentina!
@AryVinicius
@AryVinicius 2 года назад
Awesome video. I'll give this a try to practice. Maybe the next video is about adding friction in the joints? 🤔
@MrPSolver
@MrPSolver 2 года назад
This is a fantastic idea! Definitely will show up in a future video
@GuizinGuizao
@GuizinGuizao 9 месяцев назад
Great video and excellent git
@ilyashulika3538
@ilyashulika3538 2 года назад
What a great video )))
@AJ-et3vf
@AJ-et3vf 2 года назад
Awesome! Immediately saw this right now on being uploaded and immediately watched. Once again, very nice and inspiring. Now next do a spherical double pendulum 😁😁😁 haha jk.
@ItumelengS
@ItumelengS Год назад
High quality stuff here😮
@babajani3569
@babajani3569 2 года назад
Hello. Sorry about my ignorance. I don't actually know much about programming but I had a question if it is all right with you. Did you solve the Euler Lagrange equations using the Runge Kutta method? If not then is there to just immediately employ the Runge Kutta method to the Lagrange's of motion without deriving them first on python. Thank you.
@AmoghavarshaN
@AmoghavarshaN 2 года назад
Awesome
@Serena-nm8sd
@Serena-nm8sd 2 года назад
Hi, thank you so much for this. I was wondering, what do simplify=false and rational=false mean? Thank you in advance
@shohrehhoushmandsajjadi1861
@shohrehhoushmandsajjadi1861 2 года назад
Thank you so much for such a nice presentation. It was greatly helpful. Could you also go through plotting time and energy of the system?(E=T+V)
@lucid_
@lucid_ 10 месяцев назад
Wouldn’t that be constant? Assuming we ignore air resistance
@nsumanth18
@nsumanth18 2 года назад
Nice video! A doubt - How to trace the path of the two pendulums?? i.e. How to make their path visible?
@owisalsabbagh7577
@owisalsabbagh7577 7 месяцев назад
very nice explaination, I tried using the same principle to simulate a double inverted cart pole. After adding and modifiying the equations to include a cart and its movement and the force applied on it , but I faced an error when trying to use odeint the way you explained in the video. any tips?
@ivolol
@ivolol 2 года назад
You might consider making a video that could use a PID to get the pendulum holding upright? Not sure if PID works for that or not
@marijnpf
@marijnpf 2 года назад
Have you found a way?
@JulieStardoll
@JulieStardoll 2 года назад
could you do one on solving kepler problem?
@scar6073
@scar6073 2 года назад
I'm coding it as I'm watching. Planning to impress my friends lol
@marcrindermann9482
@marcrindermann9482 Год назад
is there a reason not to simplify the expressions for the second derivatives?
@h2o11h2o
@h2o11h2o Год назад
nice
@Kakikiwi-eu2kr
@Kakikiwi-eu2kr 10 месяцев назад
I'm trying to replicate, and I've got one little ugly problem: sympy outputs are not wrapped into multiple lines like he has for cell 24, 27, etc. I get one loooong line I have to scroll through. Anyone faced that problem ?
@mindeys
@mindeys Месяц назад
Looks like 3 body problem. Also has 3 points.
@jiswinvarghese1326
@jiswinvarghese1326 2 года назад
list index out of range 'tuple' object is not callable i got these errors in the last line of code "ani.save('double_pendulom.gif',writer='pillow',fps=25)" . so could not run see the animation. apart from that everything was fine.
@gerrievanstaden3416
@gerrievanstaden3416 2 года назад
I had the same issue. My fix was that I made a spelling error in my animate function. After I fixed that it worked perfectly
@jiswinvarghese1326
@jiswinvarghese1326 2 года назад
@@gerrievanstaden3416 Thanks bro i will lookinto that
@user-lo2qv8wz8f
@user-lo2qv8wz8f Год назад
love from outerspace
@muhammadikbal8944
@muhammadikbal8944 2 года назад
why is my animation not moving?
@I_am_FRANCO
@I_am_FRANCO 10 месяцев назад
22:22 friction¿
@haritssyah7434
@haritssyah7434 Год назад
your face takes up quite a bit of the screen, blocking anything behind it
@I_am_FRANCO
@I_am_FRANCO 10 месяцев назад
7:51
@skillick
@skillick 2 года назад
If your animation isn't working at the end, check the second last line, try changing it to: ani = matplotlib.animation.FuncAnimation(fig, animate, frames=1000, interval=50)
@deusexmachina3091
@deusexmachina3091 Год назад
That didn’t work for me any other ideas? Everything seems fine but the animation is just generating an image not a gif.
Далее
Photon Beam Attenuation in Python
18:55
Просмотров 5 тыс.
The Double-SPRINGED Pendulum in PYTHON
28:27
Просмотров 13 тыс.
КВН 2024 Высшая лига Четвертая 1/4
1:52:57
Grad School Be Like...
3:35
Просмотров 96 тыс.
Python Libraries Be Like...
2:30
Просмотров 95 тыс.
When Your Code Runs Without Errors...
2:23
Просмотров 115 тыс.
Coding Challenge 93: Double Pendulum
31:11
Просмотров 915 тыс.
Chaos: The Science of the Butterfly Effect
12:51
Просмотров 7 млн
Coding Challenge #159: Simple Pendulum Simulation
22:14
Mac Studio из Китая 😈
0:34
Просмотров 153 тыс.