You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Particle_Hole_Excitation_Cost.cc 1.6KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. /**********************************************************
  2. This software is part of J.-S. Caux's ABACUS library.
  3. Copyright (c) J.-S. Caux.
  4. -----------------------------------------------------------
  5. File: src/SCAN/Particle_Hole_Excitation_Cost.cc
  6. Purpose: defines the expected cost of adding a p-h pair. Used in General_Scan.
  7. ***********************************************************/
  8. #include "ABACUS.h"
  9. using namespace std;
  10. using namespace ABACUS;
  11. namespace ABACUS {
  12. DP Particle_Hole_Excitation_Cost (char whichDSF, LiebLin_Bethe_State& AveragingState)
  13. {
  14. // Estimates the cost of adding a particle-hole excitation to an intermediate state
  15. DP ph_cost = 1.0;
  16. if (whichDSF == 'd') ph_cost = ABACUS::min(0.01, 0.1/AveragingState.c_int);
  17. else if (whichDSF == 'o') ph_cost = 0.01;
  18. else if (whichDSF == 'g') ph_cost = 0.01;
  19. else if (whichDSF == 'Z') ph_cost = 1.0;
  20. else if (whichDSF == 'B') ph_cost = 0.1;
  21. else if (whichDSF == 'C') ph_cost = 0.1;
  22. else ABACUSerror("whichDSF option not implemented in Particle_Hole_Excitation_Cost for LiebLin.");
  23. return(ph_cost);
  24. }
  25. DP Particle_Hole_Excitation_Cost (char whichDSF, Heis_Bethe_State& AveragingState)
  26. {
  27. // Estimates the cost of adding a particle-hole excitation to an intermediate state
  28. DP ph_cost = 1.0;
  29. if (whichDSF == 'z') ph_cost = 0.01;
  30. else if (whichDSF == 'm') ph_cost = 0.01;
  31. else if (whichDSF == 'p') ph_cost = 0.01;
  32. else if (whichDSF == 'Z') ph_cost = 1.0;
  33. else ABACUSerror("whichDSF option not implemented in Particle_Hole_Excitation_Cost for HEIS.");
  34. return(ph_cost);
  35. }
  36. } // namespace ABACUS