Fix precision errors