docstr: Non linear decreasing/increasing with modulation index(n).
  The linear strategy can be made to converge faster without compromising
  on exploration with the use of this index which makes the equation non-linear.
  
  Defaults: :math:`n=1.2`
  
  .. math::
          w = w^{end}+(w^{start}-w^{end}) \frac{(iter^{max}-iter)^{n}}{(iter^{max})^{n}}
  
  Ref:  A. Chatterjee, P. Siarry, Nonlinear inertia weight variation for dynamic adaption
  in particle swarm optimization, Computer and Operations Research 33 (2006)
  859–871, March 2006
docstr_tok: ["Non","linear","decreasing\/increasing","with","modulation","index","(","n",")",".","The","linear","strategy","can","be","made","to","converge","faster","without","compromising","on","exploration","with","the","use","of","this","index","which","makes","the","equation","non-linear",".","Defaults",":",":","math",":","`","n=1.2","`","..","math",":",":","w","=","w^","{","end","}","+","(","w^","{","start","}","-w^","{","end","}",")","\\frac","{","(","iter^","{","max","}","-iter",")","^","{","n","}","}","{","(","iter^","{","max","}",")","^","{","n","}","}","Ref",":","A.","Chatterjee",",","P.","Siarry",",","Nonlinear","inertia","weight","variation","for","dynamic","adaption","in","particle","swarm","optimization",",","Computer","and","Operations","Research","33","(","2006",")","859\u2013871",",","March","2006"]
code: def nonlin_mod(self, start_opts, opt, **kwargs):
      """Non linear decreasing/increasing with modulation index(n).
      The linear strategy can be made to converge faster without compromising
      on exploration with the use of this index which makes the equation non-linear.
  
      Defaults: :math:`n=1.2`
  
      .. math::
              w = w^{end}+(w^{start}-w^{end}) \\frac{(iter^{max}-iter)^{n}}{(iter^{max})^{n}}
  
      Ref:  A. Chatterjee, P. Siarry, Nonlinear inertia weight variation for dynamic adaption
      in particle swarm optimization, Computer and Operations Research 33 (2006)
      859–871, March 2006
      """
  
      try:
          if "n" not in kwargs:
              n = 1.2
          else:
              n = kwargs["n"]
  
          end_opts = {
              "w": 0.4,
              "c1": 0.8 * start_opts["c1"],
              "c2": 1 * start_opts["c2"],
          }
          if "end_opts" in kwargs:
              if opt in kwargs["end_opts"]:
                  end_opts[opt] = kwargs["end_opts"][opt]
  
          start = start_opts[opt]
          end = end_opts[opt]
          new_val = end + (start - end) * (
              (kwargs["itermax"] - kwargs["iternow"]) ** n
              / kwargs["itermax"] ** n
          )
      except KeyError:
          self.rep.logger.exception(
              "Keyword 'itermax' or 'iternow' missing"
          )
          raise
      else:
          return new_val
  
imports: import inspect
  import logging
  import numpy
  import math
  from copy import copy
  from ..utils.reporter import Reporter
label_desc: Use image node_id 6 for calling the OptionsHandler obj's underlying member method code with example usage: obj.nonlin_mod(start_opts, opt) and returns: new_val