Various folk have made comments which relate to the answer, some have even spelled out the answer but I haven’t yet come across an explanation of the logic and the maths.
Logic tells everyone who first encounters this problem that the distance covered by the small circle (r) is 2pi times the radius of the large circle (R). That seems right but it isn’t, the distance covered by the small circle is 2pi times (R + r) as that is the point which remains “still” throughout the whole rotation.
If we consider a small circle 1/3 the diameter of the large one then
r=R/3 or 3r = R thus radius of rotation is 3r+r, lets call this Rc
Distance covered is circumference of the circle Rc divided by circumference of small circle r.
It is the smaller circle which is moving therefore distance covered is
2pi (3r + r) / 2pi (r) or (2pi*Rc / 2pi*r)
The 2pi elements cross out so we are left with
(3r + r)/ r = 4. QED

I don’t have the ability to draw here, but if you want to sketch it out it makes much more sense.

Various folk have made comments which relate to the answer, some have even spelled out the answer but I haven’t yet come across an explanation of the logic and the maths.

Logic tells everyone who first encounters this problem that the distance covered by the small circle (r) is 2pi times the radius of the large circle (R). That seems right but it isn’t, the distance covered by the small circle is 2pi times (R + r) as that is the point which remains “still” throughout the whole rotation.

If we consider a small circle 1/3 the diameter of the large one then

r=R/3 or 3r = R thus radius of rotation is 3r+r, lets call this Rc

Distance covered is circumference of the circle Rc divided by circumference of small circle r.

It is the smaller circle which is moving therefore distance covered is

2pi (3r + r) / 2pi (r) or (2pi*Rc / 2pi*r)

The 2pi elements cross out so we are left with

(3r + r)/ r = 4. QED

I don’t have the ability to draw here, but if you want to sketch it out it makes much more sense.