function p = v(q) % V(Q). Extracts the vector component of a quaternion. % Copyright © 2005 Stephen J. Sangwine and Nicolas Le Bihan. % See the file : Copyright.m for further details. % error(nargchk(1, 1, nargin)), error(nargoutchk(0, 1, nargout)) if ispure(q) p = q; else p = quaternion(x(q), y(q), z(q)); end