Add vector manipultaions, updated version