Correct mathematical error