dqddot: High-accuracy dot product

View source: R/blas_extras.R

dqddotR Documentation

High-accuracy dot product

Description

Forms the dot product using long-double accumulation to mitigate rounding error.

Usage

dqddot(N = NULL, X, INCX = 1L, Y, INCY = 1L)

Arguments

N

Optional integer giving the number of elements. Defaults to 'length(X)'.

X

Double-precision vector, matrix or ['bigmemory::big.matrix'] input.

INCX

Integer stride for traversing 'X'.

Y

Double-precision object updated in place.

INCY

Integer stride for traversing 'Y'.

Value

Numeric scalar equal to the dot product of 'X' and 'Y'.

Examples

dqddot(X = 1:3, Y = c(2, 4, 6))


bigalgebra documentation built on Sept. 9, 2026, 5:12 p.m.