Source: https://www.cpp.edu/~hturner/ce220/vertical_curves.pdf