MADNESS 0.10.1
|
Spectral propagtor in time. Refer to documentation of file spectralprop.h for math detail. More...
#include <spectralprop.h>
Public Member Functions | |
SpectralPropagator (int NPT) | |
Construct propagator using NPT points. | |
~SpectralPropagator () | |
template<typename uT , typename expLT , typename NT > | |
uT | step (double t, double Delta, const uT &u0, const expLT &expL, const NT &N, const double eps=1e-12, bool doprint=false, bool recurinit=true) |
Step forward in time from ![]() ![]() | |
Private Member Functions | |
double | p (int i, double t) |
Private: Makes interpolating polyn p[i](t), i=0..NPT. | |
template<typename uT , typename expLT , typename NT > | |
std::vector< uT > | solve (double t, double Delta, const uT &u0, const expLT &expL, const NT &N, const double eps, bool doprint, bool recurinit, int &napp) |
template<typename uT > | |
uT | u (double dt, const std::vector< uT > &v) |
Private: Computes interpolated solution. | |
Private Attributes | |
const int | NPT |
Number of quadrature points. | |
SpectralPropagator * | q |
std::vector< double > | w |
Quadrature weights on [0,1] with value 0 prepended. | |
std::vector< double > | x |
Quadrature points on [0,1] with value 0 prepended. | |
Spectral propagtor in time. Refer to documentation of file spectralprop.h for math detail.
|
inline |
Construct propagator using NPT
points.
References madness::gauss_legendre(), MADNESS_ASSERT, NPT, q, w, and x.
|
inline |
References q.
Private: Makes interpolating polyn p[i](t), i=0..NPT.
References madness::nonlinear_vector_solver(), NPT, and x.
Referenced by u().
|
inlineprivate |
References madness::distance(), expL(), k, N, madness::nonlinear_vector_solver(), NPT, madness::print(), q, solve(), u(), v, w, and x.
|
inline |
Step forward in time from
The template types should be automatically inferred from the invocation. uT
is the C++ type for the solution.
[in] | t | The current time |
[in] | Delta | The time step |
[in] | u0 | The solution at the current time |
[in] | expL | A function or functor to compute ![]() ![]() |
[in] | N | A function to compute the non-linear part |
[in] | eps | Threshold for convergence of iteration on norm of change in solution at last quadrature point. |
[in] | doprint | If true will print some info on convergence |
[in] | recurinit | If true initial guess is recursion from lower order quadrature instead of default explicit rule |
The user provided operators are invoked as
where
where
References expL(), k, N, madness::nonlinear_vector_solver(), NPT, madness::print(), solve(), u(), v, w, and x.
|
private |
Number of quadrature points.
Referenced by SpectralPropagator(), p(), solve(), step(), and u().
|
private |
Referenced by SpectralPropagator(), ~SpectralPropagator(), and solve().
|
private |
Quadrature weights on [0,1] with value 0 prepended.
Referenced by SpectralPropagator(), solve(), and step().
|
private |
Quadrature points on [0,1] with value 0 prepended.
Referenced by SpectralPropagator(), p(), solve(), and step().