ABACUS develop
Atomic-orbital Based Ab-initio Computation at UStc
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Private Attributes | List of all members
Parallel_K2D< TK > Class Template Reference

#include <parallel_k2d.h>

Collaboration diagram for Parallel_K2D< TK >:

Public Member Functions

 Parallel_K2D ()
 private constructor
 
 ~Parallel_K2D ()
 private destructor
 
void set_para_env (int nks, const int &nw, const int &nb2d, const int &nproc, const int &my_rank, const int &nspin)
 
void distribute_hsk (hamilt::Hamilt< TK > *pHamilt, const std::vector< int > &ik_kpar, const int &nw)
 this function distributes the Hk and Sk matrices to hk_pool and sk_pool
 
void unset_para_env ()
 
void set_kpar (int kpar)
 set the number of k-points
 
int get_kpar ()
 get the number of k-points
 
int get_my_pool ()
 get my pool
 
Parallel_Kpointsget_pKpoints ()
 get pKpoints
 
Parallel_2Dget_p2D_global ()
 get p2D_global
 
Parallel_2Dget_p2D_pool ()
 get p2D_pool
 

Public Attributes

std::vector< TK > hk_pool
 
std::vector< TK > sk_pool
 
MPI_Comm POOL_WORLD_K2D
 

Private Attributes

int kpar_ = 0
 
int NPROC_IN_POOL
 
int MY_POOL
 
int RANK_IN_POOL
 
Parallel_KpointsPkpoints = nullptr
 
Parallel_2DP2D_global = nullptr
 
Parallel_2DP2D_pool = nullptr
 

Constructor & Destructor Documentation

◆ Parallel_K2D()

template<typename TK >
Parallel_K2D< TK >::Parallel_K2D ( )
inline

private constructor

◆ ~Parallel_K2D()

template<typename TK >
Parallel_K2D< TK >::~Parallel_K2D ( )
inline

private destructor

Member Function Documentation

◆ distribute_hsk()

template<typename TK >
void Parallel_K2D< TK >::distribute_hsk ( hamilt::Hamilt< TK > *  pHamilt,
const std::vector< int > &  ik_kpar,
const int &  nw 
)

this function distributes the Hk and Sk matrices to hk_pool and sk_pool

Here is the call graph for this function:

◆ get_kpar()

template<typename TK >
int Parallel_K2D< TK >::get_kpar ( )
inline

get the number of k-points

◆ get_my_pool()

template<typename TK >
int Parallel_K2D< TK >::get_my_pool ( )
inline

get my pool

◆ get_p2D_global()

template<typename TK >
Parallel_2D * Parallel_K2D< TK >::get_p2D_global ( )
inline

get p2D_global

◆ get_p2D_pool()

template<typename TK >
Parallel_2D * Parallel_K2D< TK >::get_p2D_pool ( )
inline

get p2D_pool

◆ get_pKpoints()

template<typename TK >
Parallel_Kpoints * Parallel_K2D< TK >::get_pKpoints ( )
inline

get pKpoints

◆ set_kpar()

template<typename TK >
void Parallel_K2D< TK >::set_kpar ( int  kpar)

set the number of k-points

Here is the call graph for this function:

◆ set_para_env()

template<typename TK >
void Parallel_K2D< TK >::set_para_env ( int  nks,
const int &  nw,
const int &  nb2d,
const int &  nproc,
const int &  my_rank,
const int &  nspin 
)

Public member functions this function sets the parallel environment for k-points parallelism including the glabal and pool 2D parallel distribution

Here is the call graph for this function:

◆ unset_para_env()

template<typename TK >
void Parallel_K2D< TK >::unset_para_env ( )

this function unsets the parallel environment for k-points parallelism including the glabal and pool 2D parallel distribution

Member Data Documentation

◆ hk_pool

template<typename TK >
std::vector<TK> Parallel_K2D< TK >::hk_pool

the local Hk, Sk matrices in POOL_WORLD_K2D

◆ kpar_

template<typename TK >
int Parallel_K2D< TK >::kpar_ = 0
private

Private member variables

◆ MY_POOL

template<typename TK >
int Parallel_K2D< TK >::MY_POOL
private

◆ NPROC_IN_POOL

template<typename TK >
int Parallel_K2D< TK >::NPROC_IN_POOL
private

mpi info

◆ P2D_global

template<typename TK >
Parallel_2D* Parallel_K2D< TK >::P2D_global = nullptr
private

◆ P2D_pool

template<typename TK >
Parallel_2D* Parallel_K2D< TK >::P2D_pool = nullptr
private

◆ Pkpoints

template<typename TK >
Parallel_Kpoints* Parallel_K2D< TK >::Pkpoints = nullptr
private

the pointer to Parallel_Kpoints

◆ POOL_WORLD_K2D

template<typename TK >
MPI_Comm Parallel_K2D< TK >::POOL_WORLD_K2D

◆ RANK_IN_POOL

template<typename TK >
int Parallel_K2D< TK >::RANK_IN_POOL
private

◆ sk_pool

template<typename TK >
std::vector<TK> Parallel_K2D< TK >::sk_pool

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