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

#include <occupy.h>

Collaboration diagram for Occupy:

Public Member Functions

 Occupy ()
 ~Occupy ()

Static Public Member Functions

static void decision (const std::string &name, const std::string &smearing_method, const double &smearing_sigma)
static const bool & gauss (void)
static const bool & fix (void)
static void iweights (const int nks, const std::vector< double > &wk, const int nband, const int band_offset, const double &nelec, const ModuleBase::matrix &ekb, double &ef, ModuleBase::matrix &wg, const int &is, const std::vector< int > &isk, const int nspin)
 calculates weights and fermi energy for semiconductors and insulators
static void gweights (const int nks, const std::vector< double > &wk, const int nband, const double &nelec, const double &smearing_sigma, const int ngauss, const ModuleBase::matrix &ekb, double &ef, double &demet, ModuleBase::matrix &wg, const int &is, const std::vector< int > &isk)
 calculates weights with the gaussian spreading technique
static void tweights (const int nks, const int nspin, const int nband, const double &nelec, const int ntetra, const ModuleBase::matrix &tetra, double **ekb, double &ef, ModuleBase::matrix &wg)
static double wsweight (const ModuleBase::Vector3< double > &r, ModuleBase::Vector3< double > *rws, const int nrws)

Static Public Attributes

static bool use_gaussian_broadening = false
static int gaussian_type = 0
static double gaussian_parameter = 0.01
static bool fixed_occupations = false

Static Private Member Functions

static void efermit (double **ekb, const int nband, const int nks, const double &nelec, const int nspin, const int ntetra, const ModuleBase::matrix &tetra, double &ef)
static double sumkt (double **ekb, const int nband, const int nks, const int nspin, const int ntetra, const ModuleBase::matrix &tetra, const double &eup)
static void piksort (const int n, double *a)

Constructor & Destructor Documentation

◆ Occupy()

Occupy::Occupy ( )

◆ ~Occupy()

Occupy::~Occupy ( )

Member Function Documentation

◆ decision()

void Occupy::decision ( const std::string & name,
const std::string & smearing_method,
const double & smearing_sigma )
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ efermit()

void Occupy::efermit ( double ** ekb,
const int nband,
const int nks,
const double & nelec,
const int nspin,
const int ntetra,
const ModuleBase::matrix & tetra,
double & ef )
staticprivate

◆ fix()

const bool & Occupy::fix ( void )
inlinestatic

◆ gauss()

const bool & Occupy::gauss ( void )
inlinestatic

◆ gweights()

void Occupy::gweights ( const int nks,
const std::vector< double > & wk,
const int nband,
const double & nelec,
const double & smearing_sigma,
const int ngauss,
const ModuleBase::matrix & ekb,
double & ef,
double & demet,
ModuleBase::matrix & wg,
const int & is,
const std::vector< int > & isk )
static

calculates weights with the gaussian spreading technique

Parameters
nksnumber of k points.
wkweight of each k point(symmetry considered).
nbandnumber of bands.
nelecnumber of electrons.
smearing_sigmaparameter input by user.
ngausswhich type of smearing.
ekbband energy.
efoutput: rounded absolute Fermi level
demetoutput: energy correction for metal
wgoutput: weight of each band at each k point
isspin
iskarray to point out each k belong to which spin
Here is the call graph for this function:
Here is the caller graph for this function:

◆ iweights()

void Occupy::iweights ( const int nks,
const std::vector< double > & wk,
const int nbands,
const int band_offset,
const double & nelec,
const ModuleBase::matrix & ekb,
double & ef,
ModuleBase::matrix & wg,
const int & is,
const std::vector< int > & isk,
const int nspin )
static

calculates weights and fermi energy for semiconductors and insulators

Parameters
nspinnumber of spin channels; 2 selects a single spin through isk when is != -1, and 4 halves the spin degeneracy
Note
It is only applicable to semiconductors and insulators that have an energy gap. Here, bands are either empty or filled, and there is no electronic transfer among different k-points.
Parameters
nksnumber of k points.
wkweight of each k point (consider symmetry).
nbandsnumber of locally owned bands.
band_offsetglobal index of the first locally owned band.
nelecnumber of electrons for this spin direction.
ekbthe array save the band energy.
efoutput: the highest occupied Kohn-Sham level.
wgoutput: weight for each k, each band.
isthe spin index now.
iskdistinguish k point belong to which spin.
nspinnumber of spin channels; 2 selects a single spin through isk when is != -1, and 4 halves the spin degeneracy.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ piksort()

void Occupy::piksort ( const int n,
double * a )
staticprivate

◆ sumkt()

double Occupy::sumkt ( double ** ekb,
const int nband,
const int nks,
const int nspin,
const int ntetra,
const ModuleBase::matrix & tetra,
const double & eup )
staticprivate

◆ tweights()

void Occupy::tweights ( const int nks,
const int nspin,
const int nband,
const double & nelec,
const int ntetra,
const ModuleBase::matrix & tetra,
double ** ekb,
double & ef,
ModuleBase::matrix & wg )
static

◆ wsweight()

double Occupy::wsweight ( const ModuleBase::Vector3< double > & r,
ModuleBase::Vector3< double > * rws,
const int nrws )
static

Member Data Documentation

◆ fixed_occupations

bool Occupy::fixed_occupations = false
static

◆ gaussian_parameter

double Occupy::gaussian_parameter = 0.01
static

◆ gaussian_type

int Occupy::gaussian_type = 0
static

◆ use_gaussian_broadening

bool Occupy::use_gaussian_broadening = false
static

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