ah, the pythagorean theorem. a^2 + b^2 = c^2