try to use fixed arithmetic instead of double, less precise...