number calc and formatting