refactored calculation methods