The gravitational force exerted by the earth on an object having mass $m$ that is a distance $r$ from the center of the earth is
$$g(r)=\left\{\begin{array}{ll}
\frac{G M m r}{R^{3}}, & \text { if } r<R \\
\frac{G M m}{r^{2}}, & \text { if } r \geq R
\end{array}\right.$$
Here $G$ is the gravitational constant, $M$ is the mass of the earth, and $R$ is the earth's radius. Is $g$ a continuous function of $r ?$