simply the maths (thanks Zeljko)