Dense row-major matrix with optional GPU storage.
real dot(const Vector &x, const Vector &y)
void matvec(const Matrix &A, const Vector &x, Vector &y)
void matadd(real alpha, const Matrix &A, real beta, const Matrix &B, Matrix &C)
void scale(Vector &v, real alpha)
void matmul(const Matrix &A, const Matrix &B, Matrix &C)
void axpy(real alpha, const Vector &x, Vector &y)
real beta(real a, real b)
B(a, b) – beta function.
constexpr T ipow(T x) noexcept
Compute x^N at compile time via repeated squaring.