Implementing lapack dot methods in linalg dot.h

fixed minor error in previous commit

squash of last two commits