QNANO
Public Member Functions | Public Attributes | List of all members
Coulomb_Matrix_Elements_Calculator Class Reference
Collaboration diagram for Coulomb_Matrix_Elements_Calculator:
Collaboration graph
[legend]

Public Member Functions

void add_longrange (const Atom_List &atlist, const Distribute_EV_List &EV_e, const Distribute_EV_List &EV_h, int nr_e, int nr_h, double epsilon, int nrblocks, int verbosity=1)
 
void add_onsite (const Atom_List &atlist, const Coulomb_Onsite_Storage_List &onsite_storage_list, const Distribute_EV_List &EV_e, const Distribute_EV_List &EV_h, int nr_e, int nr_h, double epsilon, int verbosity=1)
 
void MPI_Reduce_to_Node0 ()
 Add parts calculated on different nodes and move them to node 0.
 
 Coulomb_Matrix_Elements_Calculator (Coulomb_Matrix_Elements::Type type, int nr_e, int nr_h)
 

Public Attributes

Coulomb_Matrix_Elements mat_elem
 

Member Function Documentation

void Coulomb_Matrix_Elements_Calculator::add_longrange ( const Atom_List atlist,
const Distribute_EV_List EV_e,
const Distribute_EV_List EV_h,
int  nr_e,
int  nr_h,
double  epsilon,
int  nrblocks,
int  verbosity = 1 
)

LONGRANGE PART: Calculation of the longrange part requires taking the matrix product

Vijkl=(sum_m phi^*_{im} phi_{lm})^T U (sum_m phi^*_{jm} phi_{km}) Phi_{r,{ij}}=(sum_m phi^*_{im} phi_{jm})

Main problem: storage of all eigenvector data at each process Solution: Distribute Eigenvectors according to atom numbers across processes Also: further decompose nr. of local atoms into blocks to reduce memory for U

  • read and distribute eigenvectors
  • loop through blocks for Phi_2 (decompose local atoms):
    • calculate local part of Phi_2
    • loop through blocks for Phi_1 (decompose local atoms):
      • ask subsequently for local parts of Phi_1 from processes 0,1,2,...
      • calculate U
      • calculate contribution to Phi_1*U*Phi_2 and add to coulomb_storage
  • Finally, sum up all contributions from all processes

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