/// <param name="x">Sample points (N+1), sorted ascending</param>
        /// <param name="c0">Sample values (N or N+1) at the corresponding points; intercept, zero order coefficients</param>
        /// <param name="c1">Slopes (N) at the sample points (first order coefficients): N</param>
        public LinearSpline(StructuredBufferAccessor <double> x, StructuredBufferAccessor <double> c0, StructuredBufferAccessor <double> c1)
        {
            if ((x.Count != c0.Count + 1 && x.Count != c0.Count) || x.Count != c1.Count + 1)
            {
                throw new ArgumentException(@"ArgumentVectorsSameLength");
            }

            if (x.Count < 2)
            {
                throw new ArgumentException(string.Format(@"ArrayTooSmall", 2), nameof(x));
            }

            _x  = x;
            _c0 = c0;
            _c1 = c1;
            _indefiniteIntegral = new Lazy <double[]>(ComputeIndefiniteIntegral);
        }
 public sdfsdasdad(StructuredBufferAccessor <T> x)
 {
     this.x = x;
 }