optMaxGenTerm:

--------------------------------------------------------------------------
   Returns 1, i.e. terminates the GA, when either the maximal_generation 
   is reached or when the optimal function val is found.

   Since version 7.
--------------------------------------------------------------------------
   Form:
   [done] = optMaxGenTerm(ops,bPop,endPop)
--------------------------------------------------------------------------

   ------
   Inputs
   ------  
   ops       a vector of options [maximum_generation optimal epsilon]
   bPop      a matrix of best solutions [generation_found solution_string]
   endPop    the current generation of solutions

   -------
   Outputs
   -------
   done

--------------------------------------------------------------------------