implemented the dot member function in mvector.h