Sunday, December 22, 2019

100 Days of Github. Take 2, Day 46

Day 46

Animating a billiards ball rolling around on a billiards table.
Github link here and nbviewer link here. (Nbviewer link preferred.)



This one took a while for my brain to figure out, because I wasn't thinking clearly about the ODEs. A very "d-oh" moment.

A point to note is that along with MyEps, the time step of the ODE solver plays an important role in determining how fuzzy the wall will be.

Another point to note is that the ODE solver I have used here is the very modest Euler method, because the ODE RHS function is linear in the variables, and so I don't need a higher order solver.

---
Note the lack of metrics here.

No comments:

Post a Comment