Implemented duration method for math type class