parameters: (self,signatures,func,pre=False)
docstring: For a signature tuple, sets the simplifier to func.
  
          Args:
              signatures (list): a list of argument signatures. A signature can be:
  
                  - the operation name for an OperatorExpression, passing the arg directly to func(...)
                  - '_scalar': matches to a constant scalar, and passes that constant to func(...)
                  - '_const': matches to constant, and passes that constant to func(...)
                  - '_returnType': passes the argument's returnType() to func(...)
                  - None: match all.  The arg is passed directly to func(...)
  
              func (callable): a callable that takes a list of arguments, possibly transformed by _const or _returnType.
                  This returns a simplified Expression or None.
  
              pre (bool, optional): if True, the simplifier is called before arguments are simplified.
  
          If multiple matches are present then they are tested in order
  
          1. operation name
          2. _const
          3. _returnType
          4. None
docstring_summary: For a signature tuple, sets the simplifier to func.
docstring_tokens: For a signature tuple sets the simplifier to func .
function: def addSimplifier(self,signatures,func,pre=False):
          """For a signature tuple, sets the simplifier to func.
  
          Args:
              signatures (list): a list of argument signatures. A signature can be:
  
                  - the operation name for an OperatorExpression, passing the arg directly to func(...)
                  - '_scalar': matches to a constant scalar, and passes that constant to func(...)
                  - '_const': matches to constant, and passes that constant to func(...)
                  - '_returnType': passes the argument's returnType() to func(...)
                  - None: match all.  The arg is passed directly to func(...)
  
              func (callable): a callable that takes a list of arguments, possibly transformed by _const or _returnType.
                  This returns a simplified Expression or None.
  
              pre (bool, optional): if True, the simplifier is called before arguments are simplified.
  
          If multiple matches are present then they are tested in order
  
          1. operation name
          2. _const
          3. _returnType
          4. None
  
          """
          if self.argNames is not None:
              if len(signatures) != len(self.argNames):
                  raise ValueError("Invalid signature length")
          if len(signatures) == 0:
              raise ValueError("Invalid signature tuple")
          root = self.presimplifierDict if pre else self.simplifierDict
          for s in signatures[:-1]:
              if s is not None and not isinstance(s,str):
                  raise ValueError("Signatures must be strings or None")
              root = root.setdefault(s,dict())
          root[signatures[-1]] = func
function_tokens: def addSimplifier ( self , signatures , func , pre = False ) : if self . argNames is not None : if len ( signatures ) != len ( self . argNames ) : raise ValueError ( "Invalid signature length" ) if len ( signatures ) == 0 : raise ValueError ( "Invalid signature tuple" ) root = self . presimplifierDict if pre else self . simplifierDict for s in signatures [ : - 1 ] : if s is not None and not isinstance ( s , str ) : raise ValueError ( "Signatures must be strings or None" ) root = root . setdefault ( s , dict ( ) ) root [ signatures [ - 1 ] ] = func