Physics, Science, Programming, Deep Dives, Thoughts And Theory.
timestep to the previous position to get the new position. To identify collisions with the walls, we simply check if the new position of a molecule exceeds either the lower or upper bounds of the dimensions of the box. If it does, we change the sign of the velocity normal to the wall, and set the