Beating the Odds: The Sheer Improbability of Being Here

visual.ly posts and hosts some excellent graphics. The one below, calculates the nearly infinitesimal probability of just being born. There’s hardly a better argument for appreciating life.

It’s also a good example of working with probabilities [and] exponents. Very large exponents.

by visually via

Projectile Motion

Abstract

A series of still photographs of a projectile (soccer ball) in motion were used to determine the equation for the height of the ball (h(t) = 4.9 t2 + 14.2 t + 1.25), the initial velocity of the ball (14.2 m), the maximum height of the ball (11.6 m), and the time between each photograph (0.41 s). The problem was solved numerically using MS Excel’s Solver function. There are much easier ways of doing this, which we did not do.

Introduction

Figure 1. Calculated elevation of the soccer ball after launch.
Figure 2. Animation of the soccer ball projectile.

One of physics lab assignments I gave my students was to see if students could use a camera to capture a sequence of images of a projectile, plot the elevation of the projectile from the photographs, determine the constants in the parabolic equation for the height of the projectile, and, in so doing, determine the velocity at which the projectile was launched.

I offered my old, digital Pentax SLR that can take up to seven pictures in quick sequence and be set to fully manual. A digital video camera with a detailed timestamp would have been ideal, but we did not have one available at the time.

Now the easy way of getting the velocity data would be to estimate the heights (h) of the ball from the image using some sort of known reference (in this case the whiteboard), and determine the time between each photograph (Δt) by photographing a stopwatch using the same shutterspeed settings. After all, the average velocity of the ball between two images would be:

! \bar{v} = \frac{\Delta h}{\Delta t}

The reference whiteboard is four feet tall (1.22 m) in real life, but 51 pixels tall in the image. Using this ratio (i.e. 1.22 m = 51 px) we can convert the heights of the ball from pixels to meters:

Table 1. Table showing the conversion of the height of the ball in pixels to elevation (in meters).

Unfortunately, I think my students forgot to do the pictures of the stopwatch to get Δt, the time between each photograph. Since the lab reports are due on Monday, and it’s the weekend now I’m curious to see what they come up with.

However, I was wondering if they could use just the elevation data to back out the Δt. So I gave it a try myself. Even the easiest way of solving this problem is not trivial, in fact, I ended up resorting to Excel’s iterative solver to find the answers. While this procedure probably goes a little beyond what I expect from the typical high school physics student, more advanced students who are taking calculus might benefit.

Procedure

We took the reference whiteboard (1.21 m tall), a soccer ball, and the camera outside. The whiteboard was leant vertically against the post of the soccer goal. The ball was thrown vertically by a student standing next to the whiteboard (see Figure 1) while pictures were taken. The camera’s shutterspeed was 1/250th of a second. The distance from the camera to the person throwing the ball (and to the whiteboard) were not measured.

The procedure was repeated several times, but only one trail was used in this analysis.

The images were loaded onto a computer, and the program GIMP was used to determine the distance, in pixels, from the ground to the projectile. The size of the reference whiteboard, in pixels, was used to calculate the height of the soccer ball in meters.

The elevations measured off the photographs were then used to calculate the release velocity, time between snapshots, and maximum height of the ball.

The Equation for Elevation

I started with the fact that once the ball is released, the only force acting on it is the force of gravity. Since the mass of the ball does not change we only have to consider the acceleration due to gravity (-9.8 m/s2). I also neglect air resistance to make things easier.

Finding the Velocity Equation

Start with the fact that, acceleration is the rate of change of velocity with time. You can write it in the differential form:

! a = \frac{dv}{dt} = -9.8

so we integrate with respect to time to get the equation for velocity as a function of time:

! v(t) = \int -9.8 dt

! v(t) = -9.8 t + c

where c is an unknown constant. What we do know though, is that at the beginning, when the ball is just launched, time is zero (t = 0) so cv becomes the initial velocity (v0) at which the ball is thrown:

