Refactoring to standard maths.