Single Loop Roller Coaster

Oh, I don’t feel so good1.

Peter Griffin

Gravity is a contributing factor in nearly 73 percent of all accidents involving falling objects.

Dave Barry


I know that in cartoons the laws of physics are different2, but none of O’Donnell’s laws of cartoon motion seem to apply and there are a few things in this little clip that suggest the makers actually thought about this problem so I decided to find out if it is possible for Peter to be at the right place at the right time to catch his own puke. 

That there are a few things right does not mean that there is not something wrong. The radius of the loop, which I will call \(a\), is approximately three times the distance of the head of sitting Peter to the track, which I will call \(h\). When producing the gif I needed to take 3.2 seconds as the length of one loop. This number allows me to calculate the radius, because I know that the free falling puke needs 1.6 seconds to go from Peter’s mouth at the top top to his mouth at the bottom. The distance \(s\) travelled by a free falling object starting from rest in \(t\) seconds in a gravitational field is:

\[ s = \frac{1}{2}gt^2\]

where \(g=9.81\)m/s2 is the acceleration due to gravity. The puke falls from Peter’s head on top to Peter’s head at the bottom, which means that

\[ 2(a-h) = \frac{1}{2} \times 9.81\times (1.6)^2= 12.6\,{\rm m}\]

which can be solved for \(a\):

\[ a = h + 6.3\,{\rm m}\]

Since \( a\approx 3h\) This would mean that \(h\approx 3.2\,\)m, whereas Peter’s physique  and the shape of the car suggests it cannot be much more than about 1 m. The loop should have been drawn about three times larger. If I take \(h = 1\)m, then the radius of the loop is \(7.3\,\)m, which is what I will use as value in the remainder of this post. Which makes the highest point about 15 m above ground.

The car coming almost to a full stop at the top is correct. If he would still be moving, the puke would have a forward motion as well, and never go down in a straight line, but follow a parabola. In the picture \(v_t\) is the forward velocity of the cart at the top, and the vomit follows the curve. In Newton’s words: “An object in motion tends to remain in motion along a straight line unless acted upon by an outside force”. There are two outside forces, gravity, but that only acts in the vertical direction, and friction, which we will ignore3. Of course Peter could barf backwards with exactly the same speed so as to compensate for the forward motion, but this is not obvious from the movie.

Now we have a problem: although the acceleration due to gravity is the same for Peter as for the spit, Peter follows a longer path, so it seems unlikely that they arrive at the same time at the bottom of the loop. But the first question I wanted to answer was if it is at all possible that they arrive at the same time at the bottom. And the answer to that is, yes, they can, but ….

To solve this problem we need to write down the equations of motion and in order to do that, I set up a coordinate system. In principle the motion is three dimensional, but we only need two dimensions which I choose to name \(x\) in the horizontal direction and \(z\) along the vertical. Furthermore I choose the origin of my coordinates at the centre of the loop. The mass \(m\) denotes Peter and the cart. At point \((x,z)\) on the loop, Peter has velocity \(\vec v\), and the force \(\vec F\) acts on him in the downward direction \(-\hat z\). At the bottom of the loop Peter has coordinates \((0,-a)\) and at the top \((0,a)\).

The equation of motion that the mass has to satisfy is

\[ m\frac{d\vec v}{dt} = \vec F= -mg\hat z\]

If this were all, Peter’s motion should also be a parabola, but  he is in a roller coaster and his path has to be a circle. This is what we physicist call constrained motion, and because there is a relation between the coordinates

\[ x^2+z^2 = a^2\]

this is called a holonomic constraint. For this type of constraint we should look for a generalized coordinate to describe it4.  It is easy to find such a coordinate in this case. In view of the above relation between \(x\) and \(z\) it is very suggestive to start with:

\[ x = a\sin\theta\quad\mbox{and}\quad z = -a\cos\theta\]

and \(\theta\) can act as a generalized coordinate. The restriction is automatically satisfied, since \(\sin^2\theta + \cos^2\theta =1\). The equation of motion involves the velocity so we have to express this in the coordinate \(\theta\) as well. For both components I get

\[v_x = \frac{dx}{dt} = \frac{d}{dt}a\sin\theta = a\cos\theta \frac{d\theta}{dt}\]


\[v_z = \frac{dz}{dt} = -\frac{d}{dt}a\cos\theta = a\sin\theta\frac{d\theta}{dt}\]

We could put this directly  in Newton’s equation of motion, but that involves taking another derivative with respect to time, and there is an easier way to get to the desired equation of motion for the generalized coordinate \(\theta\) by using the principle of energy conservation. The total energy of the system is given by

\[ E = \frac{1}{2}mv^2 + mg(z+a)= \frac{1}{2}ma^2\left(\frac{d\theta}{dt}\right)^2 + mga(1-\cos\theta)\]

where I put the zero of the potential energy at \(z=-a\), (\(\theta = 0\)), and expressed everything in the coordinate \(\theta\). Since the energy remains constant during the motion we can use it as a parameter, and write the equation of motion for the angle \(\theta\) as

\[ \frac{d\theta}{dt} =\sqrt{ \frac{2E}{ma^2} + \frac{2g}{a}\left(\cos\theta -1\right)}\]

Before attempting to solve an equation like this it is always a good idea to do some elementary checking to see if we did not make any stupid mistakes. First of all, the dimensions need to be correct.  The left hand side of this equation has dimension s-1, so the right hand side has to have that as well. \(E\) is in J, which is kg m2s-2 so that [\(E/ma^2\)] = kg m2s-2/kg m2 = s-2, and the square root of that is indeed s-1. The second term gives the same result. So if we did something wrong, it is not here. The second thing to check is if all this makes physical sense.

