TBTK
FockStateMap.h
Go to the documentation of this file.
1 /* Copyright 2017 Kristofer Bj√∂rnson
2  *
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
23 #ifndef COM_DAFER45_TBTK_FOCK_STATE_MAP
24 #define COM_DAFER45_TBTK_FOCK_STATE_MAP
25 
26 #include "TBTK/FockState.h"
27 
28 namespace TBTK{
29 namespace FockStateMap{
30 
31 template<typename BIT_REGISTER>
33 public:
35  FockStateMap(unsigned int exponentialDimension);
36 
38  virtual ~FockStateMap();
39 
41  virtual unsigned int getBasisSize() const = 0;
42 
44  virtual unsigned int getBasisIndex(
45  const FockState<BIT_REGISTER> &fockState
46  ) const = 0;
47 
50  unsigned int index
51  ) const = 0;
52 
54  unsigned int getExponentialDimension() const;
55 private:
56  unsigned int exponentialDimension;
57 };
58 
59 template<typename BIT_REGISTER>
60 FockStateMap<BIT_REGISTER>::FockStateMap(unsigned int exponentialDimension){
61  this->exponentialDimension = exponentialDimension;
62 }
63 
64 template<typename BIT_REGISTER>
66 }
67 
68 template<typename BIT_REGISTER>
70  return exponentialDimension;
71 }
72 
73 }; //End of namespace FockStateMap
74 }; //End of namespace TBTK
75 
76 #endif
virtual FockState< BIT_REGISTER > getFockState(unsigned int index) const =0
virtual unsigned int getBasisIndex(const FockState< BIT_REGISTER > &fockState) const =0
Definition: FockStateMap.h:32
virtual ~FockStateMap()
Definition: FockStateMap.h:65
unsigned int getExponentialDimension() const
Definition: FockStateMap.h:69
FockState.
Definition: ModelFactory.h:35
Definition: FockState.h:37
FockStateMap(unsigned int exponentialDimension)
Definition: FockStateMap.h:60
virtual unsigned int getBasisSize() const =0