-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtransfer_matrix.hpp
79 lines (58 loc) · 1.92 KB
/
transfer_matrix.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
#ifndef _TRANSFER_MATRIX_
#define _TRANSFER_MATRIX_
#include <string>
#include <vector>
#include <Eigen/Dense>
#include "transfer_matrix_functions.hpp"
class TransferMatrix
{
public:
TransferMatrix();
TransferMatrix(Potential &p_, std::string label_);
virtual double function(double ea_, double eb_) const = 0;
std::string Label() const;
void ComputeEigensystem();
int OrderEigenSystemMax();
std::vector<std::pair<double,std::vector<double> > > GetEigenSystemMax();
~TransferMatrix();
protected:
void GenerateMatrix();
const Nucleation m_parameters;
const TransferMatrixFunctions *m_tm_functions;
const int m_m = m_parameters.m;
const int m_dimension = m_parameters.dimension;
const double m_delta = m_parameters.delta;
const std::string m_matrix_label;
const std::string m_matrix_filename = m_parameters.log_dir + "/" + m_matrix_label + "_matrix.data";
const std::string m_eval_filename = m_parameters.log_dir + "/" + m_matrix_label + "_eval.data";
const std::string m_evec_filename = m_parameters.log_dir + "/" + m_matrix_label + "_evec.data";
Eigen::MatrixXd m_transfer_matrix;
Eigen::MatrixXd m_evec;
Eigen::VectorXd m_eval;
std::vector<std::pair<double, std::vector<double> > > m_Eigen;
};
class T : public TransferMatrix
{
public:
T();
T(Potential &p_);
double function(double ea_, double eb_) const;
~T();
};
class T00 : public TransferMatrix
{
public:
T00();
T00(Potential &p_);
double function(double ea_, double eb_) const;
~T00();
};
class T11 : public TransferMatrix
{
public:
T11();
T11(Potential &p_);
double function(double ea_, double eb_) const;
~T11();
};
#endif