numerics 0.1.0
Loading...
Searching...
No Matches
dense.hpp
Go to the documentation of this file.
1/// @file kernel/dense.hpp
2/// @brief Dense matrix inner kernels (namespace num::kernel::dense)
3#pragma once
4
5#include "core/matrix.hpp"
6#include "core/types.hpp"
7#include "core/vector.hpp"
8#include "kernel/policy.hpp"
9
11
12/// @brief Sequential rank-1 update.
13void ger(real alpha, const Vector& x, const Vector& y, Matrix& A, seq_t) noexcept;
14
15/// @brief Parallel rank-1 update.
16void ger(real alpha, const Vector& x, const Vector& y, Matrix& A, par_t);
17
18inline void ger(real alpha, const Vector& x, const Vector& y, Matrix& A) {
19 ger(alpha, x, y, A, default_policy{});
20}
21
22/// @brief Forward substitution: solve Lx = b.
23void trsv_lower(const Matrix& L, const Vector& b, Vector& x);
24
25/// @brief Back substitution: solve Ux = b.
26void trsv_upper(const Matrix& U, const Vector& b, Vector& x);
27
28} // namespace num::kernel::dense
Core type definitions.
Compile-time dispatch policy tags for the kernel module.
Dense row-major matrix templated over scalar type T.
void trsv_upper(const Matrix &U, const Vector &b, Vector &x)
Back substitution: solve Ux = b.
Definition dense.cpp:46
void trsv_lower(const Matrix &L, const Vector &b, Vector &x)
Forward substitution: solve Lx = b.
Definition dense.cpp:35
void ger(real alpha, const Vector &x, const Vector &y, Matrix &A, seq_t) noexcept
Sequential rank-1 update.
Definition dense.cpp:11
double real
Definition types.hpp:10
Parallel execution policy tag.
Definition policy.hpp:13
Sequential execution policy tag.
Definition policy.hpp:10
Dense vector storage and operations.