optim_doc: vfzero

Up: Zero finders [Index]

### 3.1 A vectorized version of fzero

Function File: vfzero (fun, x0)
Function File: vfzero (fun, x0, options)
Function File: [x, fval, info, output] = vfzero (…)

  A variant of `fzero`. Finds a zero of a vector-valued multivariate function where each output element only depends on the input element with the same index (so the Jacobian is diagonal).

  fun should be a handle or name of a function returning a column vector. x0 should be a two-column matrix, each row specifying two points which bracket a zero of the respective output element of fun.

  If x0 is a single-column matrix then several nearby and distant values are probed in an attempt to obtain a valid bracketing. If this is not successful, the function fails. options is a structure specifying additional options. Currently, `vfzero` recognizes these options: `"FunValCheck"`, `"OutputFcn"`, `"TolX"`, `"MaxIter"`, `"MaxFunEvals"`. For a description of these options, see optimset.

  On exit, the function returns x, the approximate zero and fval, the function value thereof. info is a column vector of exit flags that can have these values:

  - 1 The algorithm converged to a solution.
  - 0 Maximum number of iterations or function evaluations has been reached.
  - -1 The algorithm has been terminated from user output function.
  - -5 The algorithm may have converged to a singular point.

  output is a structure containing runtime information about the `fzero` algorithm. Fields in the structure are:

  - iterations Number of iterations through loop.
  - nfev Number of function evaluations.
  - bracketx A two-column matrix with the final bracketing of the zero along the x-axis.
  - brackety A two-column matrix with the final bracketing of the zero along the y-axis.

Up: Zero finders [Index]