|
ABACUS develop
Atomic-orbital Based Ab-initio Computation at UStc
|
Free-function helpers for folding S/dS matrices, extracted from Plus_U. Each function takes the data it needs (orb_cutoff, ks_solver, npol, gamma_only_local, nspin) as direct parameters; no Plus_U reference is required, so the helpers are fully decoupled from the class and unit-testable. More...
#include "source_basis/module_ao/parallel_orbitals.h"#include "source_cell/module_neighbor/sltk_grid_driver.h"#include "source_cell/unitcell.h"#include "source_lcao/force_stress_arrays.h"#include "source_hamilt/hamilt.h"#include <complex>#include <string>#include <vector>Go to the source code of this file.
Classes | |
| struct | DFTU_LCAO::FoldingCtx |
| Shared context for the folding helpers. Bundles the read-only parameters that every folding variant needs (npol, ks_solver, orbital cutoffs, unit cell, parallel-orbitals descriptor, and the grid driver) so the per-call signatures stay small. More... | |
Namespaces | |
| namespace | DFTU_LCAO |
Functions | |
| bool | DFTU_LCAO::is_adjacent_pair (const std::vector< double > &orb_cutoff, const UnitCell &ucell, const Grid_Driver &gd, int T1, int T2, const ModuleBase::Vector3< double > &tau1, const ModuleBase::Vector3< double > &tau2) |
| Judge whether atom pair (T1,I1) and (T2,I2,tau2) are adjacent by direct orbital cutoff overlap or three-body bridging via a common nonlocal projector center T0. | |
| int | DFTU_LCAO::get_linear_index (const std::string &ks_solver, int mu, int nu, const Parallel_Orbitals &pv) |
| Get the linear index of local matrix element (mu, nu) based on ks_solver (column-major or row-major). | |
| void | DFTU_LCAO::fold_dSR_gamma (const FoldingCtx &ctx, double *dsloc_x, double *dsloc_y, double *dsloc_z, double *dh_r, int dim1, int dim2, double *dSR_gamma) |
| Fold the dSR matrix for gamma-only calculations. npol is the spin-polarization factor; orb_cutoff and ks_solver are forwarded to is_adjacent_pair and get_linear_index. | |
| void | DFTU_LCAO::folding_matrix_k (const FoldingCtx &ctx, ForceStressArrays &fsr, int ik, int dim1, int dim2, std::complex< double > *mat_k, const ModuleBase::Vector3< double > &kvec_d) |
| void | DFTU_LCAO::folding_matrix_k_new (const std::string &ks_solver, bool gamma_only_local, int nspin, int ik, hamilt::Hamilt< std::complex< double > > *p_ham) |
| new function of folding_S_matrix only for Hamiltonian now, for force and stress will be developed later use HContainer as input and output in mat_k | |
Free-function helpers for folding S/dS matrices, extracted from Plus_U. Each function takes the data it needs (orb_cutoff, ks_solver, npol, gamma_only_local, nspin) as direct parameters; no Plus_U reference is required, so the helpers are fully decoupled from the class and unit-testable.