How is work related to energy?