NumericAL
A header-only C++20 lexer built on REAL
Loading...
Searching...
No Matches
Public Attributes | List of all members
numerical::least_squares_solution< T > Struct Template Reference

A least-squares solution and what numpy.linalg.lstsq reports beside it (least_squares). More...

#include <decomposition.hpp>

Collaboration diagram for numerical::least_squares_solution< T >:
[legend]

Public Attributes

matrix< T > solution
 The minimum-norm x of A x ≈ B (n × k), lstsq's.
 
vector< double > residuals
 Per column of B, ‖B − A x‖²: for a tall A of full column rank, else empty.
 
std::size_t rank {0}
 The numerical rank of A (matrix_rank).
 
vector< double > singular_values
 The singular values of A, descending (singular_values).
 

Detailed Description

template<typename T>
struct numerical::least_squares_solution< T >

A least-squares solution and what numpy.linalg.lstsq reports beside it (least_squares).

Definition at line 6588 of file decomposition.hpp.

Member Data Documentation

◆ rank

template<typename T >
std::size_t numerical::least_squares_solution< T >::rank {0}

The numerical rank of A (matrix_rank).

Definition at line 6592 of file decomposition.hpp.

◆ residuals

Per column of B, ‖B − A x‖²: for a tall A of full column rank, else empty.

Definition at line 6591 of file decomposition.hpp.

◆ singular_values

template<typename T >
vector<double> numerical::least_squares_solution< T >::singular_values

The singular values of A, descending (singular_values).

Definition at line 6593 of file decomposition.hpp.

◆ solution

The minimum-norm x of A x ≈ B (n × k), lstsq's.

Definition at line 6590 of file decomposition.hpp.


The documentation for this struct was generated from the following file: