Refactored tasks contoller calculation code into a Calculator controller
Refactor calculations into Calculator service