Options
All
  • Public
  • Public/Protected
  • All
Menu

External module "blas/gdot/docs/types/index.d"

Index

Functions

Functions

gdot

  • Computes the dot product of two vectors.

    Notes

    • In general, for best performance, especially for large vectors, provide 1-dimensional ndarrays whose underlying data type is either float64 or float32.
    throws

    first argument must be either an array-like object or a 1-dimensional ndarray

    throws

    second argument must be either an array-like object or a 1-dimensional ndarray

    throws

    input arrays must be the same length

    Parameters

    Returns number

    dot product

    Example

    var x = [ 4.0, 2.0, -3.0, 5.0, -1.0 ];
    var y = [ 2.0, 6.0, -1.0, -4.0, 8.0 ];
    
    var z = gdot( x, y );
    // returns -5.0