Updated to put calculator in lib