The dynamic visualization of vector calculus fields related to rigid body rotation. The script calculates and plots six quantities in the $x y$-plane: the velocity field ( $v$ ), the acceleration field ( $a$ ), and their respective divergence ( $\nabla \cdot v, \nabla \cdot a$ ) and $z$-component curl ( $\nabla \times v, \nabla \times a$ ). The animation runs through a sequence of varying angular velocity ( $\omega$ ) and angular acceleration ( $\dot{\omega}$ ) to demonstrate how these parameters directly influence the fields: the curl of velocity is shown to be proportional to $\omega$ (representing vorticity), while the divergence of acceleration is proportional to $-2|\omega|^2$ (related to centripetal force), and the curl of acceleration is proportional to $2 \dot{\omega}$ (related to the tangential force).

🎬Narrated Video

https://youtu.be/YLvijYirS1M


The conservative_field_demo visually proves the path-independent nature of the centrifugal force by simulating two particles traveling between the same points via vastly different routes-one direct and one winding. As the particles move through the background potential map ( $\Phi=\frac{1}{2} \omega^2 r^2$ ), a real-time work tracker demonstrates that despite their different trajectories, both particles accumulate the exact same amount of total work upon reaching the destination. This convergence numerically confirms that the field is conservative ( $\nabla \times a_c=0$ ), illustrating that the work done in a rotating frame depends solely on the change in radial distance rather than the path taken.

🎬Centrifugal Potential and Path

https://youtu.be/sA9Z5HFn87o


The centrifugal_energy_demo illustrates the conservation of energy in a rotating frame by simulating a bead sliding outward along a frictionless rod. It demonstrates that centrifugal potential energy ( $\Phi=\frac{1}{2} \omega^2 r^2$ ) is essentially the "latent" tangential kinetic energy of the frame, which is converted into radial kinetic energy as the bead "falls" down the potential hill toward larger radii. By tracking the sum of the decreasing potential and increasing radial kinetic energy, the simulation confirms that total energy remains constant, proving that the fictitious centrifugal force behaves as a conservative field that governs motion according to the work-energy theorem.

🎬Bead released from rest (relative to rod) on a frictionless rotating rod

https://youtu.be/IyQuyEBOELc


The Orbital Potential Well Simulation demonstrates how planetary stability arises from the competition between inward gravitational pull and the outward centrifugal barrier, which together form a stable "effective potential valley." By synchronizing a 2D orbit with a 1D potential graph, the simulation reveals that a planet’s radial motion is essentially a 1D oscillation—or "sloshing"—between two turning points known as periapsis and apoapsis. At these boundaries, the planet's radial velocity drops to zero as its energy is fully utilized by the potential, causing it to "bounce" back toward the center. Crucially, the steep centrifugal barrier at small radii ensures that a planet with angular momentum can never crash into its sun, as the outward repulsive force eventually dominates gravity at close range.

🎬Orbital Motion (Real Space) and Sloshing in the Potential Well

https://youtu.be/B5xeSDubAXE


🪜State Diagram: From Vector Fields to Orbital Stability