nk 1.0.0
C++ Numerical Computing Runtime
Loading...
Searching...
No Matches
balance.hpp
Go to the documentation of this file.
1
3// toolboxes/linalg/include/nk/linalg/balance.hpp
4//
5// MATLAB balance: diagonal-similarity scaling for eigenvalue
6// computations. Migrated from toolboxes/builtin/src/language/arrays/balance.cpp.
7
8#pragma once
9
10#include <memory_resource>
11#include <nk/value/value.hpp>
12
13namespace nk::linalg {
14
17
18
25
31BalanceResult balance_impl(const Value &A, bool noperm,
32 std::pmr::memory_resource *mr = nullptr);
33
34
36} // namespace nk::linalg
Core MATLAB-compatible multidimensional array and scalar value type.
Definition value.hpp:61
BalanceResult balance_impl(const Value &A, bool noperm, std::pmr::memory_resource *mr=nullptr)
Diagonal-similarity balancing for eigenvalue computations ([B, d, p] = balance(A, noperm)).
Result of balance_impl.
Definition balance.hpp:20
Value d_col
Column of scaling factors.
Definition balance.hpp:22
Value perm_col
Column of permutation indices (1..n in v1).
Definition balance.hpp:23
Value B
Balanced matrix.
Definition balance.hpp:21