Points are nothing but vectors on the screen. This vector is changed over time each frame according to different forces being applied to it. i.e. gravity.
If the point is not anchored:
Apply forces such as gravity and any other forces initialized.
Calculate the points velocity.
If the point is part of a Rigid body, divide the force by the body’s mass.
Now apply friction if the point is touching the edge of the screen or any other rigid body.
OR
Apply air friction if the point is not touching the edge of the screen or any other rigid body.
Limit the velocity from crossing the max velocity allowed.
Finally, add the velocity to the point’s position
Constraints do the job of keeping two points together in place and maintain a uniform distance between them.
3 types
Each constraint has a different way of solving the positions of the two points.
For Rope constraints:
Check if the two points are too close or too far from each other.
Calculate the offset percentage between the ‘rest length’ and the current distance between the points
$\frac {(r - c)} r$
Calculate the force and then apply half the force to each point in opposite directions.
$F = (a - b) × \frac {(r - c)} r × \frac 1 2$