Fixed inversion and implemented normalize()
Fixed dot product