-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathFSSH.h
More file actions
47 lines (38 loc) · 1.1 KB
/
FSSH.h
File metadata and controls
47 lines (38 loc) · 1.1 KB
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
#ifndef __FEWEST_SWITCHES_SURFACE_HOPPING_H__
#define __FEWEST_SWITCHES_SURFACE_HOPPING_H__
#include "TwoPara.h"
#include "DecayRate.h"
struct FSSH
{
FSSH( TwoPara* model_,
double const& mass_,
double const& dt_,
arma::uword const& nt_,
DecayRate const& Gamma_,
double const& beta_ );
void initialize(bool const& state0_, double const& x0_, double const& v0_, double const& rho00_, std::complex<double> const& rho01_);
void propagate();
// three tasks in one progagation step
void rk4_onestep();
void hop();
void collect();
// first-order differential equation
arma::vec dvar_dt(arma::vec const& var_);
TwoPara* model;
DecayRate Gamma; // parameter in the additional damping term
double beta; // parameter in the additional damping term
double mass;
double dt;
arma::uword nt;
bool state;
arma::vec var; // x, v, rho_00, Re(rho_01), Im(rho_01)
arma::uword counter;
// data storage for one trajectory
arma::vec x_t;
arma::vec v_t;
arma::vec rho00_t;
arma::vec Re_rho01_t;
arma::vec Im_rho01_t;
arma::uvec state_t;
};
#endif