Added formula and fixed add