A lot of refactoring of the classical calculator