class of discount calculator