DEV Community

fakelaboratory
fakelaboratory

Posted on • Edited on

Physics: Momentum

In this experiment - the simple collision. With transferring momentum from one object to another. I split the application of momentum to the block object(see next picture) for two parts: the rotating part and the general motion part
Image description
*by coefficients of collision's point to radius

Calcs of momentum transferring, is general, thanks to:
Image description
I tried to solve it in my way, looks similar to these calcs...
Image description
Not only similar, but the same, same in Khan, same In Wolfram, same by hands, same by tables, same by code, three tests passed
Image description

Code
Just a cube directed to the wide block, possible to set masses and move the cube(left/right)

Image description
Link to play around:
https://fakelaboratory.github.io/publish/Momentum/
Source:
https://github.com/fakelaboratory/publish/tree/main/Momentum

In general same code like in the last experiment with Newton's laws, because it is a same framework, I mean masses, friction and speed(acceleration), move and rotate points. If interested in - please read the code, for notes 'll be usefull in the last article something(https://dev.to/fakelaboratory/newtons-laws-of-motion-232p)

Top comments (1)

Collapse
 
fakelaboratory profile image
fakelaboratory • Edited

I wanna to go to the particles, and liquids, maybe thermodynamics. Found ad with Gemini, maybe someone have access?(ye i restricted) Not only for Gemini request, but i think interesting to try Python with GL(not tried yet). In all videos about simulations of liquids they regularly talk about hardware limits...