added dot product and vector code