split the worker methods out of vector.js and matrix.js