/**
 * N-dimensional AXPY (BLAS-style): in-place adds `alpha * x` into `y`.
 *
 *     y[i] += alpha * x[i]   for i in [0, n)
 *
 * @param {number[]|Float32Array|Float64Array} y receives the in-place update
 * @param {number} alpha
 * @param {number[]|Float32Array|Float64Array} x
 * @param {number} n number of elements
 */
export function vector_axpy(y, alpha, x, n) {
    for (let i = 0; i < n; ++i) {
        y[i] += alpha * x[i];
    }
}
