In physics, Hooke's law is an empirical law which states that the force (F) needed to extend or compress a spring by some distance (x) scales linearly with respect to that distance.
$$F_{s} = -kx$$
where,
\(F_{s}\)ā the force applied to the spring;
kā the spring constant (a measure of the stiffness of the spring);
xā the displacement from the equilibrium position.