at t = 0, v(0) = v0:
! v_0 = -9.8 (0) + c

! v_0 = c

So our velocity equation becomes:

! v(t) = -9.8 t + v_0

Finding the height equation

Now since we know that velocity is the rate of change of distance (in this case height) with time:

! v(t) = \frac{dh}{dt} = -9.8 t + v_0

so we integrate again to find the height equation:

! \frac{dh}{dt} = -9.8 t + v_0
! h(t) = \int (-9.8 t + v_0) dt
! h(t) = \frac{-9.8 t^2}{2} + v_0 t + c

Similar to what we did with the velocity equation, to find the new constant c we consider what happens at the start time, when the ball is launched, and t = 0 and h(0) = h0;

! h_0 = \frac{-9.8 (0)^2}{2} + v_0 (0) + c

so:
! h_0 = c

The constant is equal to the initial height of the ball — the height of the ball when it’s thrown. So we end up with the final equation:

! h(t) = \frac{-9.8 t^2}{2} + v_0 t + h_0

Results

Solving all the unknowns

At this point, although we have an equation for the height of the ball, we don’t know the initial velocity (v0), nor do we know the initial height of the ball when it’s released (h0). And we still don’t know the time when the ball is at each position.

With that many unknowns we’d need the same number of independent equations to be able to solve for them all. It may be possible, but instead of analytically solving the equations I opted to take a numerical approach, and use Excel’s Solver function.

I started by setting up the equations to calculate the height of the ball at six different times to correspond with our six height measurements. It was necessary therefore to create a set of variables:

  • Time when we started taking pictures (t1): Since we don’t know how long after we threw the ball we started taking pictures, I made this a variable called t1.
  • The time between each picture (dt): I made the assumption that the time between each picture would be constant. The shutter speed was constant (1/250th of a second) so there is no obvious reason why the time should be different.
  • Initial velocity (v0): The initial upward speed at which the ball was thrown. Obviously, the faster the initial speed the higher the ball goes, so this is a fairly important parameter.
  • Initial height (h0): We also don’t precisely know how high the ball was when it was released, so this also needs to be a variable.

By defining the time between each picture as dt, we can write the time that each picture was taken in terms of the time of the initial picture (t1) and dt. After all the second picture would have been taken dt seconds after the first for a total time of:

! t(P2) = t_0 + dt

similarly for all the pictures:

Table 2. Table of expressions giving the time when each of the six photos were taken.

Now I set up an Excel spreadsheet and gave all the unknown variable values and initial value of 1:

Table 3. Table in Excel for determining the height of a projectile. All of the unknown variables' values are highlighted in green and have been given an initial value of 1.

Now I just had to run Solver and tell it that I wanted the Total Residual, which gives the difference between the h(1) equation’s values for height and the actual, measured values, to be as close to zero as possible. A perfect fit of the equation to the data would have a total residual of one, but that’s not possible when you’re dealing with real data.

Table 4. Parameters set in Solver to determine the values of the unknown constants.

Even so, I had to goose Solver a bit for it to produce reasonable numbers. I put in a few constraints:

  • dt >= 0: We could not have a negative time between pictures.
  • h0 <= 1.25: 1.25 meters seemed reasonable for the height at which the ball was released.
  • t1 <= 1: It also seemed reasonable that the time when the first picture was taken was less than one second after the ball was thrown.

I ran the Solver a few times, and had to reset dt to 0.5 at one point when it had become zero, but the final result looked remarkably good: the total difference between the modeled line and the actual data was only 0.113 meters.

Table 5. Solver's solution for the unknown constants in the height equation.

So we found that:

  • Initial velocity: v0 = 14.2 m/s
  • Height at release: h0 = 1.25 m
  • Time between pictures: dt = 0.41 s
  • Time when the first picture was taken: t1 = 0.44 s

Which makes the height equation:

! h(t) = \frac{-9.8 t^2}{2} + 14.2 t + 1.25

