### 1.18 A simulated annealing (stochastic) optimizer

This simulated annealing algorithm implicitely honours bound constraints.

#### Helptext:

    samin: simulated annealing minimization of a function. See samin_example.m

    usage: [x, obj, convergence, details] = samin(\"f\", {args}, {control})

    Arguments:
    * \"f\": function name (string)
    * {args}: a cell array that holds all arguments of the function,
    * {control}: a cell array with 11 elements
    	* LB  - vector of lower bounds
    	* UB - vector of upper bounds
    	* nt - integer: # of iterations between temperature reductions
    	* ns - integer: # of iterations between bounds adjustments
    	* rt - (0 < rt <1): temperature reduction factor
    	* maxevals - integer: limit on function evaluations
    	* neps - integer:  number of values final result is compared to
    	* functol -   (> 0): the required tolerance level for function value
    	                   comparisons
    	* paramtol -  (> 0): the required tolerance level for parameters
    	* verbosity - scalar: 0, 1, or 2.
    		* 0 = no screen output
    		* 1 = only final results to screen
    		* 2 = summary every temperature change
    	* minarg - integer: which of function args is minimization over?

    Returns:
    * x: the minimizer
    * obj: the value of f() at x
    * convergence:
    	0 if no convergence within maxevals function evaluations
    	1 if normal convergence to a point interior to the parameter space
    	2 if convergence to point very near bounds of parameter space
    	  (suggest re-running with looser bounds)
    * details: a px3 matrix. p is the number of times improvements were found.
               The columns record information at the time an improvement was found
               * first: cumulative number of function evaluations
               * second: temperature
               * third: function value

    Example: see samin_example