Classical quantities have to be real, imaginary or complex numbers are not allowed. This means that the argument under the square root in the equation of motion has to be positive, and this in turn puts a restriction on the angle \(\theta\): only values of \(\theta\) are allowed such that

\[ \cos\theta \ge 1 – \frac{E}{mga}\]

If \( E = 0\), only \(\theta = 0\) Is allowed. That makes perfect sense: if the total energy is zero, both the kinetic an the potential energy have to be zero, and this can only be the case if the car is at rest at the bottom of the loop. For positive values of \(E\) more values of \(\theta\) are allowed but only  when \( E\ge2mga\) all angles are allowed and a complete loop can be made. This also is according to what we expect. Only if at the top of the loop, where the potential energy is equal to \(2mga\), there is some kinetic energy left (can be marginally more than zero, as in the cartoon), a loop can be completed. If the total energy is less than \(2mga\) the car cannot reach the top, and the motion will be more like that of a pendulum: the car goes up, before it reaches the top the velocity is already zero, and it starts falling back.  And so on and so forth. So far there seems to be no problem with the equation I derived, and it makes sense to attempt to solve it.

There are two constants in the problem, the radius of the loop \(a\), and the gravitational constant \(g\).We can get rid of these constants by scaling time and energy. This way we simplify the numerical procedures, which are needed in this case , we reduce the possibility of errors, and the solutions can be used for many different situations, a 300 m loop on the moon, for instance. I do this by rewriting the equation as

\[ \frac{d\theta}{dt} =\sqrt{\frac{2g}{a}}\sqrt{ \frac{E}{mga} + \left(\cos\theta -1\right)}\]

If I now define a dimensionless time and energy as respectively

\[ \tau = \sqrt{\frac{2g}{a}}t\quad\mbox{and}\quad \epsilon = \frac{E}{2mga}\]

the equation of motion can be written

\[ \frac{d\theta}{d\tau} = \sqrt{\epsilon +\cos\theta -1}\]

an equation that looks much simpler (but is not), and only contains one parameter \(\epsilon\) which completely determines the motion of peter for any given energy. Unfortunately there is no easy analytical solution to this equation5, so we have to resort to numerical methods. Even the period of the motion as function of the energy, which is the definite integral

\[P(\epsilon) = \int_0^{2\pi} \frac{d\theta}{\sqrt{\epsilon +\cos\theta -1}}\]

cannot be expressed in terms of elementary functions. It is not too hard to write a program, however, to do the calculations for you, for almost every programming language there are libraries for solving Ordinary Differential Equations (ODE’s)6.

This is a simulation of the motion of the cart with Peter with the same period as the cartoon. What is shown here is the height of the car above the bottom of the loop. It starts at the bottom (\( z=-a\) at \(t=0\)), with enough velocity to go over the top. At reduced time \(\tau = 2.6\) it reaches the top at \(z=a\) and then starts falling down again. For the value of \(a = 7.3\,\)m determined in the beginning \(t=0.61\tau\), which means that for \(\tau = 5.25\) the period is equal to \(3.2\,\)s, just as in the clip. This curve corresponds to a value of \(2.7\) for \(\epsilon\), or \(E=2.7mga\). We don’t know what the mass is of Peter and the cart, but that is irrelevant for the calculation of the speed at the top of the barrier:

\[ \frac{1}{2}v^2 = 0.7ga \quad\mbox{or}\quad v = \sqrt{1.4ga}\approx 10\,{\rm ms^{-1}}\]

This proves that the writers were way off, 10 m/s is about the speed the fastest sprinters can achieve (100 m in 10 s). I doubt if Peter could spit fast enough in the opposite direction to counteract this so as to make the puke go straight down.

We can conclude that Seth MacFarlane was correct in making the car move very slowly at the top, but this also makes it impossible for Peter to swallow his own spit at the bottom. This is only possible if he goes much faster and projectile vomits it in the opposite direction of his motion at the top.


[1] What is, with the parameters given, Peters velocity at the bottom of the loop?

[2] Show that the period of the motion goes to infinity if we let \(\epsilon\to 2\). Why is that?

[3] Does the fact that on the way down Peter weighs less (top-Peter – puke) for the period of the motion?

[4] Could a change in loop size or gravitational constant make it possible for this to work?

[5] In the cartoon the motion appears to be asymetric: faster acceleration going down than decelaration going up. Is this correct?

[6] Is it possible for Peter to barf at another position to catch it again exactly at the bottom?


[1] Clip from season 16 episode 2: “Foxx In The Men House”.

[2] It has its own wikipedia lemma: O’Donnell’s Laws of Cartoon Motion can be found here.

[3] Obviously the  friction on the car is ignored by the makers, and the air friction on the barf can be ignored in view of the small distance travelled. 

[4] H. Goldstein, Classical Mechanics, Addison-Wesley Publishing Co., (1972),  p. 10.

[5] The variables can be separated, and \(\tau = \int \frac{d\theta}{\sqrt{\epsilon+\cos\theta -1}}\) reduced to an elliptical integral. This is already messy, and in addition in order to find \(\theta(t)\) we would have to invert that. There is no hope  of finding a simple expression. There is no need to either.

[6] I used Java for reasons I don’t care to explain, with the Apache Commons Mathematics Library:




Leave a Reply

Your email address will not be published. Required fields are marked *