iterative-solver 0.0
molpro::linalg::itsolv::detail::dspace Namespace Reference

Functions

template<typename value_type >
auto construct_projected_solution (const subspace::Matrix< value_type > &solutions, const subspace::Dimensions &dims, const std::vector< int > &remove_qspace, Logger &logger)
 Projects solution from the full subspace on to Q_{delete} and current D space. More...
 
template<typename value_type >
auto construct_projected_solutions_overlap (const subspace::Matrix< value_type > &solutions_proj, const subspace::Matrix< value_type > &overlap, const subspace::Dimensions &dims, const std::vector< int > &remove_qspace, Logger &logger)
 Constructs overlap matrix for projected solutions. More...
 
template<typename value_type , typename value_type_abs >
void remove_null_norm_and_normalise (subspace::Matrix< value_type > &parameters, subspace::Matrix< value_type > &overlap, const value_type_abs norm_thresh, Logger &logger)
 Removes parameters with norm less than threshold and normalises the rest. More...
 
template<typename value_type , typename value_type_abs >
auto remove_null_projected_solutions (const subspace::Matrix< value_type > &solutions_proj, const subspace::Matrix< value_type > &overlap_proj, const value_type_abs svd_thresh, Logger &logger)
 Transforms to a stable subspace of projected solutions via SVD. More...
 
template<typename value_type >
auto construct_full_subspace_overlap (const subspace::Matrix< value_type > &solutions_proj, const subspace::Dimensions &dims, const std::vector< int > &remove_qspace, const subspace::Matrix< value_type > &overlap, const size_t nR)
 Constructs overlap matrix of P+Q+R+(projected solutions) subspaces, where Q is without removed parameters. More...
 

Function Documentation

◆ construct_full_subspace_overlap()

template<typename value_type >
auto molpro::linalg::itsolv::detail::dspace::construct_full_subspace_overlap ( const subspace::Matrix< value_type > &  solutions_proj,
const subspace::Dimensions dims,
const std::vector< int > &  remove_qspace,
const subspace::Matrix< value_type > &  overlap,
const size_t  nR 
)

Constructs overlap matrix of P+Q+R+(projected solutions) subspaces, where Q is without removed parameters.

Parameters
solutions_projsolutions matrix with Q deleted + current D space as columns
dimsdimensions of the current subspace
remove_qspaceindices of Q parameters to be removed
overlapoverlap of current subspace P+Q+D+R, including all of the current Q space
nRnumber of new parameters
Returns
overlap matrix for the subspace P+Q+R+(projected solutions), Q without deleted vectors

◆ construct_projected_solution()

template<typename value_type >
auto molpro::linalg::itsolv::detail::dspace::construct_projected_solution ( const subspace::Matrix< value_type > &  solutions,
const subspace::Dimensions dims,
const std::vector< int > &  remove_qspace,
Logger logger 
)

Projects solution from the full subspace on to Q_{delete} and current D space.

Parameters
solutionssolution matrix in the full subspace
dimsdimensions for partitioning of subspace
remove_qspaceindices to remove from current Q space and move into Q_{delete}
norm_threshvectors with norm less than this threshold are considered null
Returns
projected solutions, and their overlap matrix

◆ construct_projected_solutions_overlap()

template<typename value_type >
auto molpro::linalg::itsolv::detail::dspace::construct_projected_solutions_overlap ( const subspace::Matrix< value_type > &  solutions_proj,
const subspace::Matrix< value_type > &  overlap,
const subspace::Dimensions dims,
const std::vector< int > &  remove_qspace,
Logger logger 
)

Constructs overlap matrix for projected solutions.

x_i = \sum_j C_ij u_j <x_i, x_i> = \sum_j \sum_k C_ij C_ik <u_j, u_k> <x_i, x_j> = \sum_k \sum_l C_ik C_jl <u_j, u_l>

Parameters
solutions_projsolutions matrix projected onto Qd+D space
dimsdimensions for partitioning of subspace
remove_qspaceindices to remove from current Q space and move into Q_{delete}
overlapoverlap matrix of the current subspace
loggerlogger
Returns
overlap matrix

◆ remove_null_norm_and_normalise()

template<typename value_type , typename value_type_abs >
void molpro::linalg::itsolv::detail::dspace::remove_null_norm_and_normalise ( subspace::Matrix< value_type > &  parameters,
subspace::Matrix< value_type > &  overlap,
const value_type_abs  norm_thresh,
Logger logger 
)

Removes parameters with norm less than threshold and normalises the rest.

Parameters
parametersrow major matrix of parameters
overlapoverlap matrix of parameters
norm_threshnorm threhsold
loggerlogger

◆ remove_null_projected_solutions()

template<typename value_type , typename value_type_abs >
auto molpro::linalg::itsolv::detail::dspace::remove_null_projected_solutions ( const subspace::Matrix< value_type > &  solutions_proj,
const subspace::Matrix< value_type > &  overlap_proj,
const value_type_abs  svd_thresh,
Logger logger 
)

Transforms to a stable subspace of projected solutions via SVD.

Performs SVD and transforms to right-singular vectors with singular values greater than threshold.

Parameters
solutions_projsolutions projected onto Qd+D space
solutionssolutions in the current subspace
overlap_projoverlap matrix of projected solutions
norm_thresh
logger
Returns
stable subspace of projected solutions