Using these constants in the height equation, we could see how good fit the height equation was to the data:

Figure 3. Graph comparing the modeled heights (from the h(t) equation) to the actual data.

Maximum Height of the Ball

Finally, the maximum height of the ball can be read off the graph, but it can also be determined using the equation for the height of the ball:

! h(t) = \frac{-9.8 t^2}{2} + v_0 t + h_0

We know that the maximum height is reached when the ball stops moving upward and starts to descend. At that point, the vertical velocity of the ball is zero. Since the velocity of the ball is the rate of change of height ( v = \frac{dh}{dt} ) we can differentiate the height equation to get an equation for velocity.

! h(t) = \frac{-9.8 t^2}{2} + v_0 t + h_0

! v = \frac{dh}{dt} = -9.8 t + v_0

since we’ve determined that the initial velocity of the ball is 14.2 m/s we get:

! v = -9.8 t + 14.2

when the velocity is zero (v = 0):

! 0 = -9.8 t + 14.2

which can be solved for t to find that the time the ball reaches it’s maximum height is:

! t = 1.45 seconds

Putting this into the height equation:

! h(1.45) = \frac{-9.8 (1.45)^2}{2} + 14.2 (1.45) + 1.25

gives:

! h_{max} = 11.58 meters

Discussion

I’m quite happy with the way this project turned out. The fit between the modeled heights (h(t)) and the actual heights was very good.

My primary concern going into the project was that the distortion from the camera lens would make this technique impossible, but that appears not to be a significant problem.

Most of this calculation, including the somewhat tricky numerical solution using Solver could have been avoided if I’d calibrated the camera, simply by pointing it at a stopwatch (using the same shutterspeed as in the experiment) and measuring the time between snapshots. It will therefore be interesting to see if the actual time between shots (dt) is close to the dt of 0.41 seconds calculated by the model.

Finally, as noted above, a video camera with a timestamp would possibly be a more useful technology for this experiment.

Conclusion

It is possible to analyze the projectile path of an object using a series of snapshots, to determine the initial velocity of the projectile, its release height, and the time between snapshots, if you can assume that the time between snapshots is identical. There are, however, much easier methods of solving this problem.

References

None, but this is where they’d be if I had any.

Appendix

The Excel spreadsheet where all the calculations were done is here.

Bird Poop: Force at Impact

In response to a question asked on the Car Talk radio program, Rhett Allain does the math to find out if falling bird poop can crack a windshield.

The answer: maybe. There are just a lot of assumptions that have to be made. Is falling bird poop spherical? What’s its density? How does the bird poop deform on impact? What is the compressive strength of automobile glass?

This is however an excellent real-life application of back-of-the-envelope physics and algebra. It required calculating:

  • the volume of the poop – extrapolated from the diameter of the residue on the windshield;
  • the terminal velocity of the poop – the velocity where gravity’s force is exactly counterbalanced by wind resistance so the poop is at its maximum speed;
  • the force of impact – calculated using the work done as the poop splatters;
  • and the pressure imparted by that force.
Brace for impact. Image by Marjie Kennedy.

Math in Real Life

Take what you find interesting and turn it into something challenging, something provocative for someone else.
–Dan Meyer (2011): [anyqs] Hurricane Irene Edition

I’m looking for a good reference for project-based math. Where students face the real-life problems, and learn math as they try to solve them, yet covers the entire curriculum in a complete way.

What I’m considering right now is to swap in some of the real-life questions for some of the sections in the text that consist of rather pedantic word problems, things like: the sum of two numbers is three times less than the square root of the second plus the reciprocal of the first.

Instead, I’d rather do problems like determining the height of a tsunami, which can be treated in different ways depending on which math class you’re teaching, and tie into the science classes (like Physics) as well.

Dan Meyer is a proponent of the project based approach, and he has a lot of interesting problems on his blog.

Malthusian Growth

I think I may fairly make two postulata.

