pyoomph.utils.lyapunov module
- class pyoomph.utils.lyapunov.LyapunovExponentCalculator(average_time=None, N=1, filename='lyapunov.txt', relative_to_output=True, store_as_eigenvectors=False)[source]
Bases:
GenericProblemHooksA class for calculating Lyapunov exponents. Add it to the problem by
problem+=LyapunovExponentCalculator(...)and it will do the rest for you. However, note that we only may have first order time derivatives in the equations. Second order time derivatives must be rewritten as first order time derivatives before. Also, the time derivatives in the system must use the fully implicit “BDF2” time scheme, which is the default (unless set otherwise stated by either usingscheme="..."inpartial_t()or by alteringdefault_timestepping_schemeof theProblem).- Parameters:
average_time (
Union[Expression,int,float,None]) – The time interval over which to average the Lyapunov exponents. If None, we average over the entire timeN (
int) – The number of Lyapunov exponents to calculate. N>=2 will invoke Gram-Schmidt on the perturbation vectors. Defaults to 1.filename (
str) – The name of the output file. Defaults to “lyapunov.txt”.relative_to_output (
bool) – Whether to save the output file relative to the problem’s output directory. Defaults to True.store_as_eigenvectors (
bool) – Whether to store the perturbation vectors as eigenvectors. Defaults to False.