forked from LyapXool/V3
-
Notifications
You must be signed in to change notification settings - Fork 0
/
lyapunovfunction.hpp
96 lines (74 loc) · 3.56 KB
/
lyapunovfunction.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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
/* LyapXool – V3: Quadratic optimisations, is a program to compute Complete Lyapunov functions for dynamical systems described by non linear autonomous ordinary differential equations.
-> This is a free software; you can redistribute it and/or
-> modify it under the terms of the GNU General Public License
-> as published by the Free Software Foundation; either version 3
-> of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
-> but WITHOUT ANY WARRANTY; without even the implied warranty of
-> MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-> GNU General Public License for more details.
You should have received a copy of the GNU General Public License
-> along with this program. If not, see <http://www.gnu.org/licenses/>.
Author and main maintainer: Carlos Argáez
-> Bibliography attached to the corresponding publication.
*/
#ifndef lyapunovfunction_hpp
#define lyapunovfunction_hpp
#include <stdio.h>
#include <armadillo>
#include <list>
#include "instructions.hpp"
#include "RBF.hpp"
class LYAPUNOV{
public:
LYAPUNOV(int totaliterations, int ode_dimension, double cart_grid_density, int l, int k, double c, int points_directional, double critval, bool normal, bool printing, std::ofstream &outputf);
void lyapequation(int currentiteration, RBFMETHOD &rbf);
void lyapunovfunctions(int currentiteration, bool type_of_grid, arma::mat &evalcoordinates, WENDLAND &wendland, RBFMETHOD &rbf);
void lyapunovfunctions(int currentiteration, arma::mat &evalcoordinates, WENDLAND &wendland, RBFMETHOD &rbf);
void firstderivative(int currentiteration, bool type_of_grid, arma::mat &evalcoordinates, WENDLAND &wendland, RBFMETHOD &rbf);
void secondderivative(arma::mat &evalcoordinates, WENDLAND &wendland, RBFMETHOD &rbf);
void findingeigenamount(int currentiteration, bool type_of_grid, RBFMETHOD &rbf);
void chainrecurrentset(int currentiteration, bool type_of_grid, bool with_orbder, arma::mat &evalcoordinates);
void getnewalpha(int currentiteration, RBFMETHOD &rbf);
void make_lyap_direcional(WENDLAND &wendland, RBFMETHOD &rbf);
void make_lyap_direc_and_cart(WENDLAND &wendland, RBFMETHOD &rbf);
void make_chainrecurrent_eigenvalues(WENDLAND &wendland, RBFMETHOD &rbf);
void make_norm_chain_recurrent_sets(WENDLAND &wendland, RBFMETHOD &rbf);
void make_lyap_cartesian(WENDLAND &wendland, RBFMETHOD &rbf);
void make_check_num_approximation(WENDLAND &wendland, RBFMETHOD &rbf);
void quadraticoptimization(RBFMETHOD &rbf);
void quadratic_fixedpoint(RBFMETHOD &rbf);
int totaliterations;
int currentiteration;
int ode_dimension;
int l;
int k;
double c;
int points_directional;
double critval;
double cart_grid_density;
bool type_of_grid;
bool normal;
bool printing;
double checking;
std::ofstream* outputf;
arma::rowvec lyapfunc;
arma::rowvec orbder;
arma::vec betaod;
arma::mat fdvector;
arma::cube sdvector;
arma::rowvec normed;
arma::mat TOTALEIGEN;
arma::cube TOTALEIGENV;
std::vector<bool> booldirectgrid;
std::list<int> counter;
std::list<int> counterncol;
arma::mat failinggrid;
arma::mat failinglyapunov;
arma::mat failingorbder;
arma::mat direcnozero;
arma::mat negcollocation;
arma::vec crslyapun;
arma::vec crsorbder;
};
#endif /* lyapunovfunction_hpp */