First, That food is necessary to the existence of man.

Secondly, That the passion between the sexes is necessary and will remain nearly in its present state.

— Malthus (1798): An Essay on the Principle of Population via The Concise Encyclopedia of Economics

“Malthusian” is often used as a derogatory term to refer to alarmist predictions that we’re going to run out of some natural resource. I’m afraid I’ve used the term this way myself, however, according to Lauren Landsburg at the Concise Encyclopedia of Economics, Malthus is being unfairly maligned. He wasn’t actually predicting catastrophe but wondering why the catastrophes don’t usually happen.

What Thomas Malthus did, in 1798, was point out that while populations grow at a geometric rate – the U.S. population, he noticed, doubled every 25 years – but resources, like food, only increase at an arithmetic rate. As a result, any naturally growing population will eventually run out of resources.

The red line shows geometric growth. No matter how much you start off with, the red line will always end up crossing the blue line.

The linear equation has the form:

 y = m t + b

where y is the quantity produced, t is time (the independent variable), and m and b are constants. This should not look to unfamiliar to students who’ve had algebra.

The geometric equation is a little more complicated:

 y = a^{gt} + c

here a, g and c are constants. g is the most important, because it’s the growth rate – the higher g is the faster the curve will rise. You can play around with the coefficients and graph in this Excel spreadsheet .

At any rate, after the curves intersect, the needs of the population exceeds how much it can produce; this is the point of Malthusian catastrophe.

The intersection point is where the needs of the population exceeds the production.

The observation is, indeed, so stark that it is still easy to lose sight of Malthus’s actual conclusion: that because humans have not all starved, economic choices must be at work, and it is the job of an economist to study those choices.

— Landsburg (2008): Thomas Robert Malthus from The Concise Encyclopedia of Economics.

A Nefarious Application of Math

Cartoon by Zach Weiner.

Cynical, but, if you consider the current “kinetic military action” in Libya, way to close to reality. Indeed, this highlights the question: When does it become too easy to go to war?

Jonathan Schell sums it up in the Guardian:

American planes are taking off, they are entering Libyan air space, they are locating targets, they are dropping bombs, and the bombs are killing and injuring people and destroying things. It is war. Some say it is a good war and some say it is a bad war, but surely it is a war.

Nonetheless, the Obama administration insists it is not a war. Why?

…, the balance of forces is so lopsided in favour of the United States that no Americans are dying or are threatened with dying. War is only war, it seems, when Americans are dying, when we die. When only they, the Libyans, die, it is something else …

— Schell (2011): Libya: it’s not a war if Americans can’t get hurt

It’s 10 PM and the Moat is Empty

Full moat.

My students and I had a great chance to use the our recent geometry work when we figured out how long it would take to drain the new moat in front of the school.

It’s not really a moat, it’s going to be a flower bed that will soak up some of the runoff that tries to seep into the school’s doors every time a spring or fall thunderstorm sweeps through.

The hole was dug on Thursday evening and filled with rainwater with water, half a meter deep, by Friday morning’s rain. At least we know now that the new beds are in the right place to attract runoff.

But to fill the trenches with gravel, sand and soil, we needed to drain the water. With a small electrical pump it seemed like it would take forever; except that we could do the math.

The pump emptied water through a long hose that runs around the back of the building where the topography is lower. I sent two students with a pitcher and a timer (an iPod Touch actually) to get the flow rate.

They came back with a time of 18.9 seconds to fill 4 liters. I sent them back to take another measurement, and had them average the to numbers to get the more reliable value of 18.65 seconds.

Then one of the students got out the meter-stick and measured the depth of the moat at a few locations. The measurements ranged from 46 cm to about 36 cm and we guesstimated that we could model the moat as having two parts, both sloping. After measuring the length (~6 m) and width (2 m), we went inside to do the math.

Rough sketch of the volume of water in the moat.

