package
Version:
v0.0.0-...-2c859fb
Opens a new window with list of versions in this module.
Published: Feb 8, 2023
License: GPL-3.0
Opens a new window with license information.
Imports: 0
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
-
func Add(dst, s []float32)
-
func AddConst(alpha float32, x []float32)
-
func AxpyUnitary(alpha float32, x, y []float32)
-
func Div(dst, s []float32)
-
func DivTo(dst, s, t []float32) []float32
-
func DotUnitary(x, y []float32) (sum float32)
-
func ScalUnitary(alpha float32, x []float32)
-
func ScalUnitaryTo(dst []float32, alpha float32, x []float32)
-
func Sum(x []float32) float32
Add is
for i, v := range s {
dst[i] += v
}
AddConst is
for i := range x {
x[i] += alpha
}
AxpyUnitary is
for i, v := range x {
y[i] += alpha * v
}
Div is
for i, v := range s {
dst[i] /= v
}
DivTo is
for i, v := range s {
dst[i] = v / t[i]
}
return dst
DotUnitary is
for i, v := range x {
sum += y[i] * v
}
return sum
ScalUnitary is
for i := range x {
x[i] *= alpha
}
ScalUnitaryTo is
for i, v := range x {
dst[i] = alpha * v
}
Sum is
var sum float32
for i := range x {
sum += x[i]
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.