Related Rates: The Distance Between Moving Points Problem

An error occurred trying to load this video.

Try refreshing the page, or contact customer support.

Coming up next: Graphing Functions Flashcards

You're on a roll. Keep up the good work!

Take Quiz Watch Next Lesson
Your next lesson will play in 10 seconds
  • 0:06 Two Trains Problem
  • 3:13 Another Two Trains Problem
  • 4:55 Fire Ladder Problem
  • 8:13 Lesson Summary
Save Save Save

Want to watch this again later?

Log in or sign up to add this lesson to a Custom Course.

Log in or Sign up

Speed Speed

Recommended Lessons and Courses for You

Lesson Transcript
Instructor: Erin Monagan

Erin has been writing and editing for several years and has a master's degree in fiction writing.

Remember the classic problem of math horror stories everywhere? You know, where one train leaves Kentucky at 2 p.m. and another leaves Sacramento at 4 p. m.? In this lesson, tame the horror and learn how to solve these problems using differentiation and related rates.

Two Trains Problem

Plugging the train velocities into the problem shows the distance is changing at a rate of -75 mph
Train Problem 1

Remember that problem that everybody always makes fun of: If one train leaves Kentucky at 2 p.m. and another leaves Sacramento at 4 p.m., and the alignment of the moons is such that everything is going 5 mph, when will they cross? We're going to do a problem that's similar, but a little more reasonable. Imagine that you have two trains heading toward one another. Train 1 is going eastbound at 30 mph, and Train 2 is headed westbound at 45 mph. They're going to start 100 miles apart. How far apart will they be in one hour? When will they pass one another?

Because we want to know how far apart they're going to be and when they pass each other (when the distance between them is zero), we want to write that the distance between them is equal to the position of Train 2 minus the position of Train 1, l = x sub 2 - x sub 1. Now we've got the distance between them, which I'll call l. Here we're going to use a related rate. We're going to relate the distance between them to each one of their speeds. I'm going to take the derivative of both the left and right side of this equation, and I'll get dl/dt (how their distance changes as a function of time) = dx(sub 2/dt) - dx(sub 1/dt), how fast Train 2 is going minus how fast Train 1 is going. If I plug in the velocity of Train 2 and the velocity of Train 1, I find that the distance is changing at a rate of -75 mph.

If I use a separation of variables to solve this differential equation - if I get all the t variables on the right side and all the l variables on the left side - I get dl=-75dt. If I integrate both sides, I find that l=-75t + C. Because they start out when time equals zero at a distance 100 miles apart, I can solve this l equation for C. So 100=(-75)(0) + C, that means C=100 miles. What I end up with is an equation for how far apart they are as a function of time: l=-75t + 100. After one hour, t=1, I find that l is 25, and they're 25 miles apart. They pass each other when l=0, when t=1.3 hours.

In the second train problem, velocity 1 is negative because train 1 is moving to the left
Train Problem 2

Another Two Trains Problem

If Train 1 turns around and starts heading westbound at 30 mph instead of heading toward Train 2, and they still start 100 miles apart, how far apart will they be in one hour? Will Train 2 ever pass Train 1?

Again, I'm going to write the distance between the two trains as l= x sub 2 - x sub 1. I'm going to take the derivative of both the left and right sides. This time, after I find dl/dt = 'dx(sub 2/dt) - dx(sub 1/dt), and I plug in velocity 1 and velocity 2, velocity 1 is going to be negative because Train 1 is moving to the left (the same direction that Train 2 is moving). So dl/dt = (-45) - (-30) or dl/dt = -45 + 30. This means that the distance between them is changing at a rate of -15 mph. Again, using the fact that at time 0 they're 100 miles apart, I can solve this equation and find that l = -15t + 100. This means that after one hour, the two trains will be 85 miles apart. After 6.7 hours, Train 2 will overtake Train 1; I can solve this equation for t when l=0. But what if the distance isn't along a straight line?

The equation shows how the height is changing with respect to how fast the fire truck is moving away
fire ladder problem

To unlock this lesson you must be a Member.
Create your account

Register to view this lesson

Are you a student or a teacher?

Unlock Your Education

See for yourself why 30 million people use

Become a member and start learning now.
Become a Member  Back
What teachers are saying about
Try it risk-free for 30 days

Earning College Credit

Did you know… We have over 200 college courses that prepare you to earn credit by exam that is accepted by over 1,500 colleges and universities. You can test out of the first two years of college and save thousands off your degree. Anyone can earn credit-by-exam regardless of age or education level.

To learn more, visit our Earning Credit Page

Transferring credit to the school of your choice

Not sure what college you want to attend yet? has thousands of articles about every imaginable degree, area of study and career path that can help you find the school that's right for you.

Create an account to start this course today
Try it risk-free for 30 days!
Create an account