With the help of two of my students who tend to take the advanced math option every cycle, we calculated the volume of water (in cm3) and the flow rate of the pumped water (0.2145 cm3/s). Then we could work out the time it would take to drain the water, which turned out to be a pretty large number of seconds. We converted to minutes and then hours. The final result was about 7 hours, which would mean that the pump would need to run until 10 pm.

And it did.

The power of math.

Tsunami Geometry: Calculating the Height of a Tsunami using Basic Geometry

Since we’re working on geometry this cycle, I thought it would be an interesting exercise to think about how we could use geometry to think about how the strength of tsunamis decreases with distance from the source.

Of course, we’ll have to do this using some intense simplification so we can actually apply the tools we have available. The first is to approximate the tsunami as a circular wall of water centered on the epicenter of the earthquake.

Simplified tsunami geometry.

This lets us figure out the volume of the wave pretty easily because we know that the volume of a cylinder is:

(1) ! V_c = \pi r^2 h

The size of the circular water wall we approximate from the reports from Japan. The maximum height of the wave at landfall was somewhere in the range of 14 m along the northern Japanese coast, which was about 80 km from the epicenter. Just as a wild guess, I’m assuming that the “effective” width of the wave is 1 km.

Typically, in deep water, a tsunami can have a wavelength greater than 500 km (Nelson, 2010; note that our width is half the wavelength), but a wave height of only 1 m (USSRTF). When they reach the shallow water the wave height increases. The Japanese tsunami’s maximum height was reportedly about 14 m.

At any rate, we can figure out the volume of our wall of water by calculating the volume of a cylinder with the middle cut out of it. The radius of our inner cylinder is 80 km, and the radius of the outer cylinder is 80 km plus the width of the wave, which we say here is 1 km.

Calculating the volume of the wave

However, for the sake of algebra, we’ll call the radius of the inner cylinder, ri and the width of the wave as w. Therefore the inner cylinder has a volume of:

(2) ! V_i = \pi r_i^2 h

So the radius of the outer cylinder is the radius of the inner cylinder plus the width of the wave:

(3) ! r_o = r_i + w

which means that the volume of the outer cylinder is:

(4) ! V_o = \pi (r_i + w)^2 h

So now we can figure out the volume of the wave, which is the volume of the outer cylinder minus the volume of the inner cylinder:

(5) ! V_w = V_o - V_i

(6) ! V_w = \pi (r_i + w)^2 h - \pi r_i^2 h

Now to simplify, let’s expand the first term on the right side of the equation:

(7) ! V_w = \pi (r_i ^2 + 2 r_i w + w^2) h - \pi r_i^2 h

Now let’s collect terms:

(8) ! V_w = \pi h \left( (r_i ^2 + 2 r_i w + w^2)  - r_i^2 \right)

Take away the inner parentheses:

(9) ! V_w = \pi h (r_i ^2 + 2 r_i w + w^2  - r_i^2)

and subtract similar terms to get the equation:

(10) ! V_w = \pi h ( 2 r_i w + w^2 )

Volume of the wave

Now we can just plug in our estimates of width and height to get the volume of water in the wave. We’re going to assume, later on, that the volume of water does not change as the wave propagates across the ocean.

(11) ! V_w =  \pi (14)  ( 2 r_i (1000) + (1000)^2 )

rearrange so the coefficients are in front of the variables:

(12) ! V_w =  14 \pi  ( 2000 r_i  + 1000000 )

So, at 80 km, the volume of water in our wave is:

(13) ! V_w =  14 \pi  ( 2000 (80000)  + 1000000 )

(14) ! V_w =  7081149841  m^3

Height of the Tsunami

Okay, now we want to know what the height of the tsunami will be at any distance from the epicenter of the earthquake. We’re assuming that the volume of water in the wave remains the same, and that the width of the wave also remains the same. The radius and circumference will certainly change, however.

We take equation (10) and rearrange it to solve for h by first dividing by rearranging all the terms on the right hand side so h is at the end of the equation (this is mostly for clarity):

