|
numerics
|
Vector operations. More...
#include "core/types.hpp"#include "core/policy.hpp"#include "core/parallel/cuda_ops.hpp"#include <memory>#include <algorithm>#include <type_traits>Go to the source code of this file.
Classes | |
| class | num::BasicVector< T > |
| Dense vector with optional GPU storage, templated over scalar type T. More... | |
Namespaces | |
| namespace | num |
Typedefs | |
| using | num::Vector = BasicVector< real > |
| Real-valued dense vector with full backend dispatch (CPU + GPU) | |
| using | num::CVector = BasicVector< cplx > |
| Complex-valued dense vector (sequential; no GPU) | |
Functions | |
| void | num::scale (Vector &v, real alpha, Backend b=default_backend) |
| v *= alpha | |
| void | num::add (const Vector &x, const Vector &y, Vector &z, Backend b=default_backend) |
| z = x + y | |
| void | num::axpy (real alpha, const Vector &x, Vector &y, Backend b=default_backend) |
| y += alpha * x | |
| real | num::dot (const Vector &x, const Vector &y, Backend b=default_backend) |
| dot product | |
| real | num::norm (const Vector &x, Backend b=default_backend) |
| Euclidean norm. | |
| void | num::scale (CVector &v, cplx alpha) |
| v *= alpha | |
| void | num::axpy (cplx alpha, const CVector &x, CVector &y) |
| y += alpha * x | |
| cplx | num::dot (const CVector &x, const CVector &y) |
| Conjugate inner product <x, y> = Sigma conj(x_i) * y_i. | |
| real | num::norm (const CVector &x) |
| Euclidean norm sqrt(Sigma |v_i|^2) | |
Vector operations.
Definition in file vector.hpp.