SOLIDstate
A C++ library for solid state physics
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Pages
Public Member Functions | Static Public Attributes | List of all members
solid::RK4< T1, T2, T3 > Class Template Reference

Runge–Kutta forth order method (RK4) for solving differentional equations. More...

#include <RungeKutta4.hpp>

Inheritance diagram for solid::RK4< T1, T2, T3 >:
Inheritance graph
[legend]
Collaboration diagram for solid::RK4< T1, T2, T3 >:
Collaboration graph
[legend]

Public Member Functions

std::string getLabel () override
 Get the Label object (IQuantumDynamicSolver override) More...
 
void Propagate (double time, double dtime, QuantumDynamics< T1, T2, T3 > &qDynamics)
 Propagate the state \(|\psi\rangle\) (IQuantumDynamicSolver override) More...
 
- Public Member Functions inherited from solid::IQuantumDynamicSolver< T1, T2, T3 >
virtual ~IQuantumDynamicSolver ()
 

Static Public Attributes

static constexpr auto label = "rk4"
 label, default = "rk4" More...
 

Detailed Description

template<template< typename > class T1, typename T2, typename T3>
class solid::RK4< T1, T2, T3 >

Runge–Kutta forth order method (RK4) for solving differentional equations.

Propagation of the state is obtained in the following way:

\[ |\psi(t+\Delta t)\rangle = |\psi(t)\rangle + \frac16(|k_1\rangle+2|k_2\rangle+2|k_3\rangle+|k_4\rangle), \]

where corresponding states \(|k_1\rangle,\,|k_2\rangle,\,|k_3\rangle,\,|k_4\rangle\) are given by:

Member Function Documentation

template<template< typename > class T1, typename T2, typename T3>
std::string solid::RK4< T1, T2, T3 >::getLabel ( )
inlineoverridevirtual

Get the Label object (IQuantumDynamicSolver override)

Returns
std::string label

Implements solid::IQuantumDynamicSolver< T1, T2, T3 >.

template<template< typename > class T1, typename T2, typename T3>
void solid::RK4< T1, T2, T3 >::Propagate ( double  time,
double  dtime,
QuantumDynamics< T1, T2, T3 > &  qDynamics 
)
inlinevirtual

Propagate the state \(|\psi\rangle\) (IQuantumDynamicSolver override)

Parameters
timecurrent time
dtimetime step
qDynamicsQuantumDynamics<T1,T2,T3> object

Implements solid::IQuantumDynamicSolver< T1, T2, T3 >.

Member Data Documentation

template<template< typename > class T1, typename T2, typename T3>
constexpr auto solid::RK4< T1, T2, T3 >::label = "rk4"
inlinestatic

label, default = "rk4"


The documentation for this class was generated from the following file: