Automatic parameter estimation theory
Automatic parameter estimation (APE) is a mathematical process, known as multivariable optimization, which automatically adjusts a specified set of function parameters to minimize error between the function and measured data. The mathematical function being minimized is called the objective function.
With analytical modeling in Harmony Enterprise, the objective function is calculated as follows:

If Calculate Pressure mode is used:

If Calculate Rate mode is used:
Where (summation is done for all history points, and i is the number of the point):
 (p_{hist})_{i} — historical pressure for the ith point
 (p_{calc})_{i} — calculated pressure for the ith point
 (q_{hist})_{i} — historical rate for the ith point
 (q_{calc})_{i} — calculated rate for the ith point
 w_{i} — weight for the ith point
w_{i} = 0 if the point is deselected; w_{i} = 1 if the point is selected; w_{i} = 10 if the point is weighted.
If Calculate Both mode is used, the objective function is calculated as the sum of the objective functions for Calculate Pressure and Calculate Rate modes.
E_{avg} reflects the difference between calculated and historical data; therefore a smaller E_{avg} indicates a better history match. The value of the objective function E_{avg} is displayed under the APE group in the Analytical Model pane.
Over an iterative process, the selected modeling parameters are adjusted using the Mead (Simplex) optimization method to minimize the objective function.
Automatic parameter estimation should not be used exclusively because it is possible to find several sets of parameters that yield an acceptable model match. In other words, the solution can be nonunique. It is always recommended to start with parameters obtained from diagnostic analyses, and then finetune these parameters manually to obtain a close match. You can use APE for unknown parameters, or parameters which are not known with confidence. The more parameters that are selected for APE (or fitting), the longer the fitting process will take, with a greater chance of finding nonunique solutions. Note that if you include more data points in the fit, it will reduce performance.
Mead (Simplex)
This is a variation of the downhill Simplex method. The Simplex routine is a nonlinear regression algorithm used for APE for reservoir and well parameters (k, s, CD, etc.) when modeling pressuretransient data. The Mead method only requires function evaluations of the objective function, and not the derivatives.
To achieve greater convergence, the downhill Simplex method is modified by imposing constraints on the parameters during the search. Estimates of the parameters are always checked against preset maximum and minimum values for each parameter. Once the routine has converged on some parameters, it is restarted, with a slight perturbation away from the final values, and then it is allowed to converge again. This ensures that the parameter estimates are not the result of some local minimum in the residual, but rather a more global minimum.
Compared to other nonlinear regression methods, this method is not always very efficient because it can require a large number of function evaluations. This tends to make it extremely slow in some cases. However, it is straightforward and not encumbered by the requirement of derivatives, and hence tends to be more robust under any conditions.