How is the scalar product of vectors related to work?