Exemplo n.º 1
0
        public override void ScaleArray(double alpha, double[] x, double[] result)
        {
            if (x == null)
            {
                throw new ArgumentNullException(nameof(x));
            }

            if (!ReferenceEquals(x, result))
            {
                Array.Copy(x, 0, result, 0, x.Length);
            }

            if (alpha == 1.0)
            {
                return;
            }

            SafeNativeMethods.d_scale(_blasHandle, x.Length, alpha, result);
        }