Back to Linear Algebra
dot
Dot product of two vectors.
Syntax
dot(a, b) → r
Backends
TypeScriptOpenBLASNative BinaryWebAssembly
Description
Dot product of two vectors.
Parameters
| Name | Description |
|---|---|
| a | First vector |
| b | Second vector |
Returns
Scalar dot product
Examples
Try It
>> dot([1, 2, 3], [4, 5, 6])