/// <summary>
        ///
        /// </summary>
        public static void LerpParallel(this Vec3d[][] vectors, double[] t, int size, Vec3d[] result)
        {
            int last = vectors.Length - 1;

            Parallel.ForEach(Partitioner.Create(0, size), range =>
            {
                for (int j = range.Item1; j < range.Item2; j++)
                {
                    double tj = SlurMath.Fract(t[j] * last, out int i);

                    if (i < 0)
                    {
                        result[j] = vectors[0][j];
                    }
                    else if (i >= last)
                    {
                        result[j] = vectors[last][j];
                    }
                    else
                    {
                        result[j] = Vec3d.Lerp(vectors[i][j], vectors[i + 1][j], tj);
                    }
                }
            });
        }
        /// <summary>
        ///
        /// </summary>
        public static void Lerp(this Vec3d[][] vectors, double[] t, int size, Vec3d[] result, bool parallel = false)
        {
            if (parallel)
            {
                Parallel.ForEach(Partitioner.Create(0, size), range => Body(range.Item1, range.Item2));
            }
            else
            {
                Body(0, size);
            }

            void Body(int from, int to)
            {
                int last = vectors.Length - 1;

                for (int j = from; j < to; j++)
                {
                    double tj = SlurMath.Fract(t[j] * last, out int i);

                    if (i < 0)
                    {
                        result[j] = vectors[0][j];
                    }
                    else if (i >= last)
                    {
                        result[j] = vectors[last][j];
                    }
                    else
                    {
                        result[j] = Vec3d.Lerp(vectors[i][j], vectors[i + 1][j], tj);
                    }
                }
            }
        }
        /// <summary>
        ///
        /// </summary>
        public static void Lerp(this Vec3d[][] vectors, double[] t, int size, Vec3d[] result)
        {
            int last = vectors.Length - 1;

            for (int j = 0; j < size; j++)
            {
                double tj = SlurMath.Fract(t[j] * last, out int i);

                if (i < 0)
                {
                    result[j] = vectors[0][j];
                }
                else if (i >= last)
                {
                    result[j] = vectors[last][j];
                }
                else
                {
                    result[j] = Vec3d.Lerp(vectors[i][j], vectors[i + 1][j], tj);
                }
            }
        }