Calculating Work and Potential Energy