// Divide func (a Scalar) Div_S(b S) S { var x, y big.Float x = big.Float(a) y = big.Float(b.(Scalar)) z := x.Quo(&x, &y) return (Scalar)(*z) }
// Subtract func (a Scalar) Sub_S(b S) S { var x, y big.Float x = big.Float(a) y = big.Float(b.(Scalar)) z := x.Sub(&x, &y) return (Scalar)(*z) }
// Add func (a Scalar) Add_S(b S) S { var x, y big.Float x = big.Float(a) y = big.Float(b.(Scalar)) z := x.Add(&x, &y) return (Scalar)(*z) }
// Multiply func (a Scalar) Mul_S(b S) S { var x, y big.Float x = big.Float(a) y = big.Float(b.(Scalar)) z := x.Mul(&x, &y) return (Scalar)(*z) }
// Divide Scalar func (a *Vector) DivSc_V(pos int, b S) { x := big.Float(a.Elem[pos]) y := big.Float(b.(Scalar)) x.Quo(&x, &y) a.Elem[pos] = Scalar(x) }
// Divide func (a *Vector) Div_V(pos int, b V) { x := big.Float(a.Elem[pos]) y := big.Float(b.(*Vector).Elem[pos]) x.Quo(&x, &y) a.Elem[pos] = Scalar(x) }
// Convert Scalar to a float func (a Scalar) ToFloat() float64 { x := big.Float(a) ret, _ := x.Float64() return ret }
// Negate a vector element func (a *Vector) Neg_V(pos int) { x := big.Float(a.Elem[pos]) x.Neg(&x) a.Elem[pos] = Scalar(x) }
// Dot product of two vectors func (a *Vector) Dot(b *Vector) big.Float { return big.Float(Dot_V(a, b).(Scalar)) }