(15) ! V_w = \pi ( 2 r_i w + w^2 )  h

Now we can divide by all the other terms on the right hand side to isolate h:

(16) ! \frac{V_w}{\pi ( 2 r_i w + w^2 )} = \frac{\pi ( 2 r_i w + w^2 )  h}{\pi ( 2 r_i w + w^2 )}

so:

(17) ! \frac{V_w}{\pi ( 2 r_i w + w^2 )} = h

which when reversed looks like:

(18) ! h = \frac{V_w}{\pi ( 2 r_i w + w^2 )}

This is our most general equation. We can use it for any width, or radius of wave that we want, which is great. Anyone else who wants to calculate wave heights for other situations would probably start with this equation (and equation (15)).

Double checking our algebra

So we can now figure out the height of the wave at any radius from the epicenter of the earthquake. To double check our algebra, however, let’s plug in the volume we calculated, and the numbers we started off with, and see if we get the same height (14 m).

First, we’ll use all our initial approximations so we get an equation with only two variables: height (h) and radial distance (ri). Remember our initial conditions:

w = 1000 m
ri = 80,000 m
hi = 14 m

we used these numbers in equation (10) to calculate the volume of water in the wave:

Vw = 7081149841 m3

Now using these same numbers in equation (18) we get:

(19) ! h = \frac{7081149841}{\pi ( 2 (r_i) (1000) + (1000)^2 )}

which simplifies to:

(20) ! h = \frac{7081149841}{ 2000 r_i \pi + 1000000 \pi }

So, to double-check we try the radius of 80 km (80,000 m) and we get:

h = 14 m

Aha! it works.

Across the Pacific

Now, what about Hawaii? Well it’s about 6000 km away from the earthquake, so taking that as our radius (in meters of course), in equation (20) we get:

(21) ! h = \frac{7,081,149,841}{ 2,000 (6,000,000) \pi + 1,000,000 \pi }

which is:

h = 0.19 m

This is just 19 cm!

All the way across the Pacific, Lima, Peru, is approximately 9,000 km away, which, using equation (20) gives:

h = 0.13 m

So now I’m curious about just how fast the 14 meters drops off to less than 20 cm. So I bring up Excel and put together a spreadsheet of tsunami height at different distances. Plot on a graph we get:

Tsunami heights with distance from earthquake, assuming a circular wall of water.

So the height of the tsunami drops off relatively fast. Within 1000 km of the earthquake the height has dropped by 90%.

How good is this model

This is all very nice, a cute little exercise in algebra, but is it useful? Does it come anywhere close to reality? We can check by comparing it to actual measurements; the same ones used by NOAA to compare to their model (see here).

The red line is the tsunami's water height predicted by the NOAA computer models for Honolulu, Hawaii, while the black line is the actual water height, measured at a tidal gauge. Other comparisons can be found here.
Tsunami wave heights in the Pacific, as modeled by NOAA. Notice how the force of the tsunami is focused across the center of the Pacific.

The graph shows a maximum height of about 60 cm, which is about three times larger than our model. NOAA’s estimate is within 20% of the actual maximum heights, but they’ve spent a bit more time on this problem, so they should be a little better than us. You can find all the gruesome details on NOAA’s Center for Tsunami Research site’s Tsunami Forecasting page.

Notes

1. The maximum height of a tsunami depends on how much up-and-down motion was caused by the earthquake. ScienceDaily reports on a 2007 article that tried to figure out if you could predict the size of a tsunami based on the type of earthquake that caused it.

2. Using buoys in the area, NOAA was able to detect and warn about the Japanese earthquake in about 9 minutes. How do they know where to place the buoys? Plate tectonics.

The locations of the buoys in NOAA's tsunami warning system.

Update

The equations starting with (7) did not have the 2 on the riw term. That has been corrected. Note that the numerical calculations were correct so they have not changed. – Thanks to Spencer and Claude for helping me catch that.