X-Git-Url: http://git.osdn.net/view?p=bytom%2Fvapor.git;a=blobdiff_plain;f=vendor%2Fgonum.org%2Fv1%2Fgonum%2Fblas%2Fgonum%2Fgeneral_double.go;fp=vendor%2Fgonum.org%2Fv1%2Fgonum%2Fblas%2Fgonum%2Fgeneral_double.go;h=0000000000000000000000000000000000000000;hp=f7012ffc0adb747e475b39113edb7f5f4365b53e;hb=2cf5801b2e693a45de9b51ec9aa9c1f787d57105;hpb=0dff3fcf4fbd306176d561d721c1c31e58d90742 diff --git a/vendor/gonum.org/v1/gonum/blas/gonum/general_double.go b/vendor/gonum.org/v1/gonum/blas/gonum/general_double.go deleted file mode 100644 index f7012ffc..00000000 --- a/vendor/gonum.org/v1/gonum/blas/gonum/general_double.go +++ /dev/null @@ -1,50 +0,0 @@ -// Copyright ©2014 The Gonum Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package gonum - -import ( - "math" -) - -type general64 struct { - data []float64 - rows, cols int - stride int -} - -func (g general64) clone() general64 { - data := make([]float64, len(g.data)) - copy(data, g.data) - return general64{ - data: data, - rows: g.rows, - cols: g.cols, - stride: g.stride, - } -} - -func (g general64) equal(a general64) bool { - if g.rows != a.rows || g.cols != a.cols || g.stride != a.stride { - return false - } - for i, v := range g.data { - if a.data[i] != v { - return false - } - } - return true -} - -func (g general64) equalWithinAbs(a general64, tol float64) bool { - if g.rows != a.rows || g.cols != a.cols || g.stride != a.stride { - return false - } - for i, v := range g.data { - if math.Abs(a.data[i]-v) > tol { - return false - } - } - return true -}