Added calculation back in main.