Added all of the midpoint formulas