QMCPACK
Configuration.h
Go to the documentation of this file.
1 //////////////////////////////////////////////////////////////////////////////////////
2 // This file is distributed under the University of Illinois/NCSA Open Source License.
3 // See LICENSE file in top directory for details.
4 //
5 // Copyright (c) 2016 Jeongnim Kim and QMCPACK developers.
6 //
7 // File developed by: Ken Esler, kpesler@gmail.com, University of Illinois at Urbana-Champaign
8 // Jeongnim Kim, jeongnim.kim@gmail.com, University of Illinois at Urbana-Champaign
9 // Jeremy McMinnis, jmcminis@gmail.com, University of Illinois at Urbana-Champaign
10 //
11 // File created by: Jeongnim Kim, jeongnim.kim@gmail.com, University of Illinois at Urbana-Champaign
12 //////////////////////////////////////////////////////////////////////////////////////
13 
14 
15 #ifndef QMCPLUSPLUS_TRAITS_H
16 #define QMCPLUSPLUS_TRAITS_H
17 
18 #include <config.h>
19 #include <string>
20 #include <vector>
21 #include <map>
22 #include "type_traits/QMCTypes.h"
28 #include "Message/Communicate.h"
29 
30 //define empty DEBUG_MEMORY
31 #define DEBUG_MEMORY(msg)
32 //uncomment this out to trace the call tree of destructors
33 //#define DEBUG_MEMORY(msg) std::cerr << "<<<< " << msg << std::endl;
34 
35 #if defined(DEBUG_PSIBUFFER_ON)
36 #define DEBUG_PSIBUFFER(who, msg) \
37  std::cerr << "PSIBUFFER " << who << " " << msg << std::endl; \
38  std::cerr.flush();
39 #else
40 #define DEBUG_PSIBUFFER(who, msg)
41 #endif
42 
43 namespace qmcplusplus
44 {
45 /** traits for QMC variables
46  *
47  *typedefs for the QMC data types
48  */
49 struct QMCTraits
50 {
51  enum
52  {
54  DIM_VGL = OHMMS_DIM + 2 // Value(1) + Gradients(OHMMS_DIM) + Laplacian(1)
55  };
64  ///define other types
68  ///define PropertyList_t
70 
71  // Type for particle group index pairs
72  using PtclGrpIndexes = std::vector<std::pair<int, int>>;
73 };
74 
75 /** Particle traits to use UniformGridLayout for the ParticleLayout.
76  */
78 {
81 
82  using Index_t = int;
85 
89 
94 
98 };
99 
100 
101 // For unit tests
102 // Check if we are compiling with Catch defined. Could use other symbols if needed.
103 #ifdef TEST_CASE
104 #ifdef QMC_COMPLEX
105 using ValueApprox = Catch::Detail::ComplexApprox;
106 #else
107 using ValueApprox = Catch::Detail::Approx;
108 #endif
109 #endif
110 
111 } // namespace qmcplusplus
112 
113 #endif
TinyVector< T, D > SingleParticlePos
the type of a D-dimensional position vector
a class that defines a supercell in D-dimensional Euclean space.
std::vector< std::pair< int, int > > PtclGrpIndexes
Definition: Configuration.h:72
helper functions for EinsplineSetBuilder
Definition: Configuration.h:43
QTBase::RealType RealType
Definition: Configuration.h:58
Declaration of OutputManager class.
RealType ValueType
Definition: QMCTypes.h:42
QTBase::ComplexType ComplexType
Definition: Configuration.h:59
Vectorized record engine for scalar properties.
Attaches a unit to a Vector for IO.
Declaration of CrystalLattice<T,D>
QTFull::ValueType SingleParticleValue
Definition: Configuration.h:97
#define OHMMS_DIM
Definition: config.h:64
Declaration of OhmmsElementBase and define xml-related macros.
QTFull::ComplexType Complex_t
Definition: Configuration.h:84
QTFull::ValueType FullPrecValueType
Definition: Configuration.h:67
QTBase::ValueType ValueType
Definition: Configuration.h:60
TinyVector< ValueType, DIM > GradType
Definition: QMCTypes.h:44
#define OHMMS_INDEXTYPE
Definition: config.h:67
OHMMS_INDEXTYPE IndexType
define other types
Definition: Configuration.h:65
std::complex< Precision > ComplexType
Definition: QMCTypes.h:38
TinyVector< RealType, DIM > PosType
Definition: QMCTypes.h:45
Declaraton of ParticleAttrib<T> derived from Vector.
Particle traits to use UniformGridLayout for the ParticleLayout.
Definition: Configuration.h:77
QMCTypes< OHMMS_PRECISION_FULL, DIM > QTFull
Definition: Configuration.h:57
Precision RealType
Definition: QMCTypes.h:37
Tensor< RealType, DIM > TensorType
Definition: QMCTypes.h:46
QTFull::RealType FullPrecRealType
Definition: Configuration.h:66
traits for QMC variables
Definition: Configuration.h:49
Tensor< T, D > Tensor_t
the type of a D-dimensional Tensor
TinyVector< int, D > SingleParticleIndex
the type of a D-dimensional index vector