Use existing methods instead of incorrect maths

Fixes #824. Feels so good to be _removing_ lines for once.