Lesson one: don't underestimate the power of engineering (and science)
Lesson two: beware of those who would rewrite the truth
(Excerpts from the novelization of the movie by Greg Keyes. No, I'm not a nerd. Ok, I am.)
Andrew Rader points out some problems with the movie:
The main problem was also pointed out by Kip Thorne in The Science of Interstellar: that fighting the blight on Earth would make a lot more sense than going to a different planet.
Thorne also raises the problem of orbital mechanics in chapter 7 of the book:
and proposes a few speculative mechanisms to get the necessary changes in velocity from gravity assists. Note that there are two decelerations one of $c/3$ and one of $c/4$ for a total speed change of $7c/12$ or $1.75\times 10^{8}$ m/s. Returning to the Endurance requires an increase in speed of $1.75\times 10^{8}$ m/s as well.
To see the size of the problem, let's say they take 500 seconds (8 minutes and 20 seconds) to do each maneuver (while the rest of the Universe ages significantly) and the Ranger's mass is 2 metric tons (for simplicity, we'll assume that the water taken in on the planet makes up for the loss of Dr. Doyle to stupidity, indiscipline, and lack of planning). If we assume constant thrust for simplicity, assume away all friction and ignore the propellant mass loss (yay, infinite specific impulse!), the thrust needed for each maneuver is $7 \times 10^8$ Newton or about the same as 1077 SpaceX Merlin engines (averaging their atmosphere and vacuum thrust to 650 kN). Since there's propellant mass loss, let's say we "only" need the equivalent of 900 Merlin engines. So, yes, only a gravity assist would do.
Yes, it's an oversimplification, but didn't feel like solving the Tsiolkovsky equation. Hence the drop from 1077 to 900 engines. (That's still equivalent to 100 Falcon 9 rockets.) By the way, Thorne appears unconvinced of the feasibility of those gravity assists and hence of the feasibility of whole expedition to Miller's planet. But at least they tried to be accurate with some science in the movie.
Oh, and speaking of nerds: