HPhi++
3.1.0
|
Calculate diagonal components, i.e. \( H_d |\phi_0> = E_d |\phi_0> \). More...
#include <bitcalc.hpp>
#include "FileIO.hpp"
#include "diagonalcalc.hpp"
#include "mltplySpinCore.hpp"
#include "wrapperMPI.hpp"
#include <iostream>
Go to the source code of this file.
Functions | |
int | SetDiagonalTEInterAll (long int isite1, long int isite2, long int isigma1, long int isigma2, double dtmp_V, struct BindStruct *X, std::complex< double > *tmp_v0, std::complex< double > *tmp_v1) |
Update the vector by the general two-body diagonal interaction, \( H_{i\sigma_1 j\sigma_2} n_ {i\sigma_1}n_{j\sigma_2}\). (Using in Time Evolution mode). More... | |
int | SetDiagonalTEChemi (long int isite1, long int spin, double dtmp_V, struct BindStruct *X, std::complex< double > *tmp_v0, std::complex< double > *tmp_v1) |
Update the vector by the chemical potential \( \mu_{i \sigma_1} n_ {i \sigma_1} \) generated by the commutation relation in terms of the general two-body interaction, \( c_ {i \sigma_1} a_{j\sigma_2}c_ {j \sigma_2}a_ {i \sigma_1} = c_ {i \sigma_1}a_ {i \sigma_1}-c_ {i \sigma_1} a_ {i \sigma_1} c_ {j \sigma_2}a_{j\sigma_2}\) . (Using in Time Evolution mode). More... | |
int | SetDiagonalTETransfer (long int isite1, double dtmp_V, long int spin, struct BindStruct *X, std::complex< double > *tmp_v0, std::complex< double > *tmp_v1) |
Update the vector by the general one-body diagonal interaction, \( \mu_{i\sigma_1} n_ {i\sigma_1}\). (Using in Time Evolution mode). More... | |
int | diagonalcalcForTE (const int _istep, struct BindStruct *X, std::complex< double > *tmp_v0, std::complex< double > *tmp_v1) |
int | SetDiagonalCoulombIntra (long int isite1, double dtmp_V, struct BindStruct *X) |
Calculate the components for Coulombintra interaction, \( U_i n_ {i \uparrow}n_{i \downarrow} \). More... | |
int | SetDiagonalChemi (long int isite1, double dtmp_V, long int spin, struct BindStruct *X) |
Calculate the components for the chemical potential \( \mu_{i \sigma_1} n_ {i \sigma_1} \). More... | |
int | SetDiagonalCoulombInter (long int isite1, long int isite2, double dtmp_V, struct BindStruct *X) |
Calculate the components for Coulombinter interaction, \( V_{ij} n_ {i}n_{j} \). More... | |
int | SetDiagonalHund (long int isite1, long int isite2, double dtmp_V, struct BindStruct *X) |
Calculate the components for Hund interaction, \( H_{ij}(n_ {i\uparrow}n_{j\uparrow}+ n_ {i\downarrow}n_{j\downarrow})\). More... | |
int | SetDiagonalInterAll (long int isite1, long int isite2, long int isigma1, long int isigma2, double dtmp_V, struct BindStruct *X) |
Calculate the components for general two-body diagonal interaction, \( H_{i\sigma_1 j\sigma_2} n_ {i\sigma_1}n_{j\sigma_2}\). More... | |
int | diagonalcalc (struct BindStruct *X) |
Calculate diagonal components and obtain the list, list_diagonal. More... | |
Calculate diagonal components, i.e. \( H_d |\phi_0> = E_d |\phi_0> \).
add functions to calculate diagonal components for Time evolution.
modify functions to calculate diagonal components for general spin.
Definition in file diagonalcalc.cpp.
int diagonalcalc | ( | struct BindStruct * | X | ) |
Calculate diagonal components and obtain the list, list_diagonal.
X | [in] Struct to get the information of the diagonal operators. |
-1 | fail to calculate diagonal components. |
0 | succeed to calculate diagonal components. |
Definition at line 1912 of file diagonalcalc.cpp.
References BindStruct::Check, childfopenMPI(), DefineList::CoulombInter, DefineList::CoulombIntra, BindStruct::Def, DefineList::EDChemi, DefineList::EDNChemi, DefineList::EDParaChemi, DefineList::EDSpinChemi, DefineList::HundCoupling, CheckList::idim_max, DefineList::InterAll_Diagonal, list_Diagonal, DefineList::NCoulombInter, DefineList::NCoulombIntra, DefineList::NHundCoupling, DefineList::NInterAll_Diagonal, DefineList::ParaCoulombInter, DefineList::ParaCoulombIntra, DefineList::ParaHundCoupling, DefineList::ParaInterAll_Diagonal, SetDiagonalChemi(), SetDiagonalCoulombInter(), SetDiagonalCoulombIntra(), SetDiagonalHund(), SetDiagonalInterAll(), stdoutMPI, and TimeKeeper().
Referenced by CalcSpectrum(), main(), and SetDiagonalInterAll().
int diagonalcalcForTE | ( | const int | _istep, |
struct BindStruct * | X, | ||
std::complex< double > * | tmp_v0, | ||
std::complex< double > * | tmp_v1 | ||
) |
Definition at line 703 of file diagonalcalc.cpp.
References BindStruct::Def, DefineList::NTEChemi, DefineList::NTEInterAllDiagonal, DefineList::NTETransferDiagonal, DefineList::ParaTEChemi, DefineList::ParaTEInterAllDiagonal, DefineList::ParaTETransferDiagonal, SetDiagonalCoulombIntra(), SetDiagonalTEChemi(), SetDiagonalTEInterAll(), SetDiagonalTETransfer(), DefineList::SpinTEChemi, DefineList::TEChemi, DefineList::TEInterAllDiagonal, and DefineList::TETransferDiagonal.
Referenced by mltply(), and SetDiagonalTETransfer().
int SetDiagonalChemi | ( | long int | isite1, |
double | dtmp_V, | ||
long int | spin, | ||
struct BindStruct * | X | ||
) |
Calculate the components for the chemical potential \( \mu_{i \sigma_1} n_ {i \sigma_1} \).
isite1 | [in] a site number |
dtmp_V | [in] A value of coulombintra interaction \( \mu_{i \sigma_1} \) |
spin | [in] Spin index for the chemical potential |
X | [in] Define list to get dimension number |
-1 | fail to calculate the diagonal component. |
0 | succeed to calculate the diagonal component. |
Definition at line 871 of file diagonalcalc.cpp.
References BitCheckGeneral(), BindStruct::Check, BindStruct::Def, DefineList::iCalcModel, CheckList::idim_max, DefineList::iFlgGeneralSpin, list_1, list_Diagonal, myrank, DefineList::Nsite, SetDiagonalCoulombInter(), DefineList::SiteToBit, stdoutMPI, and DefineList::Tpow.
Referenced by diagonalcalc(), and SetDiagonalCoulombIntra().
int SetDiagonalCoulombInter | ( | long int | isite1, |
long int | isite2, | ||
double | dtmp_V, | ||
struct BindStruct * | X | ||
) |
Calculate the components for Coulombinter interaction, \( V_{ij} n_ {i}n_{j} \).
isite1 | [in] a site number \(i \) |
isite2 | [in] a site number \(j \) |
dtmp_V | [in] A value of coulombinter interaction \( V_{ij} \) |
X | [in] Define list to get the operator information. |
-1 | fail to calculate the diagonal component. |
0 | succeed to calculate the diagonal component. |
Definition at line 1041 of file diagonalcalc.cpp.
References BindStruct::Check, BindStruct::Def, DefineList::iCalcModel, CheckList::idim_max, list_1, list_Diagonal, myrank, DefineList::Nsite, SetDiagonalHund(), stdoutMPI, and DefineList::Tpow.
Referenced by diagonalcalc(), and SetDiagonalChemi().
int SetDiagonalCoulombIntra | ( | long int | isite1, |
double | dtmp_V, | ||
struct BindStruct * | X | ||
) |
Calculate the components for Coulombintra interaction, \( U_i n_ {i \uparrow}n_{i \downarrow} \).
isite1 | [in] a site number |
dtmp_V | [in] A value of coulombintra interaction \( U_i \) |
X | [in] Define list to get dimension number |
-1 | fail to calculate the diagonal component. |
0 | succeed to calculate the diagonal component. |
Definition at line 762 of file diagonalcalc.cpp.
References BindStruct::Check, BindStruct::Def, DefineList::iCalcModel, CheckList::idim_max, list_1, list_Diagonal, myrank, DefineList::Nsite, SetDiagonalChemi(), stdoutMPI, and DefineList::Tpow.
Referenced by diagonalcalc(), and diagonalcalcForTE().
int SetDiagonalHund | ( | long int | isite1, |
long int | isite2, | ||
double | dtmp_V, | ||
struct BindStruct * | X | ||
) |
Calculate the components for Hund interaction, \( H_{ij}(n_ {i\uparrow}n_{j\uparrow}+ n_ {i\downarrow}n_{j\downarrow})\).
isite1 | [in] a site number \(i \) |
isite2 | [in] a site number \(j \) |
dtmp_V | [in] A value of Hund interaction \( H_{ij} \) |
X | [in] Define list to get the operator information. |
-1 | fail to calculate the diagonal component. |
0 | succeed to calculate the diagonal component. |
Definition at line 1278 of file diagonalcalc.cpp.
References BindStruct::Check, BindStruct::Def, DefineList::iCalcModel, CheckList::idim_max, list_1, list_Diagonal, myrank, DefineList::Nsite, SetDiagonalInterAll(), stdoutMPI, and DefineList::Tpow.
Referenced by diagonalcalc(), and SetDiagonalCoulombInter().
int SetDiagonalInterAll | ( | long int | isite1, |
long int | isite2, | ||
long int | isigma1, | ||
long int | isigma2, | ||
double | dtmp_V, | ||
struct BindStruct * | X | ||
) |
Calculate the components for general two-body diagonal interaction, \( H_{i\sigma_1 j\sigma_2} n_ {i\sigma_1}n_{j\sigma_2}\).
isite1 | [in] a site number \(i \) |
isite2 | [in] a site number \(j \) |
isigma1 | [in] a spin index at \(i \) site. |
isigma2 | [in] a spin index at \(j \) site. |
dtmp_V | [in] A value of general two-body diagonal interaction \( H_{i\sigma_1 j\sigma_2} \) |
X | [in] Define list to get the operator information. |
-1 | fail to calculate the diagonal component. |
0 | succeed to calculate the diagonal component. |
Definition at line 1601 of file diagonalcalc.cpp.
References BitCheckGeneral(), BindStruct::Check, BindStruct::Def, diagonalcalc(), DefineList::iCalcModel, CheckList::idim_max, DefineList::iFlgGeneralSpin, list_1, list_Diagonal, myrank, DefineList::Nsite, DefineList::SiteToBit, stdoutMPI, DefineList::Tpow, X_Spin_CisAis(), and X_SpinGC_CisAis().
Referenced by diagonalcalc(), and SetDiagonalHund().
int SetDiagonalTEChemi | ( | long int | isite1, |
long int | spin, | ||
double | dtmp_V, | ||
struct BindStruct * | X, | ||
std::complex< double > * | tmp_v0, | ||
std::complex< double > * | tmp_v1 | ||
) |
Update the vector by the chemical potential \( \mu_{i \sigma_1} n_ {i \sigma_1} \)
generated by the commutation relation in terms of the general two-body interaction,
\( c_ {i \sigma_1} a_{j\sigma_2}c_ {j \sigma_2}a_ {i \sigma_1} = c_ {i \sigma_1}a_ {i \sigma_1}-c_ {i \sigma_1} a_ {i \sigma_1} c_ {j \sigma_2}a_{j\sigma_2}\) . (Using in Time Evolution mode).
isite1 | [in] a site number |
spin | [in] a spin number |
dtmp_V | [in] A value of coulombintra interaction \( \mu_{i \sigma_1} \) |
X | [in] Define list to get dimension number |
tmp_v0 | [in,out] Result vector |
tmp_v1 | [in] Input produced vector |
-1 | fail to calculate the diagonal component. |
0 | succeed to calculate the diagonal component. |
Definition at line 375 of file diagonalcalc.cpp.
References BitCheckGeneral(), BindStruct::Check, BindStruct::Def, DefineList::iCalcModel, CheckList::idim_max, DefineList::iFlgGeneralSpin, list_1, myrank, DefineList::Nsite, SetDiagonalTETransfer(), DefineList::SiteToBit, stdoutMPI, and DefineList::Tpow.
Referenced by diagonalcalcForTE().
int SetDiagonalTEInterAll | ( | long int | isite1, |
long int | isite2, | ||
long int | isigma1, | ||
long int | isigma2, | ||
double | dtmp_V, | ||
struct BindStruct * | X, | ||
std::complex< double > * | tmp_v0, | ||
std::complex< double > * | tmp_v1 | ||
) |
Update the vector by the general two-body diagonal interaction, \( H_{i\sigma_1 j\sigma_2} n_ {i\sigma_1}n_{j\sigma_2}\).
(Using in Time Evolution mode).
isite1 | [in] a site number \(i \) |
isite2 | [in] a site number \(j \) |
isigma1 | [in] a spin index at \(i \) site. |
isigma2 | [in] a spin index at \(j \) site. |
dtmp_V | [in] A value of general two-body diagonal interaction \( H_{i\sigma_1 j\sigma_2} \) |
X | [in] Define list to get the operator information. |
tmp_v0 | [in,out] Result vector |
tmp_v1 | [in] Input produced vector |
-1 | fail to calculate the diagonal component. |
0 | succeed to calculate the diagonal component. |
Definition at line 58 of file diagonalcalc.cpp.
References BitCheckGeneral(), BindStruct::Check, BindStruct::Def, DefineList::iCalcModel, CheckList::idim_max, DefineList::iFlgGeneralSpin, list_1, myrank, DefineList::Nsite, DefineList::SiteToBit, stdoutMPI, DefineList::Tpow, X_Spin_CisAis(), and X_SpinGC_CisAis().
Referenced by diagonalcalcForTE().
int SetDiagonalTETransfer | ( | long int | isite1, |
double | dtmp_V, | ||
long int | spin, | ||
struct BindStruct * | X, | ||
std::complex< double > * | tmp_v0, | ||
std::complex< double > * | tmp_v1 | ||
) |
Update the vector by the general one-body diagonal interaction, \( \mu_{i\sigma_1} n_ {i\sigma_1}\).
(Using in Time Evolution mode).
isite1 | [in] a site number \(i \) |
dtmp_V | [in] A value of general one-body diagonal interaction \( \mu_{i\sigma_1} \) |
spin | [in] a spin index at \(i \) site. |
X | [in] Define list to get the operator information. |
tmp_v0 | [in,out] Result vector |
tmp_v1 | [in] Input produced vector |
-1 | fail to calculate the diagonal component. |
0 | succeed to calculate the diagonal component. |
Definition at line 545 of file diagonalcalc.cpp.
References BitCheckGeneral(), BindStruct::Check, BindStruct::Def, diagonalcalcForTE(), DefineList::iCalcModel, CheckList::idim_max, DefineList::iFlgGeneralSpin, list_1, myrank, DefineList::Nsite, DefineList::SiteToBit, stdoutMPI, and DefineList::Tpow.
Referenced by diagonalcalcForTE(), and SetDiagonalTEChemi().