@equinor/videx-linear-algebra
    Preparing search index...

    Function add

    • a + b

      Component-wise addition of two n-dimensional vectors. Target is used to store the results.

      Type Parameters

      Parameters

      • a: T

        Left operand

      • b: VectorLike

        Right operand

      • target: T = a

        Target for storing the results (Default: a)

      Returns T

      Resulting vector

      add([1, 2], [3, 4], new Array(2)); // Returns: [4, 6]