Click or drag to resize

IExternalNonLinearMinimizationSolverSolve Method

Minimizes a black-box non-linear equation.

Namespace: DWSIM.Interfaces
Assembly: DWSIM.Interfaces (in DWSIM.Interfaces.dll) Version: 8.8.1.0
Syntax
double[] Solve(
	Func<double[], double> functionbody,
	Func<double[], double[]> functiongradient,
	Func<double[], double, bool> iterationcallback,
	double[] vars,
	double[] lbounds,
	double[] ubounds,
	int maxits,
	double tolerance
)
Request Example

Parameters

functionbody  FuncDouble, Double
Function which gets the current x values and returns the function value.
functiongradient  FuncDouble, Double
Optional. Function which gets the current x values and returns the gradient values.
iterationcallback  FuncDouble, Double, Boolean
Function called n each iteration step. First argument is the x-vector, second argument is function value. Return true to stop the iterations or false to continue.
vars  Double
Initial value of the variables.
lbounds  Double
Optional. Lower bounds for variables.
ubounds  Double
Optional. Upper bounds for variables.
maxits  Int32
Maximum iterations.
tolerance  Double
Tolerance for solution.

Return Value

Double
The solution vector corresponding to the function minimum.
See Also