#include <rdRKF.h>
Inheritance diagram for rdRKF:

Public Member Functions | |
| rdRKF (rdModel *aModel, double aTol=1.0e-4, double aTolFine=-1.0) | |
| Default constructor. | |
| virtual | ~rdRKF () |
| Destructor. | |
| rdModel * | getModel () |
| Get the model. | |
| int | getNY () |
| Get the number of states being integrated. | |
| void | setTolerance (double aTol, double aTolFine=-1.0) |
| Set the tolerances of the integrator. | |
| double | getTolerance () |
| Get the tolerance of the integrator. | |
| void | setFineTolerance (double aFineTol) |
| Set the fine tolerance of the integrator. | |
| double | getFineTolerance () |
| Get the fine tolerance of the integrator. | |
| int | step (double dt, double t, rdControlSet &x, double *y) |
| Step forward in time by dt. | |
| int | step (double dt, double t, double *x, double *y) |
| Step forward in time by dt. | |
| int | stepFixed (double dt, double t, rdControlSet &x, double *y) |
| Step forward in time by dt. | |
| int | stepFixed (double dt, double t, double *x, double *y) |
| Step forward in time by dt. | |
Protected Attributes | |
| double | _tol |
| Integration tolerance. | |
| double | _tolFine |
| Integration fine tolerance. | |
| rdModel * | _model |
| Dynamic model. | |
| int | _nx |
| Number of controls. | |
| double * | _x |
| Controls at time t. | |
| int | _ny |
| Number of states. | |
| double * | _yv |
| Work arrays for computing the new states. | |
| double * | _ye |
| Work arrays for computing the new states. | |
| double * | _dy |
| Work arrays for computing the new states. | |
| double * | _k1 |
| double * | _k2 |
| double * | _k3 |
| double * | _k4 |
| double * | _k5 |
| double * | _k6 |
Private Member Functions | |
| int | allocateMemory () |
| Allocate the memory needed to perform the integration. | |
| int | freeMemory () |
| Free the memory needed to perform the integration. | |
The integration method is based on a Runge-Kutta-Feldberg 5-6 Variable-Step Integrator adapted from one given by Atkinson, L.V., et al, "Numerical Methods with Fortran 77.", pp. 310-322, Addison-Wesley Publishing Company, 1989.
The user must supply a pointer to an rdModel on construction.
|
|
Get the fine tolerance of the integrator. The fine tollerance specifies the accuracy tolerance of an integration. If the accuracy is better than aTolFine, the integration step size is doubled. |
|
|
Get the tolerance of the integrator. The tolerance specifies the allowd error of an integration. If the error exceeds the tolerance, the integration step size is halved. |
|
|
Set the fine tolerance of the integrator. The fine tollerance, aTolFine, specifies the accuracy tolerance of an integration. If the accuracy is better than aTolFine, the integration step size should be doubled. |
|
||||||||||||
|
Set the tolerances of the integrator. The tolerance, aTol, specifies the allowd error of an integration. If the error exceeds the tolerance, the integration step size should be halved. The fine tollerance, aTolFine, specifies the accuracy tolerance of an integration. If the accuracy is better than aTolFine, the integration step size should be doubled. |
|
||||||||||||||||||||
|
Step forward in time by dt.
|
|
||||||||||||||||||||
|
Step forward in time by dt.
|
|
||||||||||||||||||||
|
Step forward in time by dt. This method does not estimate the integration error and does not return any kind of integration status other than rdRKF_NORMAL or rdRKF_NAN.
|
|
||||||||||||||||||||
|
Step forward in time by dt. This method does not estimate the integration error and does not return any kind of integration status other than rdRKF_NORMAL or rdRKF_NAN.
|
1.3