HPhi++  3.1.0
mltplyMPISpin.cpp
Go to the documentation of this file.
1 /* HPhi - Quantum Lattice Model Simulator */
2 /* Copyright (C) 2015 The University of Tokyo */
3 
4 /* This program is free software: you can redistribute it and/or modify */
5 /* it under the terms of the GNU General Public License as published by */
6 /* the Free Software Foundation, either version 3 of the License, or */
7 /* (at your option) any later version. */
8 
9 /* This program is distributed in the hope that it will be useful, */
10 /* but WITHOUT ANY WARRANTY; without even the implied warranty of */
11 /* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the */
12 /* GNU General Public License for more details. */
13 
14 /* You should have received a copy of the GNU General Public License */
15 /* along with this program. If not, see <http://www.gnu.org/licenses/>. */
20 #include "Common.hpp"
21 #include "mltplyCommon.hpp"
22 #include "bitcalc.hpp"
23 #include "wrapperMPI.hpp"
24 #include "mltplyMPISpin.hpp"
25 #include "mltplyMPISpinCore.hpp"
26 
33  long int i_int,
34  struct BindStruct *X,
35  int nstate, std::complex<double> **tmp_v0,
36  std::complex<double> **tmp_v1
37 ){
39  (int)X->Def.InterAll_OffDiagonal[i_int][0], (int)X->Def.InterAll_OffDiagonal[i_int][1],
40  (int)X->Def.InterAll_OffDiagonal[i_int][3], (int)X->Def.InterAll_OffDiagonal[i_int][4],
41  (int)X->Def.InterAll_OffDiagonal[i_int][5], (int)X->Def.InterAll_OffDiagonal[i_int][7],
42  X->Def.ParaInterAll_OffDiagonal[i_int], X, nstate, tmp_v0, tmp_v1);
43 }/*void child_general_int_spin_MPIdouble*/
50  int org_isite1,
51  int org_ispin1,
52  int org_ispin2,
53  int org_isite3,
54  int org_ispin3,
55  int org_ispin4,
56  std::complex<double> tmp_J,
57  struct BindStruct *X,
58  int nstate, std::complex<double> **tmp_v0,
59  std::complex<double> **tmp_v1
60 ) {
61  int mask1, mask2, state1, state2, origin;
62  long int idim_max_buf, j, ioff;
63  std::complex<double> Jint;
64  int one = 1;
65 
66  mask1 = (int)X->Def.Tpow[org_isite1];
67  mask2 = (int)X->Def.Tpow[org_isite3];
68  origin = myrank ^ (mask1 + mask2);
69 
70  state1 = (origin & mask1) / mask1;
71  state2 = (origin & mask2) / mask2;
72 
73  if (state1 == org_ispin2 && state2 == org_ispin4) {
74  Jint = tmp_J;
75  }
76  else if (state1 == org_ispin1 && state2 == org_ispin3) {
77  Jint = conj(tmp_J);
78  if (X->Large.mode == M_CORR || X->Large.mode == M_CALCSPEC) {
79  Jint = 0;
80  }
81  }
82  else return;
83 
84  idim_max_buf = SendRecv_i(origin, X->Check.idim_max);
85  SendRecv_iv(origin, X->Check.idim_max + 1, idim_max_buf + 1, list_1, list_1buf);
86  SendRecv_cv(origin, X->Check.idim_max*nstate, idim_max_buf*nstate, &tmp_v1[1][0], &v1buf[1][0]);
87 
88 #pragma omp parallel for default(none) private(j, ioff) \
89  firstprivate(idim_max_buf,Jint,X) shared(list_2_1,list_2_2,list_1buf,v1buf,tmp_v1,tmp_v0,nstate,one)
90  for (j = 1; j <= idim_max_buf; j++) {
92  X->Large.irght, X->Large.ilft, X->Large.ihfbit, &ioff);
93  zaxpy_(&nstate, &Jint, &v1buf[j][0], &one, &tmp_v0[ioff][0], &one);
94  }/*for (j = 1; j <= idim_max_buf; j++)*/
95 }/*std::complex<double> X_child_general_int_spin_MPIdouble*/
102  int org_isite1,
103  int org_isite3,
104  struct BindStruct *X,
105  int nstate, std::complex<double> **tmp_v0,
106  std::complex<double> **tmp_v1
107 ){
108  int mask1, mask2, num1_up, num2_up, origin, one = 1;
109  long int idim_max_buf, j, ioff, ibit_tmp;
110  std::complex<double> dmv;
111 
112  mask1 = (int)X->Def.Tpow[org_isite1];
113  mask2 = (int)X->Def.Tpow[org_isite3];
114  if (mask1 == mask2) origin = myrank ^ mask1;
115  else origin = myrank ^ (mask1 + mask2);
116  num1_up = (origin & mask1) / mask1;
117  num2_up = (origin & mask2) / mask2;
118 
119  ibit_tmp = (num1_up) ^ (num2_up);
120  if (ibit_tmp == 0) return;
121 
122  idim_max_buf = SendRecv_i(origin, X->Check.idim_max);
123  SendRecv_iv(origin, X->Check.idim_max + 1, idim_max_buf + 1, list_1, list_1buf);
124  SendRecv_cv(origin, X->Check.idim_max*nstate, idim_max_buf*nstate, &tmp_v1[1][0], &v1buf[1][0]);
125 
126 #pragma omp parallel for default(none) private(j, dmv, ioff) \
127  firstprivate(idim_max_buf, X) \
128  shared(list_2_1, list_2_2, list_1buf, v1buf, tmp_v1, tmp_v0,nstate,one)
129  for (j = 1; j <= idim_max_buf; j++) {
131  X->Large.irght, X->Large.ilft, X->Large.ihfbit, &ioff);
132  zaxpy_(&nstate, &dmv, &v1buf[j][0], &one, &tmp_v0[ioff][0], &one);
133  }/*for (j = 1; j <= idim_max_buf; j++)*/
134  return;
135 }/*std::complex<double> X_child_general_int_spin_MPIdouble*/
142  long int i_int,
143  struct BindStruct *X,
144  int nstate, std::complex<double> **tmp_v0,
145  std::complex<double> **tmp_v1
146 ){
147 
149  (int)X->Def.InterAll_OffDiagonal[i_int][0], (int)X->Def.InterAll_OffDiagonal[i_int][1],
150  (int)X->Def.InterAll_OffDiagonal[i_int][3], (int)X->Def.InterAll_OffDiagonal[i_int][4],
151  (int)X->Def.InterAll_OffDiagonal[i_int][5], (int)X->Def.InterAll_OffDiagonal[i_int][7],
152  X->Def.ParaInterAll_OffDiagonal[i_int], X, nstate, tmp_v0, tmp_v1);
153 }/*void child_general_int_spin_MPIsingle*/
154 /*
155 @brief General interaction term of canonical spin system.
156 site 3 is in the inter process region
157 */
159  int org_isite1,
160  int org_ispin1,
161  int org_ispin2,
162  int org_isite3,
163  int org_ispin3,
164  int org_ispin4,
165  std::complex<double> tmp_J,
166  struct BindStruct *X,
167  int nstate, std::complex<double> **tmp_v0,
168  std::complex<double> **tmp_v1
169 ) {
170  int mask2, state2, origin;
171  long int mask1, idim_max_buf, j, ioff, state1, jreal, state1check;
172  std::complex<double> Jint;
173  int one = 1;
174  /*
175  Prepare index in the inter PE
176  */
177  mask2 = (int)X->Def.Tpow[org_isite3];
178  origin = myrank ^ mask2;
179  state2 = (origin & mask2) / mask2;
180 
181  if (state2 == org_ispin4) {
182  state1check = (long int) org_ispin2;
183  Jint = tmp_J;
184  }
185  else if (state2 == org_ispin3) {
186  state1check = (long int) org_ispin1;
187  Jint = conj(tmp_J);
188  if (X->Large.mode == M_CORR || X->Large.mode == M_CALCSPEC) {
189  Jint = 0;
190  }
191  }
192  else return;
193 
194  idim_max_buf = SendRecv_i(origin, X->Check.idim_max);
195  SendRecv_iv(origin, X->Check.idim_max + 1, idim_max_buf + 1, list_1, list_1buf);
196  SendRecv_cv(origin, X->Check.idim_max*nstate, idim_max_buf*nstate, &tmp_v1[1][0], &v1buf[1][0]);
197  /*
198  Index in the intra PE
199  */
200  mask1 = X->Def.Tpow[org_isite1];
201  //printf("debug1 %ld\n", idim_max_buf);
202 
203 #pragma omp parallel for default(none) private(j, ioff, jreal, state1) \
204 firstprivate(idim_max_buf, Jint, X, mask1, state1check, org_isite1) \
205 shared(list_2_1, list_2_2, list_1buf, v1buf, tmp_v1, tmp_v0,nstate,one)
206  for (j = 1; j <= idim_max_buf; j++) {
207  jreal = list_1buf[j];
208 
209  state1 = (jreal & mask1) / mask1;
210  if (state1 == state1check) {
211  GetOffComp(list_2_1, list_2_2, jreal ^ mask1,
212  X->Large.irght, X->Large.ilft, X->Large.ihfbit, &ioff);
213  zaxpy_(&nstate, &Jint, &v1buf[j][0], &one, &tmp_v0[ioff][0], &one);
214  }
215  }
216 }/*std::complex<double> X_child_general_int_spin_MPIsingle*/
223  long int i_int,
224  struct BindStruct *X,
225  int nstate, std::complex<double> **tmp_v0,
226  std::complex<double> **tmp_v1
227 ){
228  if (X->Def.InterAll_OffDiagonal[i_int][1] == X->Def.InterAll_OffDiagonal[i_int][3] &&
229  X->Def.InterAll_OffDiagonal[i_int][5] != X->Def.InterAll_OffDiagonal[i_int][7]) {
230  GC_child_CisAisCjuAjv_spin_MPIdouble(i_int, X, nstate, tmp_v0, tmp_v1);
231  }
232  else if (X->Def.InterAll_OffDiagonal[i_int][1] != X->Def.InterAll_OffDiagonal[i_int][3] &&
233  X->Def.InterAll_OffDiagonal[i_int][5] == X->Def.InterAll_OffDiagonal[i_int][7]) {
234  GC_child_CisAitCjuAju_spin_MPIdouble(i_int, X, nstate, tmp_v0, tmp_v1);
235  }
236  else {
237  GC_child_CisAitCiuAiv_spin_MPIdouble(i_int, X, nstate, tmp_v0, tmp_v1);
238  }
239 }/*void GC_child_general_int_spin_MPIdouble*/
246  long int i_int,
247  struct BindStruct *X,
248  int nstate, std::complex<double> **tmp_v0,
249  std::complex<double> **tmp_v1
250 ){
251  if (X->Def.InterAll_OffDiagonal[i_int][1] == X->Def.InterAll_OffDiagonal[i_int][3] &&
252  X->Def.InterAll_OffDiagonal[i_int][5] != X->Def.InterAll_OffDiagonal[i_int][7]) {
253  GC_child_CisAisCjuAjv_spin_MPIsingle(i_int, X, nstate, tmp_v0, tmp_v1);
254  }
255  else if (X->Def.InterAll_OffDiagonal[i_int][1] != X->Def.InterAll_OffDiagonal[i_int][3] &&
256  X->Def.InterAll_OffDiagonal[i_int][5] == X->Def.InterAll_OffDiagonal[i_int][7]) {
257  GC_child_CisAitCjuAju_spin_MPIsingle(i_int, X, nstate, tmp_v0, tmp_v1);
258  }
259  else {
260  GC_child_CisAitCiuAiv_spin_MPIsingle(i_int, X, nstate, tmp_v0, tmp_v1);
261  }
262 }/*void GC_child_general_int_spin_MPIsingle*/
269  long int i_int,
270  struct BindStruct *X,
271  int nstate, std::complex<double> **tmp_v0,
272  std::complex<double> **tmp_v1
273 ){
274 
275  if (X->Def.InterAll_OffDiagonal[i_int][1] == X->Def.InterAll_OffDiagonal[i_int][3] &&
276  X->Def.InterAll_OffDiagonal[i_int][5] != X->Def.InterAll_OffDiagonal[i_int][7]) {
278  X->Def.InterAll_OffDiagonal[i_int][0], X->Def.InterAll_OffDiagonal[i_int][1],
279  X->Def.InterAll_OffDiagonal[i_int][4], X->Def.InterAll_OffDiagonal[i_int][5],
280  X->Def.InterAll_OffDiagonal[i_int][7], X->Def.ParaInterAll_OffDiagonal[i_int], X, nstate, tmp_v0, tmp_v1);
281  }
282  else if (X->Def.InterAll_OffDiagonal[i_int][1] != X->Def.InterAll_OffDiagonal[i_int][3] &&
283  X->Def.InterAll_OffDiagonal[i_int][5] == X->Def.InterAll_OffDiagonal[i_int][7]) {
285  X->Def.InterAll_OffDiagonal[i_int][0], X->Def.InterAll_OffDiagonal[i_int][1],
286  X->Def.InterAll_OffDiagonal[i_int][3], X->Def.InterAll_OffDiagonal[i_int][4],
287  X->Def.InterAll_OffDiagonal[i_int][5], X->Def.ParaInterAll_OffDiagonal[i_int], X, nstate, tmp_v0, tmp_v1);
288  }
289  else {
291  X->Def.InterAll_OffDiagonal[i_int][0], X->Def.InterAll_OffDiagonal[i_int][1],
292  X->Def.InterAll_OffDiagonal[i_int][3], X->Def.InterAll_OffDiagonal[i_int][4],
293  X->Def.InterAll_OffDiagonal[i_int][5], X->Def.InterAll_OffDiagonal[i_int][7],
294  X->Def.ParaInterAll_OffDiagonal[i_int], X, nstate, tmp_v0, tmp_v1);
295  }
296 }/*void GC_child_general_int_spin_MPIdouble*/
303  long int i_int,
304  struct BindStruct *X,
305  int nstate, std::complex<double> **tmp_v0,
306  std::complex<double> **tmp_v1
307 ){
308 
309  if (X->Def.InterAll_OffDiagonal[i_int][1] == X->Def.InterAll_OffDiagonal[i_int][3] &&
310  X->Def.InterAll_OffDiagonal[i_int][5] != X->Def.InterAll_OffDiagonal[i_int][7]) {
312  X->Def.InterAll_OffDiagonal[i_int][0], X->Def.InterAll_OffDiagonal[i_int][1],
313  X->Def.InterAll_OffDiagonal[i_int][4], X->Def.InterAll_OffDiagonal[i_int][5],
314  X->Def.InterAll_OffDiagonal[i_int][7], X->Def.ParaInterAll_OffDiagonal[i_int], X, nstate, tmp_v0, tmp_v1);
315  }
316  else if (X->Def.InterAll_OffDiagonal[i_int][1] != X->Def.InterAll_OffDiagonal[i_int][3] &&
317  X->Def.InterAll_OffDiagonal[i_int][5] == X->Def.InterAll_OffDiagonal[i_int][7]) {
319  X->Def.InterAll_OffDiagonal[i_int][0], X->Def.InterAll_OffDiagonal[i_int][1],
320  X->Def.InterAll_OffDiagonal[i_int][3], X->Def.InterAll_OffDiagonal[i_int][4],
321  X->Def.InterAll_OffDiagonal[i_int][5], X->Def.ParaInterAll_OffDiagonal[i_int], X, nstate, tmp_v0, tmp_v1);
322  }
323  else {
325  X->Def.InterAll_OffDiagonal[i_int][0], X->Def.InterAll_OffDiagonal[i_int][1],
326  X->Def.InterAll_OffDiagonal[i_int][3], X->Def.InterAll_OffDiagonal[i_int][4],
327  X->Def.InterAll_OffDiagonal[i_int][5], X->Def.InterAll_OffDiagonal[i_int][7],
328  X->Def.ParaInterAll_OffDiagonal[i_int], X, nstate, tmp_v0, tmp_v1);
329  }
330 
331 }/*void GC_child_general_int_spin_MPIsingle*/
338  long int i_int,
339  struct BindStruct *X,
340  int nstate, std::complex<double> **tmp_v0,
341  std::complex<double> **tmp_v1
342 ){
344  X->Def.InterAll_OffDiagonal[i_int][0], X->Def.InterAll_OffDiagonal[i_int][1],
345  X->Def.InterAll_OffDiagonal[i_int][3], X->Def.InterAll_OffDiagonal[i_int][4],
346  X->Def.InterAll_OffDiagonal[i_int][5], X->Def.InterAll_OffDiagonal[i_int][7],
347  X->Def.ParaInterAll_OffDiagonal[i_int], X, nstate, tmp_v0, tmp_v1);
348 
349 }/*void GC_child_general_int_spin_MPIdouble*/
356  long int i_int,
357  struct BindStruct *X,
358  int nstate, std::complex<double> **tmp_v0,
359  std::complex<double> **tmp_v1
360 ){
361 
363  X->Def.InterAll_OffDiagonal[i_int][0], X->Def.InterAll_OffDiagonal[i_int][1],
364  X->Def.InterAll_OffDiagonal[i_int][3], X->Def.InterAll_OffDiagonal[i_int][4],
365  X->Def.InterAll_OffDiagonal[i_int][5], X->Def.InterAll_OffDiagonal[i_int][7],
366  X->Def.ParaInterAll_OffDiagonal[i_int], X, nstate, tmp_v0, tmp_v1);
367 
368 }/*void GC_child_general_int_spin_MPIsingle*/
struct DefineList Def
Definision of system (Hamiltonian) etc.
Definition: struct.hpp:395
long int * list_2_1
Definition: global.cpp:27
void child_general_int_spin_MPIdouble(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Exchange term in Spin model When both site1 and site2 are in the inter process region.
long int * list_2_2
Definition: global.cpp:28
std::complex< double > ** v1buf
Definition: global.cpp:22
void X_child_general_int_spin_TotalS_MPIdouble(int org_isite1, int org_isite3, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Exchange term in Spin model When both site1 and site2 are in the inter process region.
void GC_child_general_int_spin_MPIdouble(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
General interaction term in the Spin model + GC When both site1 and site2 are in the inter process re...
struct LargeList Large
Variables for Matrix-Vector product.
Definition: struct.hpp:397
void X_GC_child_CisAitCjuAju_GeneralSpin_MPIsingle(int org_isite1, int org_ispin1, int org_ispin2, int org_isite3, int org_ispin3, std::complex< double > tmp_J, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Compute term in the grandcanonical general spin system when one of these site is in the inter proces...
void child_general_int_GeneralSpin_MPIsingle(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
General interaction term in the Spin model + GC When both site1 and site2 are in the inter process re...
int mode
multiply or expectation value.
Definition: struct.hpp:331
long int irght
Used for Ogata-Lin ???
Definition: struct.hpp:344
void GC_child_general_int_GeneralSpin_MPIsingle(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
General interaction term in the Spin model + GC When both site1 and site2 are in the inter process re...
void X_child_general_int_spin_MPIsingle(int org_isite1, int org_ispin1, int org_ispin2, int org_isite3, int org_ispin3, int org_ispin4, std::complex< double > tmp_J, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
int ** InterAll_OffDiagonal
[DefineList::NinterAll_OffDiagonal][8] Interacted quartet
Definition: struct.hpp:161
long int SendRecv_i(int origin, long int isend)
Wrapper of MPI_Sendrecv for long integer number.
Definition: wrapperMPI.cpp:504
void child_general_int_GeneralSpin_MPIdouble(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
General interaction term in the Spin model + GC When both site1 and site2 are in the inter process re...
void GC_child_CisAitCjuAju_spin_MPIdouble(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Wrapper for calculating CisAitCjuAju term in Spin model + GC When both site1 and site2 are in the int...
void GC_child_CisAitCiuAiv_spin_MPIsingle(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Exchange and Pairlifting term in Spin model + GC When only site2 is in the inter process region...
long int * list_1buf
Definition: global.cpp:26
long int ilft
Used for Ogata-Lin ???
Definition: struct.hpp:345
Bind.
Definition: struct.hpp:394
void GC_child_CisAisCjuAjv_spin_MPIsingle(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Wrapper for CisAisCjuAjv term in Spin model + GC When only site2 is in the inter process region...
void GC_child_general_int_GeneralSpin_MPIdouble(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
General interaction term in the Spin model + GC When both site1 and site2 are in the inter process re...
int GetOffComp(long int *_list_2_1, long int *_list_2_2, long int _ibit, const long int _irght, const long int _ilft, const long int _ihfbit, long int *_ioffComp)
function of getting off-diagonal component
Definition: bitcalc.cpp:195
long int ihfbit
Used for Ogata-Lin ???
Definition: struct.hpp:346
void X_GC_child_CisAitCjuAju_GeneralSpin_MPIdouble(int org_isite1, int org_ispin1, int org_ispin2, int org_isite3, int org_ispin3, std::complex< double > tmp_J, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
term in Spin model. When both site1 and site3 are in the inter process region.
int myrank
Process ID, defined in InitializeMPI()
Definition: global.cpp:73
void SendRecv_cv(int origin, long int nMsgS, long int nMsgR, std::complex< double > *vecs, std::complex< double > *vecr)
Wrapper of MPI_Sendrecv for std::complex<double> number. When we pass a message longer than 2^31-1 (m...
Definition: wrapperMPI.cpp:424
void GC_child_CisAitCiuAiv_spin_MPIdouble(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Exchange and Pairlifting term in Spin model + GC When both site1 and site2 are in the inter process r...
void X_GC_child_CisAitCjuAjv_GeneralSpin_MPIdouble(int org_isite1, int org_ispin1, int org_ispin2, int org_isite3, int org_ispin3, int org_ispin4, std::complex< double > tmp_J, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Compute term in the grandcanonical general spin system when both site is in the inter process region...
void GC_child_CisAitCjuAju_spin_MPIsingle(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Wrapper for CisAisCjuAjv term in Spin model + GC When only site2 is in the inter process region...
std::complex< double > * ParaInterAll_OffDiagonal
[DefineList::NInterAll_OffDiagonal] Coupling constant of off-diagonal inter-all term. malloc in setmem_def().
Definition: struct.hpp:170
void X_GC_child_CisAitCjuAjv_GeneralSpin_MPIsingle(int org_isite1, int org_ispin1, int org_ispin2, int org_isite3, int org_ispin3, int org_ispin4, std::complex< double > tmp_J, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Compute term in the grandcanonical general spin system when one of these site is in the inter proces...
long int * Tpow
[2 * DefineList::NsiteMPI] malloc in setmem_def().
Definition: struct.hpp:90
void X_GC_child_CisAisCjuAjv_GeneralSpin_MPIsingle(int org_isite1, int org_ispin1, int org_isite3, int org_ispin3, int org_ispin4, std::complex< double > tmp_J, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Compute term in the grandcanonical general spin system when one of these site is in the inter proces...
void child_general_int_spin_MPIsingle(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Exchange term in Spin model When only site2 is in the inter process region.
void SendRecv_iv(int origin, long int nMsgS, long int nMsgR, long int *vecs, long int *vecr)
Wrapper of MPI_Sendrecv for long integer number. When we pass a message longer than 2^31-1 (max of in...
Definition: wrapperMPI.cpp:465
void X_child_CisAitCjuAjv_GeneralSpin_MPIdouble(int org_isite1, int org_ispin1, int org_ispin2, int org_isite3, int org_ispin3, int org_ispin4, std::complex< double > tmp_J, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Compute term in the canonical general spin system when both sites are in the inter process region...
void GC_child_general_int_spin_MPIsingle(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
General interaction term in the Spin model + GC When both site1 and site2 are in the inter process re...
void GC_child_CisAisCjuAjv_spin_MPIdouble(long int i_int, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Wrapper for calculating CisAisCjuAjv term in Spin model + GC When both site1 and site2 are in the int...
void X_child_CisAitCjuAjv_GeneralSpin_MPIsingle(int org_isite1, int org_ispin1, int org_ispin2, int org_isite3, int org_ispin3, int org_ispin4, std::complex< double > tmp_J, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Compute term in the canonical general spin system when one of these sites is in the inter process re...
void X_child_general_int_spin_MPIdouble(int org_isite1, int org_ispin1, int org_ispin2, int org_isite3, int org_ispin3, int org_ispin4, std::complex< double > tmp_J, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
Exchange term in Spin model When both site1 and site2 are in the inter process region.
void X_GC_child_CisAisCjuAjv_GeneralSpin_MPIdouble(int org_isite1, int org_ispin1, int org_isite3, int org_ispin3, int org_ispin4, std::complex< double > tmp_J, struct BindStruct *X, int nstate, std::complex< double > **tmp_v0, std::complex< double > **tmp_v1)
term in Spin model. When both site1 and site3 are in the inter process region.
struct CheckList Check
Size of the Hilbert space.
Definition: struct.hpp:396
long int * list_1
Definition: global.cpp:25
long int idim_max
The dimension of the Hilbert space of this process.
Definition: struct.hpp:305