18 #include "diagonalcalc.h"    20 #include "wrapperMPI.h"    51   i_max=
X->Check.idim_max;      
    52   Ns = 1.0*
X->Def.NsiteMPI;
    55 #pragma omp parallel for default(none) reduction(+: dnorm) private(i) shared(v0, v1) firstprivate(i_max, Ns, LargeValue)    56   for(i = 1; i <= i_max; i++){
    58     dnorm += conj(
v0[i])*
v0[i];
    63 #pragma omp parallel for default(none) private(i) shared(v0) firstprivate(i_max, dnorm)    64   for(i=1;i<=i_max;i++){
    87   double complex dnorm=0.0;
    88   double complex tmp1 = 1.0;
    89   double complex tmp2=0.0;
    90   double dt=
X->Def.Param.TimeSlice;
    93   i_max=
X->Check.idim_max;
    95   if(dt <pow(10.0, -14)){
    96 #pragma omp parallel for default(none) reduction(+: dnorm) private(i) shared(v0, v1, v2) firstprivate(i_max, dt, tmp2)    97     for(i = 1; i <= i_max; i++){
   107 #pragma omp parallel for default(none) reduction(+: dnorm) private(i) shared(v0, v1, v2) firstprivate(i_max, dt, tmp1, tmp2)   108     for (i = 1; i <= i_max; i++) {
   110       v0[i] = 
v1[i] + tmp1 * tmp2;  
   112       v2[i] = 0.0 + I * 0.0;
   114     for (coef = 2; coef <= 
X->Def.Param.ExpandCoef; coef++) {
   115       tmp1 *= -I * dt / (
double complex) coef;
   119 #pragma omp parallel for default(none) private(i) shared(v0, v1, v2) firstprivate(i_max, tmp1, myrank)   120       for (i = 1; i <= i_max; i++) {
   121         v0[i] += tmp1 * 
v2[i];
   123         v2[i] = 0.0 + I * 0.0;
   128 #pragma omp parallel for default(none) reduction(+: dnorm) private(i) shared(v0) firstprivate(i_max, dt)   129   for(i = 1; i <= i_max; i++){
   130     dnorm += conj(
v0[i])*
v0[i];
   135 #pragma omp parallel for default(none) private(i) shared(v0) firstprivate(i_max, dnorm)   136   for(i=1;i<=i_max;i++){
 int mltply(struct BindStruct *X, double complex *tmp_v0, double complex *tmp_v1)
Parent function of multiplying the wavefunction by the Hamiltonian. . First, the calculation of diago...
double complex SumMPI_dc(double complex norm)
MPI wrapper function to obtain sum of Double complex across processes. 
int Multiply(struct BindStruct *X)
Function of calculating the i-th step norm as  and update the i+1-th wave vector as  for TPQ calculat...
int MultiplyForTEM(struct BindStruct *X)
Function of multiplying Hamiltonian for Time Evolution.