ABACUS develop
Atomic-orbital Based Ab-initio Computation at UStc
Loading...
Searching...
No Matches
ModuleIO::Angmom_op Class Reference

#include <angmom_op_mat.h>

Collaboration diagram for ModuleIO::Angmom_op:

Public Member Functions

 Angmom_op ()=delete
 Angmom_op (const std::string &orbital_dir, const UnitCell &ucell, const double &search_radius, const int tdestructor, const int tgrid, const int tatom, const bool searchpbc, const std::string &out_level, const bool gamma_only, std::ofstream *ptr_log=nullptr, const int rank=0)
 Construct a new Angular Momentum Expectation Calculator object.
 ~Angmom_op ()=default
void calculate (const std::string &prefix, const std::string &outdir, const UnitCell &ucell, const Parallel_Orbitals &pv, const int precision, const int rank, const int istep, const int out_app_flag)
 Calculate and write <phi_i|Lx/Ly/Lz|phi_j> matrix elements.

Private Attributes

std::ofstream fallback_ofs_
std::ofstream * ofs_ = nullptr
std::unique_ptr< TwoCenterIntegrator > calculator_
ModuleBase::SphericalBesselTransformer sbt_
std::unique_ptr< RadialCollection > orb_
std::unique_ptr< Grid_Driver > neighbor_searcher_

Constructor & Destructor Documentation

◆ Angmom_op() [1/2]

ModuleIO::Angmom_op::Angmom_op ( )
delete

◆ Angmom_op() [2/2]

ModuleIO::Angmom_op::Angmom_op ( const std::string & orbital_dir,
const UnitCell & ucell,
const double & search_radius,
const int tdestructor,
const int tgrid,
const int tatom,
const bool searchpbc,
const std::string & out_level,
const bool gamma_only,
std::ofstream * ptr_log = nullptr,
const int rank = 0 )

Construct a new Angular Momentum Expectation Calculator object.

Parameters
orbital_dirthe directory of the orbital file
ucellthe unit cell object
search_radiusthe search radius for the neighboring atoms
tdestructortest flag, for destructor
tgridtest flag, for grid
tatomtest flag, for atom input
searchpbc
out_levelthe output verbosity level
gamma_onlywhether the calculation is gamma-only
ptr_logpointer to the ofstream object for logging
Here is the call graph for this function:

◆ ~Angmom_op()

ModuleIO::Angmom_op::~Angmom_op ( )
default

Member Function Documentation

◆ calculate()

void ModuleIO::Angmom_op::calculate ( const std::string & prefix,
const std::string & outdir,
const UnitCell & ucell,
const Parallel_Orbitals & pv,
const int precision,
const int rank,
const int istep,
const int out_app_flag )

Calculate and write <phi_i|Lx/Ly/Lz|phi_j> matrix elements.

Parameters
prefixthe suffix of the output files (currently unused; filenames are fixed as l{x,y,z}[g{step+1}]_nao.csr)
outdirthe output directory
ucellthe unit cell object
pvthe parallel orbital distribution, used for the global basis size of the CSR output
precisionthe precision of the output
rankthe MPI rank
istepthe ionic step index; -1 for single-point runs
out_app_flagappend mode: with 1 the fixed filename l{x,y,z}_nao.csr is reused and each step appends; with 2 the filename carries g{istep+1} (e.g., lxg1_nao.csr); with 0 the fixed filename is overwritten at every write

Filename suffix: modes 0 and 1 reuse the fixed name (mode 0 overwrites, mode 1 appends each written step); only mode 2 carries "g{istep+1}" (e.g., "g1") following the out_freq_ion convention.

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ calculator_

std::unique_ptr<TwoCenterIntegrator> ModuleIO::Angmom_op::calculator_
private

◆ fallback_ofs_

std::ofstream ModuleIO::Angmom_op::fallback_ofs_
private

◆ neighbor_searcher_

std::unique_ptr<Grid_Driver> ModuleIO::Angmom_op::neighbor_searcher_
private

◆ ofs_

std::ofstream* ModuleIO::Angmom_op::ofs_ = nullptr
private

◆ orb_

std::unique_ptr<RadialCollection> ModuleIO::Angmom_op::orb_
private

◆ sbt_

ModuleBase::SphericalBesselTransformer ModuleIO::Angmom_op::sbt_
private

The documentation for this class was generated from the following files: