all calculations working