TBTK
Need a break? Support the development by playing Polarity Puzzles
LindhardSusceptibility.h
1 /* Copyright 2018 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 
17 
25 #ifndef COM_DAFER45_TBTK_PROPERTY_EXTRACTOR_LINDHARD_SUSCEPTIBILITY
26 #define COM_DAFER45_TBTK_PROPERTY_EXTRACTOR_LINDHARD_SUSCEPTIBILITY
27 
28 #include "TBTK/Solver/LindhardSusceptibility.h"
29 #include "TBTK/Property/Susceptibility.h"
31 
32 #include <complex>
33 
34 namespace TBTK{
35 namespace PropertyExtractor{
36 
39 class LindhardSusceptibility : public PropertyExtractor{
40 public:
44  LindhardSusceptibility(Solver::LindhardSusceptibility &solver);
45 
47  virtual Property::Susceptibility calculateSusceptibility(
48  std::vector<Index> patterns
49  );
50 private:
52  static void calculateSusceptibilityCallback(
53  PropertyExtractor *cb_this,
54  Property::Property &property,
55  const Index &index,
56  int offset,
57  Information &information
58  );
59 
61  Solver::LindhardSusceptibility *solver;
62 
64  virtual const Solver::Solver& getSolver() const;
65 
67  std::vector<std::complex<double>> energies;
68 };
69 
70 inline const Solver::Solver& LindhardSusceptibility::getSolver() const{
71  return *solver;
72 }
73 
74 }; //End of namespace PropertyExtractor
75 }; //End of namespace TBTK
76 
77 #endif
78 
PropertyExtractor.h
Generates IndexTrees to be used as loop ranges and memory layout for Properties in the PropertyExtrac...