TBTK
Need a break? Support the development by playing Polarity Puzzles
ChebyshevExpander.h
Go to the documentation of this file.
1 /* Copyright 2016 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_C_PROPERTY_EXTRACTOR
24 #define COM_DAFER45_TBTK_C_PROPERTY_EXTRACTOR
25 
27 #include "TBTK/Property/Density.h"
29 #include "TBTK/Property/LDOS.h"
33 
34 //#include <initializer_list>
35 #include <iostream>
36 
37 namespace TBTK{
38 namespace PropertyExtractor{
39 
52 public:
55 
57  virtual ~ChebyshevExpander();
58 
60  virtual void setEnergyWindow(
61  double lowerBound,
62  double upperBound,
63  int energyResolution
64  );
65 
68  Index to,
69  Index from,
70  Property::GreensFunction::Type type = Property::GreensFunction::Type::Retarded
71  );
72 
75  std::vector<std::vector<Index>> patterns,
76  Property::GreensFunction::Type type = Property::GreensFunction::Type::Retarded
77  );
78 
81  std::vector<Index> &to,
82  Index from,
83  Property::GreensFunction::Type type = Property::GreensFunction::Type::Retarded
84  );
85 
87  virtual std::complex<double> calculateExpectationValue(
88  Index to,
89  Index from
90  );
91 
94  Index pattern,
95  Index ranges
96  );
97 
100  std::vector<Index> patterns
101  );
102 
105  Index pattern,
106  Index ranges
107  );
108 
111  std::vector<Index> patterns
112  );
113 
115  virtual Property::LDOS calculateLDOS(Index pattern, Index ranges);
116 
119  std::vector<Index> patterns
120  );
121 
124  Index pattern,
125  Index ranges
126  );
127 
130  std::vector<Index> patterns
131  );
132 private:
134  Solver::ChebyshevExpander *cSolver;
135 
137  virtual const Solver::Solver& getSolver() const;
138 
141  static void calculateDensityCallback(
142  PropertyExtractor *cb_this,
143  Property::Property &property,
144  const Index &index,
145  int offset,
146  Information &information
147  );
148 
151  static void calculateMAGCallback(
152  PropertyExtractor *cb_this,
153  Property::Property &property,
154  const Index &index,
155  int offset,
156  Information &information
157  );
158 
161  static void calculateLDOSCallback(
162  PropertyExtractor *cb_this,
163  Property::Property &property,
164  const Index &index,
165  int offset,
166  Information &information
167  );
168 
171  static void calculateSP_LDOSCallback(
172  PropertyExtractor *cb_this,
173  Property::Property &property,
174  const Index &index,
175  int offset,
176  Information &information
177  );
178 };
179 
180 inline const Solver::Solver& ChebyshevExpander::getSolver() const{
181  return *cSolver;
182 }
183 
184 }; //End of namespace PropertyExtractor
185 }; //End of namespace TBTK
186 
187 #endif
TBTK::PropertyExtractor::ChebyshevExpander::calculateDensity
virtual Property::Density calculateDensity(Index pattern, Index ranges)
TBTK::PropertyExtractor::PropertyExtractor::Information
Definition: PropertyExtractor.h:424
TBTK::PropertyExtractor::ChebyshevExpander::calculateMagnetization
virtual Property::Magnetization calculateMagnetization(Index pattern, Index ranges)
TBTK::PropertyExtractor::ChebyshevExpander::calculateGreensFunctions
Property::GreensFunction calculateGreensFunctions(std::vector< Index > &to, Index from, Property::GreensFunction::Type type=Property::GreensFunction::Type::Retarded)
TBTK::Property::SpinPolarizedLDOS
Property container for spin-polarized local density of states (spin-polarized LDOS).
Definition: SpinPolarizedLDOS.h:46
TBTK::PropertyExtractor::ChebyshevExpander::~ChebyshevExpander
virtual ~ChebyshevExpander()
TBTK::PropertyExtractor::ChebyshevExpander::calculateLDOS
virtual Property::LDOS calculateLDOS(Index pattern, Index ranges)
TBTK::Property::LDOS
Property container for the local density of states (LDOS).
Definition: LDOS.h:48
TBTK::PropertyExtractor::ChebyshevExpander::setEnergyWindow
virtual void setEnergyWindow(double lowerBound, double upperBound, int energyResolution)
TBTK::PropertyExtractor::ChebyshevExpander::calculateGreensFunction
Property::GreensFunction calculateGreensFunction(Index to, Index from, Property::GreensFunction::Type type=Property::GreensFunction::Type::Retarded)
TBTK::Property::GreensFunction::Type
Type
Definition: GreensFunction.h:47
PropertyExtractor.h
Generates IndexTrees to be used as loop ranges and memory layout for Properties in the PropertyExtrac...
ChebyshevExpander.h
Solves a Model using the Chebyshev method.
TBTK::PropertyExtractor::ChebyshevExpander::calculateSpinPolarizedLDOS
virtual Property::SpinPolarizedLDOS calculateSpinPolarizedLDOS(Index pattern, Index ranges)
LDOS.h
Property container for local density of states (LDOS).
SpinPolarizedLDOS.h
Property container for spin-polarized local density of states (spin-polarized LDOS).
TBTK::PropertyExtractor::ChebyshevExpander::calculateExpectationValue
virtual std::complex< double > calculateExpectationValue(Index to, Index from)
TBTK::Property::Density
Property container for density.
Definition: Density.h:43
TBTK::PropertyExtractor::ChebyshevExpander
Extracts physical properties from Solver::ChebyshevExpander.
Definition: ChebyshevExpander.h:51
TBTK::Property::GreensFunction
Property container for the Green's function.
Definition: GreensFunction.h:44
Magnetization.h
Property container for magnetization.
GreensFunction.h
Property container for the Green's function.
TBTK::Property::Property
Abstract Property class.
Definition: Property.h:36
TBTK::Solver::ChebyshevExpander
Solves a Model using the Chebyshev method.
Definition: ChebyshevExpander.h:69
Density.h
Property container for density.
TBTK::PropertyExtractor::PropertyExtractor
Base class for PropertyExtractors.
Definition: PropertyExtractor.h:64
TBTK::PropertyExtractor::ChebyshevExpander::ChebyshevExpander
ChebyshevExpander(Solver::ChebyshevExpander &cSolver)
TBTK::Solver::Solver
Base class for Solvers.
Definition: Solver.h:42
TBTK::Index
Physical index.
Definition: Index.h:44
TBTK::Property::Magnetization
Property container for magnetization.
Definition: Magnetization.h:44