# OPTIMIZATION APPROACHES: WHICH ONE TO USE ?

Question asked by JERRY_MARKETOS on Nov 12, 2004
The information that follows is largely compiled from within Genesys HELP,
but we receive questions from time to time and so I thought I would post here.

If this post runs past the "size" limit, the remainder will be added as first reply.

OPTIMIZATION APPROACHES:  WHICH ONE TO USE ?

When you move to invoke the optimizer (main menu ACTIONS, OPTIMIZE...),
you're presented with the following list of choices:

Minimax - Automatic
Minimax - Pattern

Least Squares - Automatic
Least Squares - Pattern

Let's begin by dicing the choices up- it's really a matrix of two things:

"Minimax" and "Least Squares" are two different methods of calculating the error term

"Pattern" and "Gradient" are two different optimization algorithms.  The "Automatic" choice
offers automatic switching between pattern and gradient optimization search.

Both optimization algorithms seek to do the same thing:  Find a set of variable values that
satisfies the optimization targets (results in error term of zero), but they have different strengths.
The gradient algorithm is well suited to making efficient progress for a given number of optimization
rounds.  The gradient algorithm is fairly tolerant of initial variable values that aren't close to optimum,
but it may not arrive at the absolute best optimum variable values.  That's where the pattern search
algorithm comes in...  it may be a bit less efficient in terms of progress made for number of
optimization rounds executed, but will generally  "home in" on the optimum values and is more
resistant to becoming trapped in local minima of the error function.

Note that the tuning increment set for tuning variable values in Genesys...
has nothing to do with the increments used by the optimizer.  The Genesys optimizer uses
adaptive variable stepping (step size is not always constant).  Further, the variable steps
are independent for all variables (based on prior observed performance).  The Genesys optimization
algorithms are proprietary and have benefitted from many years of fine tuning.  Truth is that in most
cases, either algorithm will find the best set of optimum results, but I recommend using the Automatic
setting as a rule.  This provides maximum flexibility in the optimization process.  If you find optimization
progressing poorly, you can try other options and also be sure to see note below.

The text above discusses the two different optimization algorithms.  Next, let's discuss two different ways
to compute the error function itself, and some implications of the difference:

The "least squares" approach computes the error function using the sum of the squared errors.  Applying optimization
to an error function computed in this manner will tend to bring improvement to the average (or overall) performance.

The "minimax" approach computes the error function using the best and worst (minimum and maximum) error terms.
Applying optimization to an error function computed using the minimax approach will cause the optimizer to
tend to concentrate on the worst case portions of a given performance parameter (ie. where the measured performance
is most different from the given optimization targets).

The best choice for which optimizer to use is affected by the number of variables present and by the sensitivity
of circuit performance to those variables and also by the specific shape of the trace (most often versus frequency)
being optimized.   Most often I use the least squares automatic approach, but hopefully the information contained
here will arm the reader with information to make informed judgements on optimization choices.

Further information is available within Genesys HELP.  Choose main menu HELP, CONTENTS, then switch to the
"search" tab and search for "optimization".  Click the button for "list topics".  I strongly recommend to read the topic
entitled "optimization overview".  Other topics will probably also be of interest.