![]() |
OpenSWMM Engine
6.0.0-alpha.1
Data-oriented, plugin-extensible SWMM Engine (6.0.0-alpha.1)
|
Macros | |
| #define | SIGN(a, b) ((b) >= 0.0 ? fabs(a) : -fabs(a)) |
| #define | MAXIT 60 |
Functions | |
| int | findroot_Newton (double x1, double x2, double *rts, double xacc, newton_callback func, void *p) |
| Finds the root of a function using Newton's method. | |
| double | findroot_Ridder (double x1, double x2, double xacc, ridder_callback func, void *p) |
| Finds the root of a function using Ridder's method. | |
| #define MAXIT 60 |
| #define SIGN | ( | a, | |
| b | |||
| ) | ((b) >= 0.0 ? fabs(a) : -fabs(a)) |
| int findroot_Newton | ( | double | x1, |
| double | x2, | ||
| double * | rts, | ||
| double | xacc, | ||
| newton_callback | func, | ||
| void * | p | ||
| ) |
Finds the root of a function using Newton's method.
| x1 | Lower bound of the bracketing interval. |
| x2 | Upper bound of the bracketing interval. |
| rts | Pointer to the root. |
| xacc | Desired accuracy of the root. |
| func | Callback function for the function and its derivative. |
| p | Pointer to additional data. |
| double findroot_Ridder | ( | double | x1, |
| double | x2, | ||
| double | xacc, | ||
| ridder_callback | func, | ||
| void * | p | ||
| ) |
Finds the root of a function using Ridder's method.
| x1 | Lower bound of the bracketing interval. |
| x2 | Upper bound of the bracketing interval. |
| xacc | Desired accuracy of the root. |
| func | Callback function for the function. |
| p | Pointer to additional data. |