Verlet Integration for Physics Simulations

Поделиться
HTML-код
  • Опубликовано: 14 окт 2024
  • #breakthroughjuniorchallenge #breakthroughjuniorchallenge2023
    Physics simulations are everywhere, and many of them are based on Verlet integration. In this video, you will learn how these simulations are made.
    This video was created for the 2023 Breakthrough Junior Challenge.
    All math animations in this video were created using Grant Sanderson's Manim library. For more information on Manim, see github.com/3b1b/manim

Комментарии • 16

  • @zippolag
    @zippolag 4 месяца назад +1

    short and to the point, great work! Keep 'em coming!

  • @tusharkuntawar6170
    @tusharkuntawar6170 6 месяцев назад

    Amaaaazing, and just what I needed. Amazing!!

  • @RitvikG299
    @RitvikG299 Год назад +3

    damn this is good

  • @VisualizingScience-dq1jt
    @VisualizingScience-dq1jt  4 месяца назад +1

    @llufabluff4700 noticed that in the final algorithm at the end, constraints are run before the Verlet equation. The correct order should be the Verlet equation, then the constraints. How it's shown in the video, the Verlet equation could override the constraints.

  • @cmedia425
    @cmedia425 6 месяцев назад

    Amazing short explanation! What editing software is used to edit those text transitions? I'm seeing them in many math/physics videos.
    Edit* I just looked at the description

  • @protasov-by
    @protasov-by 8 месяцев назад

    Hello, how to extract distance passed with acceleration time from Velocity Verlet? Like I have acceleration time 2s, and MaxSpeed for example 4000, and distance remains I wish to know somehow in between integraion step, like get current speed, compute dist remainder (since on max speed dist and acceleration should be 0) then do Integrate(dt)... Classic formulas seems for constant velocity and time in seconds, where in verlet our seconds is stripped to FPS amount. dt = 1/ fps etc... That make me bad time of real distance object passed from some velocity to 0 speed (braking) through deceleration and classic formules produce distances like 20-50 times longer than factually object is passing....

    • @VisualizingScience-dq1jt
      @VisualizingScience-dq1jt  8 месяцев назад

      Thanks for asking. Since the Verlet equations account for dt, the frame rate shouldn’t be a problem. However, may I ask how you are slowing down the object? (Continually stepping down velocity doesn’t work; you have to set the acceleration.) I apologize if this does not answer your question.

    • @protasov-by
      @protasov-by 8 месяцев назад

      @@VisualizingScience-dq1jt when conditions tells that I wish to stop, i do set linear acceleration as dir * (maxSpeedConst - current_speed) / timeToStop * scaler. direction is unit vector that is difference between my desired stop point and current origin of body. I use scaler that goes from 0.01 to 1 in range of where current speed is in terms of max speed. Since I need dynamically determine deceleration time and not keep it constant in any dist remainder. So this looks natural when object slowdown. And conditions to tell it to go in deceleration state is some distance like two points is moving, and distance between is 250 for example, then one is stop and at some point I need to estimate that my stop distance is enough not less not more to perfectly stop in this desired point, there where problems of distance occurs, If I predefined something like 200 for distance all ok, but if I put each frame current velocity and time to perform deceleration my distance is like even bigger value than max speed const, while this const is 4000, and current speed not goes more than 1500 🤗 i tried different formulas, ask chat bots nobody know what is dynamic acceleration or deceleration ether. They like can do some calculus and recommend me to memorize all values computed for frame where i decide to perform stopping, and then just interpolate positions which is works for now but is not physically right…

    • @VisualizingScience-dq1jt
      @VisualizingScience-dq1jt  8 месяцев назад

      I have never tried anything like this, unfortunately. Does this look like it answers your question? stackoverflow.com/questions/1088088/how-to-calculate-deceleration-needed-to-reach-a-certain-speed-over-a-certain-dis

    • @protasov-by
      @protasov-by 8 месяцев назад

      @@VisualizingScience-dq1jt well it seems partially what I did, but I read it more deeply and try if this helps, anyway Thanks in advance!

  • @llufabluff4700
    @llufabluff4700 5 месяцев назад

    Hello, in the pseudo code show in the end, the constrains are treated before Verlet. Couldn’t that cause that at the end of the iteration, some constrains were broken?
    Thanks in advance!

    • @VisualizingScience-dq1jt
      @VisualizingScience-dq1jt  4 месяца назад

      Ah yes, you're right! It is better to run the constraints after repositioning with the Verlet equation. Thanks for pointing that out.

    • @llufabluff4700
      @llufabluff4700 4 месяца назад

      Okey, thank you

  • @stevedoetsch
    @stevedoetsch 6 месяцев назад

    Guy just delivered a 6-month PhD level physics class in less than 120 seconds. 😂

  • @ballballab123
    @ballballab123 3 месяца назад

    this animation made from manim ?