|
|
TSolveEquationParameters |
The TSolveEquationParameters data structure holds the convergence parameters used by C_SolveEquation.
typedef struct {
int Size;
int MaxNumberOfIterations;
double Tolerance;
double MaxStep;
double Delta;
} TSolveEquationParameters;
Specifies the size, in bytes, of this data structure. Set this member to sizeof(TSolveEquationParameters) before calling a function with a TSolveEquationParameters parameter.
The maximum number of steps that the C_SolveEquation will use when trying to solve the given equation.
This controls the accuracy of the solution. C_SolveEquation searches for a value of $X$ which satisfies
\begin{equation}
| Y(X) - \textrm{TargetY} | < \textrm{Tolerance}
\end{equation}
This limits the change in $X$ value from one iteration to the next in C_SolveEquation. When C_SolveEquation choose new values of $X$ it will not choose a value more than MaxStep away from the previous value of $X$.
This is a perturbation size, used to calculate the derivative of $Y$. Delta should always be less than the tolerance specified. If the latest estimate of the solution is $X$, then the derivative will be estimated as
\begin{equation}
\frac{Y(X+\delta X) - Y(X)}{\delta X}
\end{equation}
where $\delta X = \textrm{Delta} \times X$.