# This file was automatically generated by SWIG (http://www.swig.org).
# Version 3.0.11
#
# Do not make changes to this file unless you know what you are doing--modify
# the SWIG interface file instead.





from sys import version_info as _swig_python_version_info
if _swig_python_version_info >= (2, 7, 0):
    def swig_import_helper():
        import importlib
        pkg = __name__.rpartition('.')[0]
        mname = '.'.join((pkg, '_casadi')).lstrip('.')
        try:
            return importlib.import_module(mname)
        except ImportError:
            return importlib.import_module('_casadi')
    _casadi = swig_import_helper()
    del swig_import_helper
elif _swig_python_version_info >= (2, 6, 0):
    def swig_import_helper():
        from os.path import dirname
        import imp
        fp = None
        try:
            fp, pathname, description = imp.find_module('_casadi', [dirname(__file__)])
        except ImportError:
            import _casadi
            return _casadi
        if fp is not None:
            try:
                _mod = imp.load_module('_casadi', fp, pathname, description)
            finally:
                fp.close()
            return _mod
    _casadi = swig_import_helper()
    del swig_import_helper
else:
    import _casadi
del _swig_python_version_info
try:
    _swig_property = property
except NameError:
    pass  # Python < 2.2 doesn't have 'property'.

try:
    import builtins as __builtin__
except ImportError:
    import __builtin__

def _swig_setattr_nondynamic(self, class_type, name, value, static=1):
    if (name == "thisown"):
        return self.this.own(value)
    if (name == "this"):
        if type(value).__name__ == 'SwigPyObject':
            self.__dict__[name] = value
            return
    method = class_type.__swig_setmethods__.get(name, None)
    if method:
        return method(self, value)
    if (not static):
        if _newclass:
            object.__setattr__(self, name, value)
        else:
            self.__dict__[name] = value
    else:
        raise AttributeError("You cannot add attributes to %s" % self)


def _swig_setattr(self, class_type, name, value):
    return _swig_setattr_nondynamic(self, class_type, name, value, 0)


def _swig_getattr(self, class_type, name):
    if (name == "thisown"):
        return self.this.own()
    method = class_type.__swig_getmethods__.get(name, None)
    if method:
        return method(self)
    raise AttributeError("'%s' object has no attribute '%s'" % (class_type.__name__, name))


def _swig_repr(self):
    try:
        strthis = "proxy of " + self.this.__repr__()
    except __builtin__.Exception:
        strthis = ""
    return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,)

try:
    _object = object
    _newclass = 1
except __builtin__.Exception:
    class _object:
        pass
    _newclass = 0

try:
    import weakref
    weakref_proxy = weakref.proxy
except __builtin__.Exception:
    weakref_proxy = lambda x: x


CASADI_INT_TYPE_STR = _casadi.CASADI_INT_TYPE_STR
SOLVER_RET_SUCCESS = _casadi.SOLVER_RET_SUCCESS
SOLVER_RET_UNKNOWN = _casadi.SOLVER_RET_UNKNOWN
SOLVER_RET_LIMITED = _casadi.SOLVER_RET_LIMITED
SOLVER_RET_NAN = _casadi.SOLVER_RET_NAN
SOLVER_RET_INFEASIBLE = _casadi.SOLVER_RET_INFEASIBLE
SOLVER_RET_EXCEPTION = _casadi.SOLVER_RET_EXCEPTION


import contextlib

class _copyableObject(object):
  def __copy__(self):
    return self.__class__(self)

  def __deepcopy__(self,dummy=None):
    return self.__class__(self)

_object = object = _copyableObject

_swig_repr_default = _swig_repr
def _swig_repr(self):
  if hasattr(self,'repr'):
    return self.repr()
  else:
    return _swig_repr_default(self)

def DM_from_array(m, check_only=True):
  import numpy as np
  if isinstance(m, np.ndarray):
    if len(m.shape)>2:
      return False
    try:
      m = m.astype(float,casting="same_kind",copy=False)
    except:
      return False
    if check_only:
      return True
    else:
      shape = m.shape + (1, 1)
      nrow, ncol = shape[0], shape[1]
      return (nrow,ncol,m.flat)
  return False

def IM_from_array(m, check_only=True):
  import numpy as np
  if isinstance(m, np.ndarray):
    if len(m.shape)>2:
      return False
    try:
      m = m.astype(int,casting="same_kind",copy=False)
    except:
      return False
    if check_only:
      return True
    else:
      shape = m.shape + (1, 1)
      nrow, ncol = shape[0], shape[1]
      return (nrow,ncol,m.flat)
  return False

def SX_from_array(m, check_only=True):
  import numpy as np
  if isinstance(m, np.ndarray):
    if len(m.shape)>2:
      return False
    if m.dtype!=object: return None
    shape = m.shape + (1, 1)
    nrow, ncol = shape[0], shape[1]
    return (nrow,ncol,m.flat)
  return False

def DM_from_csc(m, check_only=True):
  if hasattr(m,"tocsc"):
    m = m.tocsc()
  if m.__class__.__name__ == "csc_matrix":
    if len(m.shape)!=2: return False
    if check_only: return True
    return m.shape + (m.indptr.flat,m.indices.flat,m.data.flat)
  return False


MNAME = _casadi.MNAME
class SwigPyIterator(_object):
    """


    ::

      SwigPyIterator() -> 



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, SwigPyIterator, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, SwigPyIterator, name)

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined - class is abstract")
    __repr__ = _swig_repr
    __swig_destroy__ = _casadi.delete_SwigPyIterator

    def value(self, *args) -> "PyObject *":
        """


        ::

          value(self) -> PyObject *



        """
        return _casadi.SwigPyIterator_value(self, *args)


    def incr(self, *args) -> "swig::SwigPyIterator *":
        """


        ::

          incr(self, size_t n) -> SwigPyIterator



        """
        return _casadi.SwigPyIterator_incr(self, *args)


    def decr(self, *args) -> "swig::SwigPyIterator *":
        """


        ::

          decr(self, size_t n) -> SwigPyIterator



        """
        return _casadi.SwigPyIterator_decr(self, *args)


    def distance(self, *args) -> "ptrdiff_t":
        """


        ::

          distance(self, SwigPyIterator x) -> ptrdiff_t



        """
        return _casadi.SwigPyIterator_distance(self, *args)


    def equal(self, *args) -> "bool":
        """


        ::

          equal(self, SwigPyIterator x) -> bool



        """
        return _casadi.SwigPyIterator_equal(self, *args)


    def copy(self, *args) -> "swig::SwigPyIterator *":
        """


        ::

          copy(self) -> SwigPyIterator



        """
        return _casadi.SwigPyIterator_copy(self, *args)


    def next(self, *args) -> "PyObject *":
        """


        ::

          next(self) -> PyObject *



        """
        return _casadi.SwigPyIterator_next(self, *args)


    def __next__(self, *args) -> "PyObject *":
        """


        ::

          __next__(self) -> PyObject *



        """
        return _casadi.SwigPyIterator___next__(self, *args)


    def previous(self, *args) -> "PyObject *":
        """


        ::

          previous(self) -> PyObject *



        """
        return _casadi.SwigPyIterator_previous(self, *args)


    def advance(self, *args) -> "swig::SwigPyIterator *":
        """


        ::

          advance(self, ptrdiff_t n) -> SwigPyIterator



        """
        return _casadi.SwigPyIterator_advance(self, *args)


    def __eq__(self, *args) -> "bool":
        """


        ::

          __eq__(self, SwigPyIterator x) -> bool



        """
        return _casadi.SwigPyIterator___eq__(self, *args)


    def __ne__(self, *args) -> "bool":
        """


        ::

          __ne__(self, SwigPyIterator x) -> bool



        """
        return _casadi.SwigPyIterator___ne__(self, *args)


    def __iadd__(self, *args) -> "swig::SwigPyIterator &":
        """


        ::

          __iadd__(self, ptrdiff_t n) -> SwigPyIterator



        """
        return _casadi.SwigPyIterator___iadd__(self, *args)


    def __isub__(self, *args) -> "swig::SwigPyIterator &":
        """


        ::

          __isub__(self, ptrdiff_t n) -> SwigPyIterator



        """
        return _casadi.SwigPyIterator___isub__(self, *args)


    def __add__(self, *args) -> "swig::SwigPyIterator *":
        """


        ::

          __add__(self, ptrdiff_t n) -> SwigPyIterator



        """
        return _casadi.SwigPyIterator___add__(self, *args)


    def __sub__(self, *args) -> "ptrdiff_t":
        """


        ::

          __sub__(self, SwigPyIterator x) -> ptrdiff_t
          __sub__(self, ptrdiff_t n) -> SwigPyIterator



        """
        return _casadi.SwigPyIterator___sub__(self, *args)

    def __iter__(self):
        return self
SwigPyIterator_swigregister = _casadi.SwigPyIterator_swigregister
SwigPyIterator_swigregister(SwigPyIterator)

L_INT = _casadi.L_INT
L_BOOL = _casadi.L_BOOL
LL = _casadi.LL
LR = _casadi.LR
L_DICT = _casadi.L_DICT
L_DOUBLE = _casadi.L_DOUBLE
L_STR = _casadi.L_STR
LABEL = _casadi.LABEL

if __name__ != "casadi.casadi":
  raise Exception("""
            CasADi is not running from its package context.

            You probably specified the wrong casadi directory.

            When setting PYTHONPATH or sys.path.append,
            take care not to add a trailing '/casadi'.

        """)

def swigtypeconvertor(*args):
  return swig_typename_convertor_python2cpp(args)

def swig_typename_convertor_python2cpp(a):
  try:
    import numpy as np
  except:
    class NoExist:
      pass
    class Temp(object):
      ndarray = NoExist
    np = Temp()
  if isinstance(a,list):
    if len(a)>0:
      return "[%s]" % "|".join(set([swig_typename_convertor_python2cpp(i) for i in a]))
    else:
      return "[]"
  elif isinstance(a,tuple):
    return "(%s)" % ",".join([swig_typename_convertor_python2cpp(i) for i in a])
  elif isinstance(a,np.ndarray):
    return "np.array(%s)" % ",".join(set([swig_typename_convertor_python2cpp(i) for i in np.array(a).flatten().tolist()]))
  elif isinstance(a,dict):
    if len(a)>0:
      return "|".join(set([swig_typename_convertor_python2cpp(i) for i in a.keys()])) +":"+ "|".join(set([swig_typename_convertor_python2cpp(i) for i in a.values()]))
    else:
      return "dict"
  return type(a).__name__


try:
  from numpy import pi, inf, sum
except:
  pass

arcsin = lambda x: _casadi.asin(x)
arccos = lambda x: _casadi.acos(x)
arctan = lambda x: _casadi.atan(x)
arctan2 = lambda x,y: _casadi.atan2(x, y)
arctanh = lambda x: _casadi.atanh(x)
arcsinh = lambda x: _casadi.asinh(x)
arccosh = lambda x: _casadi.acosh(x)


def veccat(*args):
    try:
        if len(args)==0:
            return DM(0,1)
    except:
        pass
    return _veccat(args)
def vertcat(*args):
    try:
        if len(args)==0:
            return DM(0,1)
    except:
        pass
    return _vertcat(args)
def horzcat(*args):
    try:
        if len(args)==0:
            return DM(1,0)
    except:
        pass
    return _horzcat(args)
def diagcat(*args):
    try:
        if len(args)==0:
            return DM(0,0)
    except:
        pass
    return _diagcat(args)
def vvcat(args):
    try:
        if len(args)==0:
            return DM(0,1)
    except:
        pass
    return _veccat(args)
def vcat(args):
    try:
        if len(args)==0:
            return DM(0,1)
    except:
        pass
    return _vertcat(args)
def hcat(args):
    try:
        if len(args)==0:
            return DM(1,0)
    except:
        pass
    return _horzcat(args)
def dcat(args):
    try:
        if len(args)==0:
            return DM(0,0)
    except:
        pass
    return _diagcat(args)


class NZproxy:
  def __init__(self,matrix):
    self.matrix = matrix

  def __getitem__(self,s):
    return self.matrix.get_nz(False, s)

  def __setitem__(self,s,val):
    return self.matrix.set_nz(val, False, s)

  def __len__(self):
    return self.matrix.nnz()

  def __iter__(self):
    for i in range(len(self)):
      yield self[i]


class PrintableCommon(_object):
    """


    ::

      PrintableCommon() -> 



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, PrintableCommon, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, PrintableCommon, name)
    __repr__ = _swig_repr

    def __str__(self): return self.str()
    def repr(self): return self.type_name() + '(' + self.str() + ')'


    def __init__(self, *args):
        """


        ::

          PrintableCommon()
          PrintableCommon(PrintableCommon other)



        """
        this = _casadi.new_PrintableCommon(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_PrintableCommon
PrintableCommon_swigregister = _casadi.PrintableCommon_swigregister
PrintableCommon_swigregister(PrintableCommon)

class GenSharedObject(_object):
    """
      [INTERNAL] C++ includes: generic_shared.hpp

    ::





    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, GenSharedObject, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, GenSharedObject, name)
    __repr__ = _swig_repr

    def debug_repr(self, *args) -> "std::string":
        """


        ::

          debug_repr(self) -> str



        """
        return _casadi.GenSharedObject_debug_repr(self, *args)


    def is_null(self, *args) -> "bool":
        """


        ::

          is_null(self) -> bool



        """
        return _casadi.GenSharedObject_is_null(self, *args)


    def __hash__(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          __hash__(self) -> int

        Returns a number that is unique for a given Node.

        If the Object does not point to any node, "0" is returned.

        Extra doc: https://github.com/casadi/casadi/wiki/L_av

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_shared.hpp#L124

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_shared_impl.hpp#L141-L143




        """
        return _casadi.GenSharedObject___hash__(self, *args)


    def __init__(self, *args):
        """


        ::

          GenSharedObject()
          GenSharedObject(GenSharedObject other)



        """
        this = _casadi.new_GenSharedObject(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_GenSharedObject
GenSharedObject_swigregister = _casadi.GenSharedObject_swigregister
GenSharedObject_swigregister(GenSharedObject)

class GenWeakRef(GenSharedObject):
    """
      [INTERNAL] C++ includes: generic_shared.hpp

    ::





    """

    __swig_setmethods__ = {}
    for _s in [GenSharedObject]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, GenWeakRef, name, value)
    __swig_getmethods__ = {}
    for _s in [GenSharedObject]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, GenWeakRef, name)
    __repr__ = _swig_repr

    def is_null(self, *args) -> "bool":
        """


        ::

          is_null(self) -> bool



        """
        return _casadi.GenWeakRef_is_null(self, *args)


    def shared(self, *args) -> "casadi::SharedObject":
        """


        ::

          shared(self) -> SharedObject



        """
        return _casadi.GenWeakRef_shared(self, *args)


    def alive(self, *args) -> "bool":
        """


        ::

          alive(self) -> bool



        """
        return _casadi.GenWeakRef_alive(self, *args)


    def shared_if_alive(self, *args) -> "bool":
        """


        ::

          shared_if_alive(self, SharedObject shared) -> bool



        """
        return _casadi.GenWeakRef_shared_if_alive(self, *args)


    def __init__(self, *args):
        """


        ::

          GenWeakRef(int dummy)
          GenWeakRef(SharedObject shared)
          GenWeakRef(GenWeakRef other)



        """
        this = _casadi.new_GenWeakRef(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_GenWeakRef
GenWeakRef_swigregister = _casadi.GenWeakRef_swigregister
GenWeakRef_swigregister(GenWeakRef)

class SharedObject(GenSharedObject):
    """
      [INTERNAL] 

    ::


     GenericShared implements a reference counting framework similar
     for efficient and.

    easily-maintained memory management.

    To use the class, both the  GenericShared class (the public class), and the 
    GenericSharedInternal class (the 
    internal class) must be inherited from. It
     can be done in two 
    different files and together with memory management, 
    this approach 
    provides a clear distinction of which methods of the class 
    are to be 
    considered "public", i.e. methods for public use that can be 

    considered to remain over time with small changes, and the internal 
    memory.

    When interfacing a software, which typically includes including some 
    header
     file, this is best done only in the file where the internal 
    class is 
    defined, to avoid polluting the global namespace and other 
    side effects.

    The default constructor always means creating a null pointer to an 
    internal
     class only. To allocate an internal class (this works only 
    when the 
    internal class isn't abstract), use the constructor with 
    arguments.

    The copy constructor and the assignment operator perform shallow 
    copies 
    only, to make a deep copy you must use the clone method 
    explicitly. This 
    will give a shared pointer instance.

    In an inheritance hierarchy, you can cast down automatically, e.g. 

    (SXFunction is a child class of  Function): SXFunction derived(...);  
    Function base = derived;

    To cast up, use the shared_cast template function, which works 
    analogously 
    to dynamic_cast, static_cast, const_cast etc, e.g.: 
    SXFunction 
    derived(...);  Function base = derived; SXFunction derived_from_base = 

    shared_cast<SXFunction>(base);

    A failed shared_cast will result in a null pointer (cf. dynamic_cast)

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_as

    C++ includes: shared_object.hpp



    """

    __swig_setmethods__ = {}
    for _s in [GenSharedObject]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, SharedObject, name, value)
    __swig_getmethods__ = {}
    for _s in [GenSharedObject]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, SharedObject, name)
    __repr__ = _swig_repr

    def class_name(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          class_name(self) -> str

        Get class name.

        Extra doc: https://github.com/casadi/casadi/wiki/L_au

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/shared_object.hpp#L85

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/shared_object.cpp#L31-L33




        """
        return _casadi.SharedObject_class_name(self, *args)


    def disp(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          disp(self, bool more)

        Print a description of the object.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/shared_object.hpp#L88

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/shared_object.cpp#L35-L41




        """
        return _casadi.SharedObject_disp(self, *args)


    def str(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          str(self, bool more) -> str

        Get string representation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/shared_object.hpp#L91

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/shared_object.hpp#L91-L95




        """
        return _casadi.SharedObject_str(self, *args)


    def print_ptr(self, *args) -> "void":
        """


        ::

          print_ptr(self)



        """
        return _casadi.SharedObject_print_ptr(self, *args)


    def __init__(self, *args):
        """


        ::

          SharedObject()
          SharedObject(SharedObject other)



        """
        this = _casadi.new_SharedObject(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_SharedObject
SharedObject_swigregister = _casadi.SharedObject_swigregister
SharedObject_swigregister(SharedObject)

class WeakRef(GenWeakRef):
    """
      [INTERNAL] 

    ::


    Weak reference type.

    A weak reference to a  GenericShared
    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_ax

    C++ includes: shared_object.hpp



    """

    __swig_setmethods__ = {}
    for _s in [GenWeakRef]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, WeakRef, name, value)
    __swig_getmethods__ = {}
    for _s in [GenWeakRef]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, WeakRef, name)
    __repr__ = _swig_repr

    def __init__(self, *args):
        """


        ::

          WeakRef(int dummy)
          WeakRef(SharedObject shared)
          WeakRef(WeakRef other)


        .......

        ::

          WeakRef(WeakRef other)



        .............


        .......

        ::

          WeakRef(int dummy)
          WeakRef(SharedObject shared)



        [INTERNAL] 

        .............



        """
        this = _casadi.new_WeakRef(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_WeakRef
WeakRef_swigregister = _casadi.WeakRef_swigregister
WeakRef_swigregister(WeakRef)


def complement(*args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
    """
      [INTERNAL] 

    ::

      complement([int] v, int size) -> [int]

    Returns the list of all i in [0, size[ not found in supplied 
    list.

    The supplied vector may contain duplicates and may be non-monotonous 
    The 
    supplied vector will be checked for bounds The result vector is 
    guaranteed 
    to be monotonously increasing

    Extra doc: https://github.com/casadi/casadi/wiki/L_1lf

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L137

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.cpp#L137-L153




    """
    return _casadi.complement(*args)

def lookupvector(*args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
    """
      [INTERNAL] 

    ::

      lookupvector([int] v) -> [int]
      lookupvector([int] v, int size) -> [int]


    .......

    ::

      lookupvector([int] v)



    [INTERNAL] 

    .............


    .......

    ::

      lookupvector([int] v, int size)



    [INTERNAL] 
    Returns a vector for quickly looking up entries of supplied 
    list.

    lookupvector[i]!=-1 <=> v contains i v[lookupvector[i]] == i <=> v 
    contains
     i

    Duplicates are treated by looking up last occurrence

    Extra doc: https://github.com/casadi/casadi/wiki/L_1lg

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L155

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.cpp#L155-L164



    .............



    """
    return _casadi.lookupvector(*args)

def temporary_file(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      temporary_file(str prefix, str suffix) -> str



    """
    return _casadi.temporary_file(*args)

def normalized_setup(*args) -> "void":
    """
      [INTERNAL] 

    ::

      normalized_setup()
      normalized_setup(std::istream & stream)



    """
    return _casadi.normalized_setup(*args)
class StreamStateGuard(_object):
    """
      [INTERNAL] C++ includes: casadi_misc.hpp

    ::





    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, StreamStateGuard, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, StreamStateGuard, name)
    __repr__ = _swig_repr
    __swig_destroy__ = _casadi.delete_StreamStateGuard

    def __init__(self, *args):
        """


        ::

          StreamStateGuard(std::ostream & os)
          StreamStateGuard(StreamStateGuard other)


        .......

        ::

          StreamStateGuard(StreamStateGuard other)



        .............


        .......

        ::

          StreamStateGuard(std::ostream & os)



        [INTERNAL] 

        .............



        """
        this = _casadi.new_StreamStateGuard(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
StreamStateGuard_swigregister = _casadi.StreamStateGuard_swigregister
StreamStateGuard_swigregister(StreamStateGuard)


def normalized_out(*args) -> "void":
    """
      [INTERNAL] 

    ::

      normalized_out(float val)



    """
    return _casadi.normalized_out(*args)

def normalized_in(*args) -> "int":
    """
      [INTERNAL] 

    ::

      normalized_in(std::istream & stream, double & ret) -> int



    """
    return _casadi.normalized_in(*args)
SWIG_IND1 = _casadi.SWIG_IND1
class GenericType(PrintableCommon):
    """
      [INTERNAL] 

    ::


    Generic data type, can hold different types such as bool, 
    casadi_int, 
    std::string etc.

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_17n

    C++ includes: generic_type.hpp



    """

    __swig_setmethods__ = {}
    for _s in [PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, GenericType, name, value)
    __swig_getmethods__ = {}
    for _s in [PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, GenericType, name)
    __repr__ = _swig_repr

    def serialize(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          serialize(self, casadi::SerializingStream & s)

        Serialize an object.

        Extra doc: https://github.com/casadi/casadi/wiki/L_17r

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_type.hpp#L249

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_type.cpp#L742-L745




        """
        return _casadi.GenericType_serialize(self, *args)


    def deserialize(*args) -> "casadi::GenericType":
        """


        ::

          deserialize(casadi::DeserializingStream & s) -> GenericType



        """
        return _casadi.GenericType_deserialize(*args)

    deserialize = staticmethod(deserialize)

    def __init__(self, *args):
        """


        ::

          GenericType()
          GenericType(GenericType other)


        .......

        ::

          GenericType(GenericType other)



        .............


        .......

        ::

          GenericType()



        [INTERNAL] 
        Default constructor.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_type.hpp#L85

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_type.cpp#L249-L250



        .............



        """
        this = _casadi.new_GenericType(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_GenericType
GenericType_swigregister = _casadi.GenericType_swigregister
GenericType_swigregister(GenericType)

def GenericType_deserialize(*args) -> "casadi::GenericType":
    """


    ::

      deserialize(casadi::DeserializingStream & s) -> GenericType



    """
    return _casadi.GenericType_deserialize(*args)

OP_ASSIGN = _casadi.OP_ASSIGN
OP_ADD = _casadi.OP_ADD
OP_SUB = _casadi.OP_SUB
OP_MUL = _casadi.OP_MUL
OP_DIV = _casadi.OP_DIV
OP_NEG = _casadi.OP_NEG
OP_EXP = _casadi.OP_EXP
OP_LOG = _casadi.OP_LOG
OP_POW = _casadi.OP_POW
OP_CONSTPOW = _casadi.OP_CONSTPOW
OP_SQRT = _casadi.OP_SQRT
OP_SQ = _casadi.OP_SQ
OP_TWICE = _casadi.OP_TWICE
OP_SIN = _casadi.OP_SIN
OP_COS = _casadi.OP_COS
OP_TAN = _casadi.OP_TAN
OP_ASIN = _casadi.OP_ASIN
OP_ACOS = _casadi.OP_ACOS
OP_ATAN = _casadi.OP_ATAN
OP_LT = _casadi.OP_LT
OP_LE = _casadi.OP_LE
OP_EQ = _casadi.OP_EQ
OP_NE = _casadi.OP_NE
OP_NOT = _casadi.OP_NOT
OP_AND = _casadi.OP_AND
OP_OR = _casadi.OP_OR
OP_FLOOR = _casadi.OP_FLOOR
OP_CEIL = _casadi.OP_CEIL
OP_FMOD = _casadi.OP_FMOD
OP_FABS = _casadi.OP_FABS
OP_SIGN = _casadi.OP_SIGN
OP_COPYSIGN = _casadi.OP_COPYSIGN
OP_IF_ELSE_ZERO = _casadi.OP_IF_ELSE_ZERO
OP_ERF = _casadi.OP_ERF
OP_FMIN = _casadi.OP_FMIN
OP_FMAX = _casadi.OP_FMAX
OP_INV = _casadi.OP_INV
OP_SINH = _casadi.OP_SINH
OP_COSH = _casadi.OP_COSH
OP_TANH = _casadi.OP_TANH
OP_ASINH = _casadi.OP_ASINH
OP_ACOSH = _casadi.OP_ACOSH
OP_ATANH = _casadi.OP_ATANH
OP_ATAN2 = _casadi.OP_ATAN2
OP_CONST = _casadi.OP_CONST
OP_INPUT = _casadi.OP_INPUT
OP_OUTPUT = _casadi.OP_OUTPUT
OP_PARAMETER = _casadi.OP_PARAMETER
OP_CALL = _casadi.OP_CALL
OP_FIND = _casadi.OP_FIND
OP_LOW = _casadi.OP_LOW
OP_MAP = _casadi.OP_MAP
OP_MTIMES = _casadi.OP_MTIMES
OP_SOLVE = _casadi.OP_SOLVE
OP_TRANSPOSE = _casadi.OP_TRANSPOSE
OP_DETERMINANT = _casadi.OP_DETERMINANT
OP_INVERSE = _casadi.OP_INVERSE
OP_DOT = _casadi.OP_DOT
OP_BILIN = _casadi.OP_BILIN
OP_RANK1 = _casadi.OP_RANK1
OP_HORZCAT = _casadi.OP_HORZCAT
OP_VERTCAT = _casadi.OP_VERTCAT
OP_DIAGCAT = _casadi.OP_DIAGCAT
OP_HORZSPLIT = _casadi.OP_HORZSPLIT
OP_VERTSPLIT = _casadi.OP_VERTSPLIT
OP_DIAGSPLIT = _casadi.OP_DIAGSPLIT
OP_RESHAPE = _casadi.OP_RESHAPE
OP_SUBREF = _casadi.OP_SUBREF
OP_SUBASSIGN = _casadi.OP_SUBASSIGN
OP_GETNONZEROS = _casadi.OP_GETNONZEROS
OP_GETNONZEROS_PARAM = _casadi.OP_GETNONZEROS_PARAM
OP_ADDNONZEROS = _casadi.OP_ADDNONZEROS
OP_ADDNONZEROS_PARAM = _casadi.OP_ADDNONZEROS_PARAM
OP_SETNONZEROS = _casadi.OP_SETNONZEROS
OP_SETNONZEROS_PARAM = _casadi.OP_SETNONZEROS_PARAM
OP_PROJECT = _casadi.OP_PROJECT
OP_ASSERTION = _casadi.OP_ASSERTION
OP_MONITOR = _casadi.OP_MONITOR
OP_NORM2 = _casadi.OP_NORM2
OP_NORM1 = _casadi.OP_NORM1
OP_NORMINF = _casadi.OP_NORMINF
OP_NORMF = _casadi.OP_NORMF
OP_MMIN = _casadi.OP_MMIN
OP_MMAX = _casadi.OP_MMAX
OP_HORZREPMAT = _casadi.OP_HORZREPMAT
OP_HORZREPSUM = _casadi.OP_HORZREPSUM
OP_ERFINV = _casadi.OP_ERFINV
OP_PRINTME = _casadi.OP_PRINTME
OP_LIFT = _casadi.OP_LIFT
OP_EINSTEIN = _casadi.OP_EINSTEIN
OP_BSPLINE = _casadi.OP_BSPLINE
OP_CONVEXIFY = _casadi.OP_CONVEXIFY
OP_SPARSITY_CAST = _casadi.OP_SPARSITY_CAST
OP_LOG1P = _casadi.OP_LOG1P
OP_EXPM1 = _casadi.OP_EXPM1
OP_HYPOT = _casadi.OP_HYPOT
OP_LOGSUMEXP = _casadi.OP_LOGSUMEXP
OP_REMAINDER = _casadi.OP_REMAINDER
class SparsityInterfaceCommon(_object):
    """
      [INTERNAL] 

    ::

      SparsityInterfaceCommon() -> 

    Sparsity interface class.

    This is a common base class for  GenericMatrix (i.e.  MX and Matrix<>) and 
    Sparsity, introducing a uniform syntax and 
    implementing common 
    functionality using the curiously recurring 
    template pattern (CRTP) idiom.

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_3d

    C++ includes: sparsity_interface.hpp



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, SparsityInterfaceCommon, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, SparsityInterfaceCommon, name)
    __repr__ = _swig_repr

    def __init__(self, *args):
        """


        ::

          SparsityInterfaceCommon()
          SparsityInterfaceCommon(SparsityInterfaceCommon other)



        """
        this = _casadi.new_SparsityInterfaceCommon(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_SparsityInterfaceCommon
SparsityInterfaceCommon_swigregister = _casadi.SparsityInterfaceCommon_swigregister
SparsityInterfaceCommon_swigregister(SparsityInterfaceCommon)

class Sparsity(SharedObject, SparsityInterfaceCommon, PrintableCommon):
    """


    ::




    """

    __swig_setmethods__ = {}
    for _s in [SharedObject, SparsityInterfaceCommon, PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, Sparsity, name, value)
    __swig_getmethods__ = {}
    for _s in [SharedObject, SparsityInterfaceCommon, PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, Sparsity, name)
    __repr__ = _swig_repr

    def scalar(*args) -> "casadi::Sparsity":
        """


        ::

          scalar(bool dense_scalar) -> Sparsity



        """
        return _casadi.Sparsity_scalar(*args)

    scalar = staticmethod(scalar)

    def dense(*args) -> "casadi::Sparsity":
        """


        ::

          dense(int nrow, int ncol) -> Sparsity
          dense((int,int) rc) -> Sparsity



        """
        return _casadi.Sparsity_dense(*args)

    dense = staticmethod(dense)

    def unit(*args) -> "casadi::Sparsity":
        """


        ::

          unit(int n, int el) -> Sparsity



        """
        return _casadi.Sparsity_unit(*args)

    unit = staticmethod(unit)

    def upper(*args) -> "casadi::Sparsity":
        """


        ::

          upper(int n) -> Sparsity



        """
        return _casadi.Sparsity_upper(*args)

    upper = staticmethod(upper)

    def lower(*args) -> "casadi::Sparsity":
        """


        ::

          lower(int n) -> Sparsity



        """
        return _casadi.Sparsity_lower(*args)

    lower = staticmethod(lower)

    def diag(*args) -> "casadi::Sparsity":
        """


        ::

          diag(int nrow) -> Sparsity
          diag((int,int) rc) -> Sparsity
          diag(int nrow, int ncol) -> Sparsity



        """
        return _casadi.Sparsity_diag(*args)

    diag = staticmethod(diag)

    def band(*args) -> "casadi::Sparsity":
        """


        ::

          band(int n, int p) -> Sparsity



        """
        return _casadi.Sparsity_band(*args)

    band = staticmethod(band)

    def banded(*args) -> "casadi::Sparsity":
        """


        ::

          banded(int n, int p) -> Sparsity



        """
        return _casadi.Sparsity_banded(*args)

    banded = staticmethod(banded)

    def rowcol(*args) -> "casadi::Sparsity":
        """


        ::

          rowcol([int] row, [int] col, int nrow, int ncol) -> Sparsity



        """
        return _casadi.Sparsity_rowcol(*args)

    rowcol = staticmethod(rowcol)

    def triplet(*args) -> "casadi::Sparsity":
        """


        ::

          triplet(int nrow, int ncol, [int] row, [int] col) -> Sparsity
          triplet(int nrow, int ncol, [int] row, [int] col, bool invert_mapping) -> (Sparsity , [int] OUTPUT)



        """
        return _casadi.Sparsity_triplet(*args)

    triplet = staticmethod(triplet)

    def nonzeros(*args) -> "casadi::Sparsity":
        """


        ::

          nonzeros(int nrow, int ncol, [int] nz, bool ind1) -> Sparsity



        """
        return _casadi.Sparsity_nonzeros(*args)

    nonzeros = staticmethod(nonzeros)

    def compressed(*args) -> "casadi::Sparsity":
        """


        ::

          compressed([int] v, bool order_rows) -> Sparsity



        """
        return _casadi.Sparsity_compressed(*args)

    compressed = staticmethod(compressed)

    def permutation(*args) -> "casadi::Sparsity":
        """


        ::

          permutation([int] p, bool invert) -> Sparsity



        """
        return _casadi.Sparsity_permutation(*args)

    permutation = staticmethod(permutation)

    def permutation_vector(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > > const":
        """


        ::

          permutation_vector(self, bool invert) -> [int]



        """
        return _casadi.Sparsity_permutation_vector(self, *args)


    def get_diag(self, *args) -> "casadi::Sparsity":
        """


        ::

          get_diag(self) -> (Sparsity , [int] OUTPUT)



        """
        return _casadi.Sparsity_get_diag(self, *args)


    def compress(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """


        ::

          compress(self, bool canonical) -> [int]



        """
        return _casadi.Sparsity_compress(self, *args)


    def is_equal(self, *args) -> "bool":
        """


        ::

          is_equal(self, Sparsity y) -> bool
          is_equal(self, int nrow, int ncol, [int] colind, [int] row) -> bool



        """
        return _casadi.Sparsity_is_equal(self, *args)


    def __eq__(self, *args) -> "bool":
        """


        ::

          __eq__(self, Sparsity y) -> bool



        """
        return _casadi.Sparsity___eq__(self, *args)


    def __ne__(self, *args) -> "bool":
        """


        ::

          __ne__(self, Sparsity y) -> bool



        """
        return _casadi.Sparsity___ne__(self, *args)


    def is_stacked(self, *args) -> "bool":
        """


        ::

          is_stacked(self, Sparsity y, int n) -> bool



        """
        return _casadi.Sparsity_is_stacked(self, *args)


    def size1(self, *args) -> "casadi_int":
        """


        ::

          size1(self) -> int



        """
        return _casadi.Sparsity_size1(self, *args)


    def rows(self, *args) -> "casadi_int":
        """


        ::

          rows(self) -> int



        """
        return _casadi.Sparsity_rows(self, *args)


    def size2(self, *args) -> "casadi_int":
        """


        ::

          size2(self) -> int



        """
        return _casadi.Sparsity_size2(self, *args)


    def columns(self, *args) -> "casadi_int":
        """


        ::

          columns(self) -> int



        """
        return _casadi.Sparsity_columns(self, *args)


    def numel(self, *args) -> "casadi_int":
        """


        ::

          numel(self) -> int



        """
        return _casadi.Sparsity_numel(self, *args)


    def density(self, *args) -> "double":
        """


        ::

          density(self) -> float



        """
        return _casadi.Sparsity_density(self, *args)


    def is_empty(self, *args) -> "bool":
        """


        ::

          is_empty(self, bool both) -> bool



        """
        return _casadi.Sparsity_is_empty(self, *args)


    def nnz(self, *args) -> "casadi_int":
        """


        ::

          nnz(self) -> int



        """
        return _casadi.Sparsity_nnz(self, *args)


    def nnz_upper(self, *args) -> "casadi_int":
        """


        ::

          nnz_upper(self, bool strictly) -> int



        """
        return _casadi.Sparsity_nnz_upper(self, *args)


    def nnz_lower(self, *args) -> "casadi_int":
        """


        ::

          nnz_lower(self, bool strictly) -> int



        """
        return _casadi.Sparsity_nnz_lower(self, *args)


    def nnz_diag(self, *args) -> "casadi_int":
        """


        ::

          nnz_diag(self) -> int



        """
        return _casadi.Sparsity_nnz_diag(self, *args)


    def bw_upper(self, *args) -> "casadi_int":
        """


        ::

          bw_upper(self) -> int



        """
        return _casadi.Sparsity_bw_upper(self, *args)


    def bw_lower(self, *args) -> "casadi_int":
        """


        ::

          bw_lower(self) -> int



        """
        return _casadi.Sparsity_bw_lower(self, *args)


    def size(self, *args) -> "casadi_int":
        """


        ::

          size(self) -> (int,int)
          size(self, int axis) -> int



        """
        return _casadi.Sparsity_size(self, *args)


    def info(self, *args) -> "casadi::Dict":
        """


        ::

          info(self) -> dict



        """
        return _casadi.Sparsity_info(self, *args)


    def to_file(self, *args) -> "void":
        """


        ::

          to_file(self, str filename, str format_hint)



        """
        return _casadi.Sparsity_to_file(self, *args)


    def from_file(*args) -> "casadi::Sparsity":
        """


        ::

          from_file(str filename, str format_hint) -> Sparsity



        """
        return _casadi.Sparsity_from_file(*args)

    from_file = staticmethod(from_file)

    def serialize(self, *args) -> "void":
        """


        ::

          serialize(self) -> str
          serialize(self, casadi::SerializingStream & s)



        """
        return _casadi.Sparsity_serialize(self, *args)


    def deserialize(*args) -> "casadi::Sparsity":
        """


        ::

          deserialize(std::istream & stream) -> Sparsity
          deserialize(casadi::DeserializingStream & s) -> Sparsity
          deserialize(str s) -> Sparsity



        """
        return _casadi.Sparsity_deserialize(*args)

    deserialize = staticmethod(deserialize)

    def colind(self, *args) -> "casadi_int":
        """


        ::

          colind(self) -> [int]
          colind(self, int cc) -> int



        """
        return _casadi.Sparsity_colind(self, *args)


    def row(self, *args) -> "casadi_int":
        """


        ::

          row(self) -> [int]
          row(self, int el) -> int



        """
        return _casadi.Sparsity_row(self, *args)


    def get_col(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """


        ::

          get_col(self) -> [int]



        """
        return _casadi.Sparsity_get_col(self, *args)


    def resize(self, *args) -> "void":
        """


        ::

          resize(self, int nrow, int ncol)



        """
        return _casadi.Sparsity_resize(self, *args)


    def add_nz(self, *args) -> "casadi_int":
        """


        ::

          add_nz(self, int rr, int cc) -> int



        """
        return _casadi.Sparsity_add_nz(self, *args)


    def has_nz(self, *args) -> "bool":
        """


        ::

          has_nz(self, int rr, int cc) -> bool



        """
        return _casadi.Sparsity_has_nz(self, *args)


    def get_nz(self, *args) -> "void":
        """


        ::

          get_nz(self) -> [int]
          get_nz(self, int rr, int cc) -> int
          get_nz(self, [int] rr, [int] cc) -> [int]



        """
        return _casadi.Sparsity_get_nz(self, *args)


    def get_lower(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """


        ::

          get_lower(self) -> [int]



        """
        return _casadi.Sparsity_get_lower(self, *args)


    def get_upper(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """


        ::

          get_upper(self) -> [int]



        """
        return _casadi.Sparsity_get_upper(self, *args)


    def get_ccs(self, *args) -> "void":
        """


        ::

          get_ccs(self) -> ([int] OUTPUT, [int] OUTPUT)



        """
        return _casadi.Sparsity_get_ccs(self, *args)


    def get_crs(self, *args) -> "void":
        """


        ::

          get_crs(self) -> ([int] OUTPUT, [int] OUTPUT)



        """
        return _casadi.Sparsity_get_crs(self, *args)


    def get_triplet(self, *args) -> "void":
        """


        ::

          get_triplet(self) -> ([int] OUTPUT, [int] OUTPUT)



        """
        return _casadi.Sparsity_get_triplet(self, *args)


    def sub(self, *args) -> "casadi::Sparsity":
        """


        ::

          sub(self, [int] rr, Sparsity sp, bool ind1) -> (Sparsity , [int] OUTPUT)
          sub(self, [int] rr, [int] cc, bool ind1) -> (Sparsity , [int] OUTPUT)



        """
        return _casadi.Sparsity_sub(self, *args)


    def transpose(self, *args) -> "casadi::Sparsity":
        """


        ::

          transpose(self, bool invert_mapping) -> (Sparsity , [int] OUTPUT)



        """
        return _casadi.Sparsity_transpose(self, *args)


    def is_transpose(self, *args) -> "bool":
        """


        ::

          is_transpose(self, Sparsity y) -> bool



        """
        return _casadi.Sparsity_is_transpose(self, *args)


    def is_reshape(self, *args) -> "bool":
        """


        ::

          is_reshape(self, Sparsity y) -> bool



        """
        return _casadi.Sparsity_is_reshape(self, *args)


    def combine(self, *args) -> "casadi::Sparsity":
        """


        ::

          combine(self, Sparsity y, bool f0x_is_zero, bool function0_is_zero) -> Sparsity



        """
        return _casadi.Sparsity_combine(self, *args)


    def unite(self, *args) -> "casadi::Sparsity":
        """


        ::

          unite(self, Sparsity y) -> Sparsity



        """
        return _casadi.Sparsity_unite(self, *args)


    def __add__(self, *args) -> "casadi::Sparsity":
        """


        ::

          __add__(self, Sparsity b) -> Sparsity



        """
        return _casadi.Sparsity___add__(self, *args)


    def intersect(self, *args) -> "casadi::Sparsity":
        """


        ::

          intersect(self, Sparsity y) -> Sparsity



        """
        return _casadi.Sparsity_intersect(self, *args)


    def __mul__(self, *args) -> "casadi::Sparsity":
        """


        ::

          __mul__(self, Sparsity b) -> Sparsity



        """
        return _casadi.Sparsity___mul__(self, *args)


    def is_subset(self, *args) -> "bool":
        """


        ::

          is_subset(self, Sparsity rhs) -> bool



        """
        return _casadi.Sparsity_is_subset(self, *args)


    def sparsity_cast_mod(self, *args) -> "casadi::Sparsity":
        """


        ::

          sparsity_cast_mod(self, Sparsity X, Sparsity Y) -> Sparsity



        """
        return _casadi.Sparsity_sparsity_cast_mod(self, *args)


    def pattern_inverse(self, *args) -> "casadi::Sparsity":
        """


        ::

          pattern_inverse(self) -> Sparsity



        """
        return _casadi.Sparsity_pattern_inverse(self, *args)


    def enlarge(self, *args) -> "void":
        """


        ::

          enlarge(self, int nrow, int ncol, [int] rr, [int] cc, bool ind1)



        """
        return _casadi.Sparsity_enlarge(self, *args)


    def enlargeRows(self, *args) -> "void":
        """


        ::

          enlargeRows(self, int nrow, [int] rr, bool ind1)



        """
        return _casadi.Sparsity_enlargeRows(self, *args)


    def enlargeColumns(self, *args) -> "void":
        """


        ::

          enlargeColumns(self, int ncol, [int] cc, bool ind1)



        """
        return _casadi.Sparsity_enlargeColumns(self, *args)


    def makeDense(self, *args) -> "casadi::Sparsity":
        """


        ::

          makeDense(self) -> (Sparsity , [int] OUTPUT)



        """
        return _casadi.Sparsity_makeDense(self, *args)


    def erase(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """


        ::

          erase(self, [int] rr, bool ind1) -> [int]
          erase(self, [int] rr, [int] cc, bool ind1) -> [int]



        """
        return _casadi.Sparsity_erase(self, *args)


    def append(self, *args) -> "void":
        """


        ::

          append(self, Sparsity sp)



        """
        return _casadi.Sparsity_append(self, *args)


    def appendColumns(self, *args) -> "void":
        """


        ::

          appendColumns(self, Sparsity sp)



        """
        return _casadi.Sparsity_appendColumns(self, *args)


    def is_scalar(self, *args) -> "bool":
        """


        ::

          is_scalar(self, bool scalar_and_dense) -> bool



        """
        return _casadi.Sparsity_is_scalar(self, *args)


    def is_dense(self, *args) -> "bool":
        """


        ::

          is_dense(self) -> bool



        """
        return _casadi.Sparsity_is_dense(self, *args)


    def is_row(self, *args) -> "bool":
        """


        ::

          is_row(self) -> bool



        """
        return _casadi.Sparsity_is_row(self, *args)


    def is_column(self, *args) -> "bool":
        """


        ::

          is_column(self) -> bool



        """
        return _casadi.Sparsity_is_column(self, *args)


    def is_vector(self, *args) -> "bool":
        """


        ::

          is_vector(self) -> bool



        """
        return _casadi.Sparsity_is_vector(self, *args)


    def is_diag(self, *args) -> "bool":
        """


        ::

          is_diag(self) -> bool



        """
        return _casadi.Sparsity_is_diag(self, *args)


    def is_square(self, *args) -> "bool":
        """


        ::

          is_square(self) -> bool



        """
        return _casadi.Sparsity_is_square(self, *args)


    def is_symmetric(self, *args) -> "bool":
        """


        ::

          is_symmetric(self) -> bool



        """
        return _casadi.Sparsity_is_symmetric(self, *args)


    def is_triu(self, *args) -> "bool":
        """


        ::

          is_triu(self, bool strictly) -> bool



        """
        return _casadi.Sparsity_is_triu(self, *args)


    def is_tril(self, *args) -> "bool":
        """


        ::

          is_tril(self, bool strictly) -> bool



        """
        return _casadi.Sparsity_is_tril(self, *args)


    def is_singular(self, *args) -> "bool":
        """


        ::

          is_singular(self) -> bool



        """
        return _casadi.Sparsity_is_singular(self, *args)


    def is_permutation(self, *args) -> "bool":
        """


        ::

          is_permutation(self) -> bool



        """
        return _casadi.Sparsity_is_permutation(self, *args)


    def is_selection(self, *args) -> "bool":
        """


        ::

          is_selection(self, bool allow_empty) -> bool



        """
        return _casadi.Sparsity_is_selection(self, *args)


    def is_orthonormal(self, *args) -> "bool":
        """


        ::

          is_orthonormal(self, bool allow_empty) -> bool



        """
        return _casadi.Sparsity_is_orthonormal(self, *args)


    def is_orthonormal_rows(self, *args) -> "bool":
        """


        ::

          is_orthonormal_rows(self, bool allow_empty) -> bool



        """
        return _casadi.Sparsity_is_orthonormal_rows(self, *args)


    def is_orthonormal_columns(self, *args) -> "bool":
        """


        ::

          is_orthonormal_columns(self, bool allow_empty) -> bool



        """
        return _casadi.Sparsity_is_orthonormal_columns(self, *args)


    def rowsSequential(self, *args) -> "bool":
        """


        ::

          rowsSequential(self, bool strictly) -> bool



        """
        return _casadi.Sparsity_rowsSequential(self, *args)


    def removeDuplicates(self, *args) -> "void":
        """


        ::

          removeDuplicates(self) -> [int]



        """
        return _casadi.Sparsity_removeDuplicates(self, *args)


    def etree(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """


        ::

          etree(self, bool ata) -> [int]



        """
        return _casadi.Sparsity_etree(self, *args)


    def ldl(self, *args) -> "casadi::Sparsity":
        """


        ::

          ldl(self, bool amd) -> (Sparsity , [int] OUTPUT)



        """
        return _casadi.Sparsity_ldl(self, *args)


    def qr_sparse(self, *args) -> "void":
        """


        ::

          qr_sparse(self, bool amd) -> (Sparsity OUTPUT, Sparsity OUTPUT, [int] OUTPUT, [int] OUTPUT)



        """
        return _casadi.Sparsity_qr_sparse(self, *args)


    def dfs(self, *args) -> "casadi_int":
        """


        ::

          dfs(self, int j, int top, [int] pinv) -> (int , [int] INOUT, [int] INOUT, [bool] INOUT)



        """
        return _casadi.Sparsity_dfs(self, *args)


    def scc(self, *args) -> "casadi_int":
        """


        ::

          scc(self) -> (int , [int] OUTPUT, [int] OUTPUT)



        """
        return _casadi.Sparsity_scc(self, *args)


    def btf(self, *args) -> "casadi_int":
        """


        ::

          btf(self) -> (int , [int] OUTPUT, [int] OUTPUT, [int] OUTPUT, [int] OUTPUT, [int] OUTPUT, [int] OUTPUT)



        """
        return _casadi.Sparsity_btf(self, *args)


    def amd(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """


        ::

          amd(self) -> [int]



        """
        return _casadi.Sparsity_amd(self, *args)


    def find(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """


        ::

          find(self, bool ind1) -> [int]



        """
        return _casadi.Sparsity_find(self, *args)


    def uni_coloring(self, *args) -> "casadi::Sparsity":
        """


        ::

          uni_coloring(self, Sparsity AT, int cutoff) -> Sparsity



        """
        return _casadi.Sparsity_uni_coloring(self, *args)


    def star_coloring(self, *args) -> "casadi::Sparsity":
        """


        ::

          star_coloring(self, int ordering, int cutoff) -> Sparsity



        """
        return _casadi.Sparsity_star_coloring(self, *args)


    def star_coloring2(self, *args) -> "casadi::Sparsity":
        """


        ::

          star_coloring2(self, int ordering, int cutoff) -> Sparsity



        """
        return _casadi.Sparsity_star_coloring2(self, *args)


    def largest_first(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """


        ::

          largest_first(self) -> [int]



        """
        return _casadi.Sparsity_largest_first(self, *args)


    def pmult(self, *args) -> "casadi::Sparsity":
        """


        ::

          pmult(self, [int] p, bool permute_rows, bool permute_columns, bool invert_permutation) -> Sparsity



        """
        return _casadi.Sparsity_pmult(self, *args)


    def dim(self, *args) -> "std::string":
        """


        ::

          dim(self, bool with_nz) -> str



        """
        return _casadi.Sparsity_dim(self, *args)


    def postfix_dim(self, *args) -> "std::string":
        """


        ::

          postfix_dim(self) -> str



        """
        return _casadi.Sparsity_postfix_dim(self, *args)


    def repr_el(self, *args) -> "std::string":
        """


        ::

          repr_el(self, int k) -> str



        """
        return _casadi.Sparsity_repr_el(self, *args)


    def spy(self, *args) -> "void":
        """


        ::

          spy(self)



        """
        return _casadi.Sparsity_spy(self, *args)


    def spy_matlab(self, *args) -> "void":
        """


        ::

          spy_matlab(self, str mfile)



        """
        return _casadi.Sparsity_spy_matlab(self, *args)


    def export_code(self, *args) -> "void":
        """


        ::

          export_code(self, str lang, dict options)



        """
        return _casadi.Sparsity_export_code(self, *args)


    def type_name(*args) -> "std::string":
        """


        ::

          type_name() -> str



        """
        return _casadi.Sparsity_type_name(*args)

    type_name = staticmethod(type_name)

    def hash(self, *args) -> "std::size_t":
        """


        ::

          hash(self) -> std::size_t



        """
        return _casadi.Sparsity_hash(self, *args)


    def test_cast(*args) -> "bool":
        """


        ::

          test_cast(casadi::SharedObjectInternal const * ptr) -> bool



        """
        return _casadi.Sparsity_test_cast(*args)

    test_cast = staticmethod(test_cast)

    def kkt(*args) -> "casadi::Sparsity":
        """


        ::

          kkt(Sparsity H, Sparsity J, bool with_x_diag, bool with_lam_g_diag) -> Sparsity



        """
        return _casadi.Sparsity_kkt(*args)

    kkt = staticmethod(kkt)

    def __setstate__(self, state):
        self.__init__(Sparsity.deserialize(state["serialization"]))

    def __getstate__(self):
        return {"serialization": self.serialize()}


    @property
    def shape(self):
        return (self.size1(),self.size2())

    @property
    def T(self):
        return _casadi.transpose(self)

    def __array__(self,*args,**kwargs):
        return DM.ones(self).full()


    def __init__(self, *args):
        """


        ::

          Sparsity(int dummy)
          Sparsity((int,int) rc)
          Sparsity(Sparsity other)
          Sparsity(int nrow, int ncol)
          Sparsity(int nrow, int ncol, [int] colind, [int] row, bool order_rows)



        """
        this = _casadi.new_Sparsity(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_Sparsity
Sparsity_swigregister = _casadi.Sparsity_swigregister
Sparsity_swigregister(Sparsity)

def Sparsity_scalar(*args) -> "casadi::Sparsity":
    """


    ::

      scalar(bool dense_scalar) -> Sparsity



    """
    return _casadi.Sparsity_scalar(*args)

def Sparsity_dense(*args) -> "casadi::Sparsity":
    """


    ::

      dense(int nrow, int ncol) -> Sparsity
      dense((int,int) rc) -> Sparsity



    """
    return _casadi.Sparsity_dense(*args)

def Sparsity_unit(*args) -> "casadi::Sparsity":
    """


    ::

      unit(int n, int el) -> Sparsity



    """
    return _casadi.Sparsity_unit(*args)

def Sparsity_upper(*args) -> "casadi::Sparsity":
    """


    ::

      upper(int n) -> Sparsity



    """
    return _casadi.Sparsity_upper(*args)

def Sparsity_lower(*args) -> "casadi::Sparsity":
    """


    ::

      lower(int n) -> Sparsity



    """
    return _casadi.Sparsity_lower(*args)

def Sparsity_diag(*args) -> "casadi::Sparsity":
    """


    ::

      diag(int nrow) -> Sparsity
      diag((int,int) rc) -> Sparsity
      diag(int nrow, int ncol) -> Sparsity



    """
    return _casadi.Sparsity_diag(*args)

def Sparsity_band(*args) -> "casadi::Sparsity":
    """


    ::

      band(int n, int p) -> Sparsity



    """
    return _casadi.Sparsity_band(*args)

def Sparsity_banded(*args) -> "casadi::Sparsity":
    """


    ::

      banded(int n, int p) -> Sparsity



    """
    return _casadi.Sparsity_banded(*args)

def Sparsity_rowcol(*args) -> "casadi::Sparsity":
    """


    ::

      rowcol([int] row, [int] col, int nrow, int ncol) -> Sparsity



    """
    return _casadi.Sparsity_rowcol(*args)

def Sparsity_triplet(*args) -> "casadi::Sparsity":
    """


    ::

      triplet(int nrow, int ncol, [int] row, [int] col) -> Sparsity
      triplet(int nrow, int ncol, [int] row, [int] col, bool invert_mapping) -> (Sparsity , [int] OUTPUT)



    """
    return _casadi.Sparsity_triplet(*args)

def Sparsity_nonzeros(*args) -> "casadi::Sparsity":
    """


    ::

      nonzeros(int nrow, int ncol, [int] nz, bool ind1) -> Sparsity



    """
    return _casadi.Sparsity_nonzeros(*args)

def Sparsity_compressed(*args) -> "casadi::Sparsity":
    """


    ::

      compressed([int] v, bool order_rows) -> Sparsity



    """
    return _casadi.Sparsity_compressed(*args)

def Sparsity_permutation(*args) -> "casadi::Sparsity":
    """


    ::

      permutation([int] p, bool invert) -> Sparsity



    """
    return _casadi.Sparsity_permutation(*args)

def Sparsity_from_file(*args) -> "casadi::Sparsity":
    """


    ::

      from_file(str filename, str format_hint) -> Sparsity



    """
    return _casadi.Sparsity_from_file(*args)

def Sparsity_deserialize(*args) -> "casadi::Sparsity":
    """


    ::

      deserialize(std::istream & stream) -> Sparsity
      deserialize(casadi::DeserializingStream & s) -> Sparsity
      deserialize(str s) -> Sparsity



    """
    return _casadi.Sparsity_deserialize(*args)

def Sparsity_type_name(*args) -> "std::string":
    """


    ::

      type_name() -> str



    """
    return _casadi.Sparsity_type_name(*args)

def Sparsity_test_cast(*args) -> "bool":
    """


    ::

      test_cast(casadi::SharedObjectInternal const * ptr) -> bool



    """
    return _casadi.Sparsity_test_cast(*args)

def Sparsity_kkt(*args) -> "casadi::Sparsity":
    """


    ::

      kkt(Sparsity H, Sparsity J, bool with_x_diag, bool with_lam_g_diag) -> Sparsity



    """
    return _casadi.Sparsity_kkt(*args)


def hash_sparsity(*args) -> "std::size_t":
    """


    ::

      hash_sparsity(int nrow, int ncol, casadi_int const * colind, casadi_int const * row) -> std::size_t
      hash_sparsity(int nrow, int ncol, [int] colind, [int] row) -> std::size_t



    """
    return _casadi.hash_sparsity(*args)
class Slice(PrintableCommon):
    """
      [INTERNAL] 

    ::


    Class representing a  Slice.

    Note that Python or Octave do not need to use this class. They can 
    just use
     slicing utility from the host language ( M[0:6] in Python, 
    M(1:7) )

    Extra doc: https://github.com/casadi/casadi/wiki/L_13

    C++ includes: slice.hpp



    """

    __swig_setmethods__ = {}
    for _s in [PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, Slice, name, value)
    __swig_getmethods__ = {}
    for _s in [PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, Slice, name)
    __repr__ = _swig_repr
    __swig_getmethods__["start"] = _casadi.Slice_start_get
    if _newclass:
        start = _swig_property(_casadi.Slice_start_get)
    __swig_getmethods__["stop"] = _casadi.Slice_stop_get
    if _newclass:
        stop = _swig_property(_casadi.Slice_stop_get)
    __swig_getmethods__["step"] = _casadi.Slice_step_get
    if _newclass:
        step = _swig_property(_casadi.Slice_step_get)

    def all(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """
          [INTERNAL] 

        ::

          all(self) -> [int]
          all(self, int len, bool ind1) -> [int]
          all(self, Slice outer, int len) -> [int]

        Get a vector of indices (nested slice)

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L75

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L129-L137



        .......

        ::

          all(self)



        [INTERNAL] 
        Get a vector of indices.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L69

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L90-L98


        .............


        .......

        ::

          all(self, int len, bool ind1)



        [INTERNAL] 
        Get a vector of indices.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L72

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L100-L102



        .............


        .......

        ::

          all(self, Slice outer, int len)



        [INTERNAL] 
        Get a vector of indices (nested slice)

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L75

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L129-L137



        .............



        """
        return _casadi.Slice_all(self, *args)


    def size(self, *args) -> "size_t":
        """
          [INTERNAL] 

        ::

          size(self) -> size_t

        Get number of elements.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L78

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L104-L109




        """
        return _casadi.Slice_size(self, *args)


    def is_empty(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_empty(self) -> bool

        Check if slice is empty.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L81

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L111-L113




        """
        return _casadi.Slice_is_empty(self, *args)


    def is_scalar(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_scalar(self, int len) -> bool

        Is the slice a scalar.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L84

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L139-L144




        """
        return _casadi.Slice_is_scalar(self, *args)


    def scalar(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          scalar(self, int len) -> int

        Get scalar (if is_scalar)

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L87

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L146-L150




        """
        return _casadi.Slice_scalar(self, *args)


    def __eq__(self, *args) -> "bool":
        """


        ::

          __eq__(self, Slice other) -> bool



        """
        return _casadi.Slice___eq__(self, *args)


    def __ne__(self, *args) -> "bool":
        """


        ::

          __ne__(self, Slice other) -> bool



        """
        return _casadi.Slice___ne__(self, *args)


    def apply(self, *args) -> "casadi::Slice":
        """
          [INTERNAL] 

        ::

          apply(self, int len, bool ind1) -> Slice

        Apply concrete length.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L98

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L66-L88



        """
        return _casadi.Slice_apply(self, *args)


    def __sub__(self, *args) -> "casadi::Slice":
        """


        ::

          __sub__(self, int i) -> Slice



        """
        return _casadi.Slice___sub__(self, *args)


    def __mul__(self, *args) -> "casadi::Slice":
        """


        ::

          __mul__(self, int i) -> Slice



        """
        return _casadi.Slice___mul__(self, *args)


    def type_name(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          type_name(self) -> str

        Get name of the class.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L107

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L107-L107




        """
        return _casadi.Slice_type_name(self, *args)


    def disp(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          disp(self, bool more)

        Print a description of the object.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L110

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L115-L127




        """
        return _casadi.Slice_disp(self, *args)


    def str(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          str(self, bool more) -> str

        Get string representation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L113

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L113-L117




        """
        return _casadi.Slice_str(self, *args)


    def info(self, *args) -> "casadi::Dict":
        """
          [INTERNAL] 

        ::

          info(self) -> dict

        Obtain information

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L120

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L120-L122




        """
        return _casadi.Slice_info(self, *args)


    def serialize(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          serialize(self, casadi::SerializingStream & s)

        Serialize an object.

        Extra doc: https://github.com/casadi/casadi/wiki/L_14

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L127

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L292-L296




        """
        return _casadi.Slice_serialize(self, *args)


    def deserialize(*args) -> "casadi::Slice":
        """


        ::

          deserialize(casadi::DeserializingStream & s) -> Slice



        """
        return _casadi.Slice_deserialize(*args)

    deserialize = staticmethod(deserialize)

    def __init__(self, *args):
        """


        ::

          Slice()
          Slice(int i, bool ind1)
          Slice(Slice other)
          Slice(int start, int stop, int step)
          Slice(int start, int stop, int step)
          Slice(int start, int stop, int step)
          Slice(int start, int stop, int step)


        .......

        ::

          Slice(Slice other)



        .............


        .......

        ::

          Slice()



        [INTERNAL] 
        Default constructor - all elements.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L57

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L32-L33


        .............


        .......

        ::

          Slice(int i, bool ind1)



        [INTERNAL] 
        A single element (explicit to avoid ambiguity with IM overload.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L60

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L35-L42


        .............


        .......

        ::

          Slice(int start, int stop, int step)



        [INTERNAL] 
        A slice.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L63

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L44-L45


        .............


        .......

        ::

          Slice(int start, int stop, int step)
          Slice(int start, int stop, int step)
          Slice(int start, int stop, int step)



        [INTERNAL] 

        .............



        """
        this = _casadi.new_Slice(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_Slice
Slice_swigregister = _casadi.Slice_swigregister
Slice_swigregister(Slice)

def Slice_deserialize(*args) -> "casadi::Slice":
    """


    ::

      deserialize(casadi::DeserializingStream & s) -> Slice



    """
    return _casadi.Slice_deserialize(*args)


def to_slice(*args) -> "casadi::Slice":
    """
      [INTERNAL] 

    ::

      to_slice([int] v, bool ind1) -> Slice

    Construct from an index vector (requires is_slice(v) to be true)

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L152

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L152-L168




    """
    return _casadi.to_slice(*args)

def to_slice2(*args) -> "std::pair< casadi::Slice,casadi::Slice >":
    """
      [INTERNAL] 

    ::

      to_slice2([int] v) -> std::pair< casadi::Slice,casadi::Slice >

    Construct nested slices from an index vector (requires 
    is_slice2(v) to
     be true)

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L255

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L255-L289




    """
    return _casadi.to_slice2(*args)

def is_slice(*args) -> "bool":
    """
      [INTERNAL] 

    ::

      is_slice([int] v, bool ind1) -> bool

    Check if an index vector can be represented more efficiently as 
    a 
    slice.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L170

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L170-L200




    """
    return _casadi.is_slice(*args)

def is_slice2(*args) -> "bool":
    """
      [INTERNAL] 

    ::

      is_slice2([int] v) -> bool

    Check if an index vector can be represented more efficiently as 
    two 
    nested slices.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/slice.hpp#L202

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/slice.cpp#L202-L253




    """
    return _casadi.is_slice2(*args)
class GenericMatrixCommon(_object):
    """
      [INTERNAL] 

    ::

      GenericMatrixCommon() -> 

     Matrix base class.

    This is a common base class for  MX and Matrix<>, introducing a uniform 
    syntax and implementing common 
    functionality using the curiously recurring 
    template pattern (CRTP) 
    idiom.
     The class is designed with the idea that 
    "everything is a matrix",
     that is, also scalars and vectors.
    This 
    philosophy makes it easy to use and to interface in particularly
     with 
    Python and Matlab/Octave.
     The syntax tries to stay as close as possible to 
    the ublas syntax 
    when it comes to vector/matrix operations.
     Index starts 
    with 0.
    Index vec happens as follows: (rr, cc) -> k = rr+cc*size1()
    Vectors 
    are column vectors.
     The storage format is Compressed Column Storage (CCS), 
    similar to 
    that used for sparse matrices in Matlab, 
    but unlike this 
    format, we do allow for elements to be structurally 
    non-zero but 
    numerically zero.
     The sparsity pattern, which is reference counted and 
    cached, can be 
    accessed with Sparsity&  sparsity()
    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_1am

    C++ includes: generic_matrix.hpp



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, GenericMatrixCommon, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, GenericMatrixCommon, name)
    __repr__ = _swig_repr

    def __mldivide__(x, y): return _casadi.mldivide(x, y)
    def __rmldivide__(y, x): return _casadi.mldivide(x, y)
    def __mrdivide__(x, y): return _casadi.mrdivide(x, y)
    def __rmrdivide__(y, x): return _casadi.mrdivide(x, y)
    def __mpower__(x, y): return _casadi.mpower(x, y)
    def __rmpower__(y, x): return _casadi.mpower(x, y)


    def __init__(self, *args):
        """


        ::

          GenericMatrixCommon()
          GenericMatrixCommon(GenericMatrixCommon other)



        """
        this = _casadi.new_GenericMatrixCommon(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_GenericMatrixCommon
GenericMatrixCommon_swigregister = _casadi.GenericMatrixCommon_swigregister
GenericMatrixCommon_swigregister(GenericMatrixCommon)


def index_interp1d(*args) -> "double":
    """
      [INTERNAL] 

    ::

      index_interp1d([float] x, float xq, bool equidistant) -> float



    """
    return _casadi.index_interp1d(*args)
class GenDM(GenericMatrixCommon, SparsityInterfaceCommon):
    """


    ::




    """

    __swig_setmethods__ = {}
    for _s in [GenericMatrixCommon, SparsityInterfaceCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, GenDM, name, value)
    __swig_getmethods__ = {}
    for _s in [GenericMatrixCommon, SparsityInterfaceCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, GenDM, name)
    __repr__ = _swig_repr

    def nnz(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz(self) -> int

        Get the number of (structural) non-zero elements.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1an

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L84

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1298-L1300




        """
        return _casadi.GenDM_nnz(self, *args)


    def nnz_lower(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz_lower(self) -> int

        Get the number of non-zeros in the lower triangular half.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ao

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L89

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1303-L1305




        """
        return _casadi.GenDM_nnz_lower(self, *args)


    def nnz_upper(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz_upper(self) -> int

        Get the number of non-zeros in the upper triangular half.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ap

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L94

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1308-L1310




        """
        return _casadi.GenDM_nnz_upper(self, *args)


    def nnz_diag(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz_diag(self) -> int

        Get get the number of non-zeros on the diagonal.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1aq

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L99

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1313-L1315




        """
        return _casadi.GenDM_nnz_diag(self, *args)


    def numel(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          numel(self) -> int

        Get the number of elements.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ar

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L104

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1318-L1320




        """
        return _casadi.GenDM_numel(self, *args)


    def size1(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size1(self) -> int

        Get the first dimension (i.e. number of rows)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1as

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L109

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1323-L1325




        """
        return _casadi.GenDM_size1(self, *args)


    def rows(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          rows(self) -> int

        Get the number of rows, Octave-style syntax.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1at

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L114

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L114-L114




        """
        return _casadi.GenDM_rows(self, *args)


    def size2(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size2(self) -> int

        Get the second dimension (i.e. number of columns)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1au

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L119

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1328-L1330




        """
        return _casadi.GenDM_size2(self, *args)


    def columns(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          columns(self) -> int

        Get the number of columns, Octave-style syntax.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1av

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L124

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L124-L124




        """
        return _casadi.GenDM_columns(self, *args)


    def dim(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          dim(self, bool with_nz) -> str

        Get string representation of dimensions.

        The representation is e.g. "4x5" or "4x5,10nz"

        Extra doc: https://github.com/casadi/casadi/wiki/L_1aw

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L131

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1343-L1345




        """
        return _casadi.GenDM_dim(self, *args)


    def size(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size(self) -> (int,int)
          size(self, int axis) -> int

        Get the size along a particular dimensions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ay

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L141

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1338-L1340



        .......

        ::

          size(self, int axis)



        [INTERNAL] 
        Get the size along a particular dimensions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ay

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L141

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1338-L1340



        .............


        .......

        ::

          size(self)



        [INTERNAL] 
        Get the shape.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ax

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L136

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1333-L1335



        .............



        """
        return _casadi.GenDM_size(self, *args)


    def is_empty(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_empty(self, bool both) -> bool

        Check if the sparsity is empty, i.e. if one of the dimensions is
         zero.

        (or optionally both dimensions)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1az

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L148

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L148-L148




        """
        return _casadi.GenDM_is_empty(self, *args)


    def is_dense(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_dense(self) -> bool

        Check if the matrix expression is dense.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b0

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L153

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L153-L153




        """
        return _casadi.GenDM_is_dense(self, *args)


    def is_scalar(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_scalar(self, bool scalar_and_dense) -> bool

        Check if the matrix expression is scalar.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L158

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1348-L1350




        """
        return _casadi.GenDM_is_scalar(self, *args)


    def is_square(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_square(self) -> bool

        Check if the matrix expression is square.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b2

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L163

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L163-L163




        """
        return _casadi.GenDM_is_square(self, *args)


    def is_vector(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_vector(self) -> bool

        Check if the matrix is a row or column vector.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L168

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L168-L168




        """
        return _casadi.GenDM_is_vector(self, *args)


    def is_row(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_row(self) -> bool

        Check if the matrix is a row vector (i.e.  size1()==1)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L173

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L173-L173




        """
        return _casadi.GenDM_is_row(self, *args)


    def is_column(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_column(self) -> bool

        Check if the matrix is a column vector (i.e.  size2()==1)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L178

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L178-L178




        """
        return _casadi.GenDM_is_column(self, *args)


    def is_triu(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_triu(self) -> bool

        Check if the matrix is upper triangular.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b6

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L183

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L183-L183




        """
        return _casadi.GenDM_is_triu(self, *args)


    def is_tril(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_tril(self) -> bool

        Check if the matrix is lower triangular.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L188

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L188-L188




        """
        return _casadi.GenDM_is_tril(self, *args)


    def row(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          row(self) -> [int]
          row(self, int el) -> int

        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L200

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L200-L200



        .......

        ::

          row(self)



        [INTERNAL] 
        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L194

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L194-L194



        .............


        .......

        ::

          row(self, int el)



        [INTERNAL] 
        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L200

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L200-L200



        .............



        """
        return _casadi.GenDM_row(self, *args)


    def colind(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          colind(self) -> [int]
          colind(self, int col) -> int

        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L201

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L201-L201



        .......

        ::

          colind(self)



        [INTERNAL] 
        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L195

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L195-L195



        .............


        .......

        ::

          colind(self, int col)



        [INTERNAL] 
        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L201

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L201-L201



        .............



        """
        return _casadi.GenDM_colind(self, *args)


    def sparsity(self, *args) -> "casadi::Sparsity const":
        """
          [INTERNAL] 

        ::

          sparsity(self) -> Sparsity

        Get the sparsity pattern.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b9

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L207

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1293-L1295




        """
        return _casadi.GenDM_sparsity(self, *args)


    def sym(*args) -> "std::vector< std::vector< casadi::Matrix< double >,std::allocator< casadi::Matrix< double > > >,std::allocator< std::vector< casadi::Matrix< double >,std::allocator< casadi::Matrix< double > > > > >":
        """
          [INTERNAL] 

        ::

          sym(str name, int nrow, int ncol) -> DM
          sym(str name, (int,int) rc) -> DM
          sym(str name, Sparsity sp) -> DM
          sym(str name, Sparsity sp, int p) -> [DM]
          sym(str name, int nrow, int ncol, int p) -> [DM]
          sym(str name, Sparsity sp, int p, int r) -> [[DM]]
          sym(str name, int nrow, int ncol, int p, int r) -> [[DM]]

        Create a vector of length r of vectors of length p.

        with nrow-by-ncol symbolic primitives

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dg

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253-L1255



        .......

        ::

          sym(str name, (int,int) rc)



        [INTERNAL] 
        Construct a symbolic primitive with given dimensions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1db

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1213

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1213-L1215



        .............


        .......

        ::

          sym(str name, int nrow, int ncol, int p)



        [INTERNAL] 
        Create a vector of length p with nrow-by-ncol symbolic 
        primitives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1de

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1234

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1234-L1237



        .............


        .......

        ::

          sym(str name, int nrow, int ncol)



        [INTERNAL] 
        Create an nrow-by-ncol symbolic primitive.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1da

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1206

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1206-L1208



        .............


        .......

        ::

          sym(str name, Sparsity sp, int p)



        [INTERNAL] 
        Create a vector of length p with with matrices.

        with symbolic primitives of given sparsity

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dd

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1229

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1355-L1365



        .............


        .......

        ::

          sym(str name, Sparsity sp)



        [INTERNAL] 
        Create symbolic primitive with a given sparsity pattern.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dc

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1220

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1220-L1222



        .............


        .......

        ::

          sym(str name, Sparsity sp, int p, int r)



        [INTERNAL] 
        Create a vector of length r of vectors of length p with.

        symbolic primitives with given sparsity

        Extra doc: https://github.com/casadi/casadi/wiki/L_1df

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1245

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1368-L1378



        .............


        .......

        ::

          sym(str name, int nrow, int ncol, int p, int r)



        [INTERNAL] 
        Create a vector of length r of vectors of length p.

        with nrow-by-ncol symbolic primitives

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dg

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253-L1255



        .............



        """
        return _casadi.GenDM_sym(*args)

    sym = staticmethod(sym)

    def zeros(*args) -> "casadi::Matrix< double >":
        """
          [INTERNAL] 

        ::

          zeros(int nrow, int ncol) -> DM
          zeros((int,int) rc) -> DM
          zeros(Sparsity sp) -> DM

        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries zero.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266-L1268



        .......

        ::

          zeros(int nrow, int ncol)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries zero.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1262

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1262-L1264



        .............


        .......

        ::

          zeros((int,int) rc)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries zero.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266-L1268



        .............


        .......

        ::

          zeros(Sparsity sp)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries zero.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1265

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1265-L1265



        .............



        """
        return _casadi.GenDM_zeros(*args)

    zeros = staticmethod(zeros)

    def ones(*args) -> "casadi::Matrix< double >":
        """
          [INTERNAL] 

        ::

          ones(int nrow, int ncol) -> DM
          ones((int,int) rc) -> DM
          ones(Sparsity sp) -> DM

        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries one.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1di

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279-L1281



        .......

        ::

          ones(int nrow, int ncol)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries one.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1di

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1275

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1275-L1277



        .............


        .......

        ::

          ones((int,int) rc)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries one.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1di

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279-L1281



        .............


        .......

        ::

          ones(Sparsity sp)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries one.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1di

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1278

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1278-L1278



        .............



        """
        return _casadi.GenDM_ones(*args)

    ones = staticmethod(ones)

    def __init__(self, *args):
        """


        ::

          GenDM()
          GenDM(GenDM other)



        """
        this = _casadi.new_GenDM(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_GenDM
GenDM_swigregister = _casadi.GenDM_swigregister
GenDM_swigregister(GenDM)

def GenDM_sym(*args) -> "std::vector< std::vector< casadi::Matrix< double >,std::allocator< casadi::Matrix< double > > >,std::allocator< std::vector< casadi::Matrix< double >,std::allocator< casadi::Matrix< double > > > > >":
    """
      [INTERNAL] 

    ::

      sym(str name, int nrow, int ncol) -> DM
      sym(str name, (int,int) rc) -> DM
      sym(str name, Sparsity sp) -> DM
      sym(str name, Sparsity sp, int p) -> [DM]
      sym(str name, int nrow, int ncol, int p) -> [DM]
      sym(str name, Sparsity sp, int p, int r) -> [[DM]]
      sym(str name, int nrow, int ncol, int p, int r) -> [[DM]]

    Create a vector of length r of vectors of length p.

    with nrow-by-ncol symbolic primitives

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dg

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253-L1255



    .......

    ::

      sym(str name, (int,int) rc)



    [INTERNAL] 
    Construct a symbolic primitive with given dimensions.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1db

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1213

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1213-L1215



    .............


    .......

    ::

      sym(str name, int nrow, int ncol, int p)



    [INTERNAL] 
    Create a vector of length p with nrow-by-ncol symbolic 
    primitives.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1de

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1234

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1234-L1237



    .............


    .......

    ::

      sym(str name, int nrow, int ncol)



    [INTERNAL] 
    Create an nrow-by-ncol symbolic primitive.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1da

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1206

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1206-L1208



    .............


    .......

    ::

      sym(str name, Sparsity sp, int p)



    [INTERNAL] 
    Create a vector of length p with with matrices.

    with symbolic primitives of given sparsity

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dd

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1229

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1355-L1365



    .............


    .......

    ::

      sym(str name, Sparsity sp)



    [INTERNAL] 
    Create symbolic primitive with a given sparsity pattern.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dc

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1220

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1220-L1222



    .............


    .......

    ::

      sym(str name, Sparsity sp, int p, int r)



    [INTERNAL] 
    Create a vector of length r of vectors of length p with.

    symbolic primitives with given sparsity

    Extra doc: https://github.com/casadi/casadi/wiki/L_1df

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1245

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1368-L1378



    .............


    .......

    ::

      sym(str name, int nrow, int ncol, int p, int r)



    [INTERNAL] 
    Create a vector of length r of vectors of length p.

    with nrow-by-ncol symbolic primitives

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dg

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253-L1255



    .............



    """
    return _casadi.GenDM_sym(*args)

def GenDM_zeros(*args) -> "casadi::Matrix< double >":
    """
      [INTERNAL] 

    ::

      zeros(int nrow, int ncol) -> DM
      zeros((int,int) rc) -> DM
      zeros(Sparsity sp) -> DM

    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries zero.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266-L1268



    .......

    ::

      zeros(int nrow, int ncol)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries zero.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1262

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1262-L1264



    .............


    .......

    ::

      zeros((int,int) rc)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries zero.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266-L1268



    .............


    .......

    ::

      zeros(Sparsity sp)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries zero.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1265

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1265-L1265



    .............



    """
    return _casadi.GenDM_zeros(*args)

def GenDM_ones(*args) -> "casadi::Matrix< double >":
    """
      [INTERNAL] 

    ::

      ones(int nrow, int ncol) -> DM
      ones((int,int) rc) -> DM
      ones(Sparsity sp) -> DM

    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries one.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1di

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279-L1281



    .......

    ::

      ones(int nrow, int ncol)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries one.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1di

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1275

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1275-L1277



    .............


    .......

    ::

      ones((int,int) rc)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries one.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1di

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279-L1281



    .............


    .......

    ::

      ones(Sparsity sp)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries one.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1di

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1278

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1278-L1278



    .............



    """
    return _casadi.GenDM_ones(*args)

class GenSX(GenericMatrixCommon, SparsityInterfaceCommon):
    """


    ::




    """

    __swig_setmethods__ = {}
    for _s in [GenericMatrixCommon, SparsityInterfaceCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, GenSX, name, value)
    __swig_getmethods__ = {}
    for _s in [GenericMatrixCommon, SparsityInterfaceCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, GenSX, name)
    __repr__ = _swig_repr

    def nnz(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz(self) -> int

        Get the number of (structural) non-zero elements.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1an

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L84

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1298-L1300




        """
        return _casadi.GenSX_nnz(self, *args)


    def nnz_lower(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz_lower(self) -> int

        Get the number of non-zeros in the lower triangular half.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ao

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L89

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1303-L1305




        """
        return _casadi.GenSX_nnz_lower(self, *args)


    def nnz_upper(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz_upper(self) -> int

        Get the number of non-zeros in the upper triangular half.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ap

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L94

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1308-L1310




        """
        return _casadi.GenSX_nnz_upper(self, *args)


    def nnz_diag(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz_diag(self) -> int

        Get get the number of non-zeros on the diagonal.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1aq

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L99

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1313-L1315




        """
        return _casadi.GenSX_nnz_diag(self, *args)


    def numel(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          numel(self) -> int

        Get the number of elements.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ar

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L104

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1318-L1320




        """
        return _casadi.GenSX_numel(self, *args)


    def size1(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size1(self) -> int

        Get the first dimension (i.e. number of rows)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1as

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L109

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1323-L1325




        """
        return _casadi.GenSX_size1(self, *args)


    def rows(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          rows(self) -> int

        Get the number of rows, Octave-style syntax.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1at

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L114

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L114-L114




        """
        return _casadi.GenSX_rows(self, *args)


    def size2(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size2(self) -> int

        Get the second dimension (i.e. number of columns)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1au

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L119

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1328-L1330




        """
        return _casadi.GenSX_size2(self, *args)


    def columns(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          columns(self) -> int

        Get the number of columns, Octave-style syntax.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1av

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L124

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L124-L124




        """
        return _casadi.GenSX_columns(self, *args)


    def dim(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          dim(self, bool with_nz) -> str

        Get string representation of dimensions.

        The representation is e.g. "4x5" or "4x5,10nz"

        Extra doc: https://github.com/casadi/casadi/wiki/L_1aw

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L131

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1343-L1345




        """
        return _casadi.GenSX_dim(self, *args)


    def size(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size(self) -> (int,int)
          size(self, int axis) -> int

        Get the size along a particular dimensions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ay

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L141

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1338-L1340



        .......

        ::

          size(self, int axis)



        [INTERNAL] 
        Get the size along a particular dimensions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ay

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L141

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1338-L1340



        .............


        .......

        ::

          size(self)



        [INTERNAL] 
        Get the shape.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ax

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L136

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1333-L1335



        .............



        """
        return _casadi.GenSX_size(self, *args)


    def is_empty(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_empty(self, bool both) -> bool

        Check if the sparsity is empty, i.e. if one of the dimensions is
         zero.

        (or optionally both dimensions)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1az

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L148

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L148-L148




        """
        return _casadi.GenSX_is_empty(self, *args)


    def is_dense(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_dense(self) -> bool

        Check if the matrix expression is dense.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b0

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L153

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L153-L153




        """
        return _casadi.GenSX_is_dense(self, *args)


    def is_scalar(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_scalar(self, bool scalar_and_dense) -> bool

        Check if the matrix expression is scalar.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L158

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1348-L1350




        """
        return _casadi.GenSX_is_scalar(self, *args)


    def is_square(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_square(self) -> bool

        Check if the matrix expression is square.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b2

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L163

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L163-L163




        """
        return _casadi.GenSX_is_square(self, *args)


    def is_vector(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_vector(self) -> bool

        Check if the matrix is a row or column vector.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L168

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L168-L168




        """
        return _casadi.GenSX_is_vector(self, *args)


    def is_row(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_row(self) -> bool

        Check if the matrix is a row vector (i.e.  size1()==1)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L173

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L173-L173




        """
        return _casadi.GenSX_is_row(self, *args)


    def is_column(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_column(self) -> bool

        Check if the matrix is a column vector (i.e.  size2()==1)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L178

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L178-L178




        """
        return _casadi.GenSX_is_column(self, *args)


    def is_triu(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_triu(self) -> bool

        Check if the matrix is upper triangular.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b6

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L183

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L183-L183




        """
        return _casadi.GenSX_is_triu(self, *args)


    def is_tril(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_tril(self) -> bool

        Check if the matrix is lower triangular.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L188

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L188-L188




        """
        return _casadi.GenSX_is_tril(self, *args)


    def row(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          row(self) -> [int]
          row(self, int el) -> int

        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L200

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L200-L200



        .......

        ::

          row(self)



        [INTERNAL] 
        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L194

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L194-L194



        .............


        .......

        ::

          row(self, int el)



        [INTERNAL] 
        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L200

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L200-L200



        .............



        """
        return _casadi.GenSX_row(self, *args)


    def colind(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          colind(self) -> [int]
          colind(self, int col) -> int

        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L201

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L201-L201



        .......

        ::

          colind(self)



        [INTERNAL] 
        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L195

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L195-L195



        .............


        .......

        ::

          colind(self, int col)



        [INTERNAL] 
        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L201

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L201-L201



        .............



        """
        return _casadi.GenSX_colind(self, *args)


    def sparsity(self, *args) -> "casadi::Sparsity const":
        """
          [INTERNAL] 

        ::

          sparsity(self) -> Sparsity

        Get the sparsity pattern.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b9

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L207

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1293-L1295




        """
        return _casadi.GenSX_sparsity(self, *args)


    def sym(*args) -> "std::vector< std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >,std::allocator< std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > > > >":
        """
          [INTERNAL] 

        ::

          sym(str name, int nrow, int ncol) -> SX
          sym(str name, (int,int) rc) -> SX
          sym(str name, Sparsity sp) -> SX
          sym(str name, Sparsity sp, int p) -> [SX]
          sym(str name, int nrow, int ncol, int p) -> [SX]
          sym(str name, Sparsity sp, int p, int r) -> [[SX]]
          sym(str name, int nrow, int ncol, int p, int r) -> [[SX]]

        Create a vector of length r of vectors of length p.

        with nrow-by-ncol symbolic primitives

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dg

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253-L1255



        .......

        ::

          sym(str name, (int,int) rc)



        [INTERNAL] 
        Construct a symbolic primitive with given dimensions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1db

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1213

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1213-L1215



        .............


        .......

        ::

          sym(str name, int nrow, int ncol, int p)



        [INTERNAL] 
        Create a vector of length p with nrow-by-ncol symbolic 
        primitives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1de

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1234

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1234-L1237



        .............


        .......

        ::

          sym(str name, int nrow, int ncol)



        [INTERNAL] 
        Create an nrow-by-ncol symbolic primitive.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1da

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1206

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1206-L1208



        .............


        .......

        ::

          sym(str name, Sparsity sp, int p)



        [INTERNAL] 
        Create a vector of length p with with matrices.

        with symbolic primitives of given sparsity

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dd

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1229

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1355-L1365



        .............


        .......

        ::

          sym(str name, Sparsity sp)



        [INTERNAL] 
        Create symbolic primitive with a given sparsity pattern.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dc

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1220

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1220-L1222



        .............


        .......

        ::

          sym(str name, Sparsity sp, int p, int r)



        [INTERNAL] 
        Create a vector of length r of vectors of length p with.

        symbolic primitives with given sparsity

        Extra doc: https://github.com/casadi/casadi/wiki/L_1df

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1245

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1368-L1378



        .............


        .......

        ::

          sym(str name, int nrow, int ncol, int p, int r)



        [INTERNAL] 
        Create a vector of length r of vectors of length p.

        with nrow-by-ncol symbolic primitives

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dg

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253-L1255



        .............



        """
        return _casadi.GenSX_sym(*args)

    sym = staticmethod(sym)

    def zeros(*args) -> "casadi::Matrix< casadi::SXElem >":
        """
          [INTERNAL] 

        ::

          zeros(int nrow, int ncol) -> SX
          zeros((int,int) rc) -> SX
          zeros(Sparsity sp) -> SX

        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries zero.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266-L1268



        .......

        ::

          zeros(int nrow, int ncol)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries zero.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1262

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1262-L1264



        .............


        .......

        ::

          zeros((int,int) rc)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries zero.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266-L1268



        .............


        .......

        ::

          zeros(Sparsity sp)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries zero.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1265

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1265-L1265



        .............



        """
        return _casadi.GenSX_zeros(*args)

    zeros = staticmethod(zeros)

    def ones(*args) -> "casadi::Matrix< casadi::SXElem >":
        """
          [INTERNAL] 

        ::

          ones(int nrow, int ncol) -> SX
          ones((int,int) rc) -> SX
          ones(Sparsity sp) -> SX

        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries one.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1di

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279-L1281



        .......

        ::

          ones(int nrow, int ncol)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries one.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1di

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1275

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1275-L1277



        .............


        .......

        ::

          ones((int,int) rc)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries one.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1di

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279-L1281



        .............


        .......

        ::

          ones(Sparsity sp)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries one.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1di

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1278

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1278-L1278



        .............



        """
        return _casadi.GenSX_ones(*args)

    ones = staticmethod(ones)

    def __init__(self, *args):
        """


        ::

          GenSX()
          GenSX(GenSX other)



        """
        this = _casadi.new_GenSX(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_GenSX
GenSX_swigregister = _casadi.GenSX_swigregister
GenSX_swigregister(GenSX)

def GenSX_sym(*args) -> "std::vector< std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >,std::allocator< std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > > > >":
    """
      [INTERNAL] 

    ::

      sym(str name, int nrow, int ncol) -> SX
      sym(str name, (int,int) rc) -> SX
      sym(str name, Sparsity sp) -> SX
      sym(str name, Sparsity sp, int p) -> [SX]
      sym(str name, int nrow, int ncol, int p) -> [SX]
      sym(str name, Sparsity sp, int p, int r) -> [[SX]]
      sym(str name, int nrow, int ncol, int p, int r) -> [[SX]]

    Create a vector of length r of vectors of length p.

    with nrow-by-ncol symbolic primitives

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dg

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253-L1255



    .......

    ::

      sym(str name, (int,int) rc)



    [INTERNAL] 
    Construct a symbolic primitive with given dimensions.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1db

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1213

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1213-L1215



    .............


    .......

    ::

      sym(str name, int nrow, int ncol, int p)



    [INTERNAL] 
    Create a vector of length p with nrow-by-ncol symbolic 
    primitives.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1de

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1234

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1234-L1237



    .............


    .......

    ::

      sym(str name, int nrow, int ncol)



    [INTERNAL] 
    Create an nrow-by-ncol symbolic primitive.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1da

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1206

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1206-L1208



    .............


    .......

    ::

      sym(str name, Sparsity sp, int p)



    [INTERNAL] 
    Create a vector of length p with with matrices.

    with symbolic primitives of given sparsity

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dd

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1229

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1355-L1365



    .............


    .......

    ::

      sym(str name, Sparsity sp)



    [INTERNAL] 
    Create symbolic primitive with a given sparsity pattern.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dc

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1220

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1220-L1222



    .............


    .......

    ::

      sym(str name, Sparsity sp, int p, int r)



    [INTERNAL] 
    Create a vector of length r of vectors of length p with.

    symbolic primitives with given sparsity

    Extra doc: https://github.com/casadi/casadi/wiki/L_1df

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1245

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1368-L1378



    .............


    .......

    ::

      sym(str name, int nrow, int ncol, int p, int r)



    [INTERNAL] 
    Create a vector of length r of vectors of length p.

    with nrow-by-ncol symbolic primitives

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dg

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253-L1255



    .............



    """
    return _casadi.GenSX_sym(*args)

def GenSX_zeros(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      [INTERNAL] 

    ::

      zeros(int nrow, int ncol) -> SX
      zeros((int,int) rc) -> SX
      zeros(Sparsity sp) -> SX

    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries zero.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266-L1268



    .......

    ::

      zeros(int nrow, int ncol)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries zero.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1262

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1262-L1264



    .............


    .......

    ::

      zeros((int,int) rc)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries zero.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266-L1268



    .............


    .......

    ::

      zeros(Sparsity sp)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries zero.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1265

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1265-L1265



    .............



    """
    return _casadi.GenSX_zeros(*args)

def GenSX_ones(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      [INTERNAL] 

    ::

      ones(int nrow, int ncol) -> SX
      ones((int,int) rc) -> SX
      ones(Sparsity sp) -> SX

    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries one.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1di

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279-L1281



    .......

    ::

      ones(int nrow, int ncol)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries one.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1di

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1275

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1275-L1277



    .............


    .......

    ::

      ones((int,int) rc)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries one.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1di

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279-L1281



    .............


    .......

    ::

      ones(Sparsity sp)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries one.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1di

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1278

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1278-L1278



    .............



    """
    return _casadi.GenSX_ones(*args)

class GenMX(GenericMatrixCommon, SparsityInterfaceCommon):
    """


    ::




    """

    __swig_setmethods__ = {}
    for _s in [GenericMatrixCommon, SparsityInterfaceCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, GenMX, name, value)
    __swig_getmethods__ = {}
    for _s in [GenericMatrixCommon, SparsityInterfaceCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, GenMX, name)
    __repr__ = _swig_repr

    def nnz(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz(self) -> int

        Get the number of (structural) non-zero elements.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1an

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L84

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1298-L1300




        """
        return _casadi.GenMX_nnz(self, *args)


    def nnz_lower(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz_lower(self) -> int

        Get the number of non-zeros in the lower triangular half.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ao

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L89

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1303-L1305




        """
        return _casadi.GenMX_nnz_lower(self, *args)


    def nnz_upper(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz_upper(self) -> int

        Get the number of non-zeros in the upper triangular half.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ap

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L94

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1308-L1310




        """
        return _casadi.GenMX_nnz_upper(self, *args)


    def nnz_diag(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz_diag(self) -> int

        Get get the number of non-zeros on the diagonal.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1aq

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L99

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1313-L1315




        """
        return _casadi.GenMX_nnz_diag(self, *args)


    def numel(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          numel(self) -> int

        Get the number of elements.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ar

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L104

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1318-L1320




        """
        return _casadi.GenMX_numel(self, *args)


    def size1(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size1(self) -> int

        Get the first dimension (i.e. number of rows)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1as

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L109

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1323-L1325




        """
        return _casadi.GenMX_size1(self, *args)


    def rows(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          rows(self) -> int

        Get the number of rows, Octave-style syntax.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1at

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L114

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L114-L114




        """
        return _casadi.GenMX_rows(self, *args)


    def size2(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size2(self) -> int

        Get the second dimension (i.e. number of columns)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1au

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L119

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1328-L1330




        """
        return _casadi.GenMX_size2(self, *args)


    def columns(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          columns(self) -> int

        Get the number of columns, Octave-style syntax.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1av

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L124

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L124-L124




        """
        return _casadi.GenMX_columns(self, *args)


    def dim(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          dim(self, bool with_nz) -> str

        Get string representation of dimensions.

        The representation is e.g. "4x5" or "4x5,10nz"

        Extra doc: https://github.com/casadi/casadi/wiki/L_1aw

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L131

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1343-L1345




        """
        return _casadi.GenMX_dim(self, *args)


    def size(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size(self) -> (int,int)
          size(self, int axis) -> int

        Get the size along a particular dimensions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ay

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L141

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1338-L1340



        .......

        ::

          size(self, int axis)



        [INTERNAL] 
        Get the size along a particular dimensions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ay

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L141

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1338-L1340



        .............


        .......

        ::

          size(self)



        [INTERNAL] 
        Get the shape.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ax

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L136

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1333-L1335



        .............



        """
        return _casadi.GenMX_size(self, *args)


    def is_empty(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_empty(self, bool both) -> bool

        Check if the sparsity is empty, i.e. if one of the dimensions is
         zero.

        (or optionally both dimensions)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1az

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L148

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L148-L148




        """
        return _casadi.GenMX_is_empty(self, *args)


    def is_dense(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_dense(self) -> bool

        Check if the matrix expression is dense.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b0

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L153

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L153-L153




        """
        return _casadi.GenMX_is_dense(self, *args)


    def is_scalar(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_scalar(self, bool scalar_and_dense) -> bool

        Check if the matrix expression is scalar.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L158

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1348-L1350




        """
        return _casadi.GenMX_is_scalar(self, *args)


    def is_square(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_square(self) -> bool

        Check if the matrix expression is square.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b2

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L163

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L163-L163




        """
        return _casadi.GenMX_is_square(self, *args)


    def is_vector(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_vector(self) -> bool

        Check if the matrix is a row or column vector.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L168

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L168-L168




        """
        return _casadi.GenMX_is_vector(self, *args)


    def is_row(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_row(self) -> bool

        Check if the matrix is a row vector (i.e.  size1()==1)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L173

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L173-L173




        """
        return _casadi.GenMX_is_row(self, *args)


    def is_column(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_column(self) -> bool

        Check if the matrix is a column vector (i.e.  size2()==1)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L178

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L178-L178




        """
        return _casadi.GenMX_is_column(self, *args)


    def is_triu(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_triu(self) -> bool

        Check if the matrix is upper triangular.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b6

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L183

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L183-L183




        """
        return _casadi.GenMX_is_triu(self, *args)


    def is_tril(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_tril(self) -> bool

        Check if the matrix is lower triangular.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L188

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L188-L188




        """
        return _casadi.GenMX_is_tril(self, *args)


    def row(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          row(self) -> [int]
          row(self, int el) -> int

        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L200

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L200-L200



        .......

        ::

          row(self)



        [INTERNAL] 
        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L194

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L194-L194



        .............


        .......

        ::

          row(self, int el)



        [INTERNAL] 
        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L200

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L200-L200



        .............



        """
        return _casadi.GenMX_row(self, *args)


    def colind(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          colind(self) -> [int]
          colind(self, int col) -> int

        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L201

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L201-L201



        .......

        ::

          colind(self)



        [INTERNAL] 
        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L195

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L195-L195



        .............


        .......

        ::

          colind(self, int col)



        [INTERNAL] 
        Get the sparsity pattern. See the Sparsity class for details.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L201

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L201-L201



        .............



        """
        return _casadi.GenMX_colind(self, *args)


    def sparsity(self, *args) -> "casadi::Sparsity const":
        """
          [INTERNAL] 

        ::

          sparsity(self) -> Sparsity

        Get the sparsity pattern.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b9

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L207

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1293-L1295




        """
        return _casadi.GenMX_sparsity(self, *args)


    def sym(*args) -> "std::vector< std::vector< casadi::MX,std::allocator< casadi::MX > >,std::allocator< std::vector< casadi::MX,std::allocator< casadi::MX > > > >":
        """
          [INTERNAL] 

        ::

          sym(str name, int nrow, int ncol) -> MX
          sym(str name, (int,int) rc) -> MX
          sym(str name, Sparsity sp) -> MX
          sym(str name, Sparsity sp, int p) -> [MX]
          sym(str name, int nrow, int ncol, int p) -> [MX]
          sym(str name, Sparsity sp, int p, int r) -> [[MX]]
          sym(str name, int nrow, int ncol, int p, int r) -> [[MX]]

        Create a vector of length r of vectors of length p.

        with nrow-by-ncol symbolic primitives

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dg

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253-L1255



        .......

        ::

          sym(str name, (int,int) rc)



        [INTERNAL] 
        Construct a symbolic primitive with given dimensions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1db

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1213

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1213-L1215



        .............


        .......

        ::

          sym(str name, int nrow, int ncol, int p)



        [INTERNAL] 
        Create a vector of length p with nrow-by-ncol symbolic 
        primitives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1de

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1234

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1234-L1237



        .............


        .......

        ::

          sym(str name, int nrow, int ncol)



        [INTERNAL] 
        Create an nrow-by-ncol symbolic primitive.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1da

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1206

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1206-L1208



        .............


        .......

        ::

          sym(str name, Sparsity sp, int p)



        [INTERNAL] 
        Create a vector of length p with with matrices.

        with symbolic primitives of given sparsity

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dd

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1229

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1355-L1365



        .............


        .......

        ::

          sym(str name, Sparsity sp)



        [INTERNAL] 
        Create symbolic primitive with a given sparsity pattern.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dc

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1220

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1220-L1222



        .............


        .......

        ::

          sym(str name, Sparsity sp, int p, int r)



        [INTERNAL] 
        Create a vector of length r of vectors of length p with.

        symbolic primitives with given sparsity

        Extra doc: https://github.com/casadi/casadi/wiki/L_1df

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1245

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1368-L1378



        .............


        .......

        ::

          sym(str name, int nrow, int ncol, int p, int r)



        [INTERNAL] 
        Create a vector of length r of vectors of length p.

        with nrow-by-ncol symbolic primitives

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dg

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253-L1255



        .............



        """
        return _casadi.GenMX_sym(*args)

    sym = staticmethod(sym)

    def zeros(*args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          zeros(int nrow, int ncol) -> MX
          zeros((int,int) rc) -> MX
          zeros(Sparsity sp) -> MX

        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries zero.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266-L1268



        .......

        ::

          zeros(int nrow, int ncol)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries zero.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1262

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1262-L1264



        .............


        .......

        ::

          zeros((int,int) rc)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries zero.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266-L1268



        .............


        .......

        ::

          zeros(Sparsity sp)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries zero.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1265

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1265-L1265



        .............



        """
        return _casadi.GenMX_zeros(*args)

    zeros = staticmethod(zeros)

    def ones(*args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          ones(int nrow, int ncol) -> MX
          ones((int,int) rc) -> MX
          ones(Sparsity sp) -> MX

        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries one.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1di

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279-L1281



        .......

        ::

          ones(int nrow, int ncol)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries one.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1di

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1275

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1275-L1277



        .............


        .......

        ::

          ones((int,int) rc)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries one.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1di

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279-L1281



        .............


        .......

        ::

          ones(Sparsity sp)



        [INTERNAL] 
        Create a dense matrix or a matrix with specified sparsity with 
        all 
        entries one.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1di

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1278

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1278-L1278



        .............



        """
        return _casadi.GenMX_ones(*args)

    ones = staticmethod(ones)

    def __init__(self, *args):
        """


        ::

          GenMX()
          GenMX(GenMX other)



        """
        this = _casadi.new_GenMX(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_GenMX
GenMX_swigregister = _casadi.GenMX_swigregister
GenMX_swigregister(GenMX)

def GenMX_sym(*args) -> "std::vector< std::vector< casadi::MX,std::allocator< casadi::MX > >,std::allocator< std::vector< casadi::MX,std::allocator< casadi::MX > > > >":
    """
      [INTERNAL] 

    ::

      sym(str name, int nrow, int ncol) -> MX
      sym(str name, (int,int) rc) -> MX
      sym(str name, Sparsity sp) -> MX
      sym(str name, Sparsity sp, int p) -> [MX]
      sym(str name, int nrow, int ncol, int p) -> [MX]
      sym(str name, Sparsity sp, int p, int r) -> [[MX]]
      sym(str name, int nrow, int ncol, int p, int r) -> [[MX]]

    Create a vector of length r of vectors of length p.

    with nrow-by-ncol symbolic primitives

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dg

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253-L1255



    .......

    ::

      sym(str name, (int,int) rc)



    [INTERNAL] 
    Construct a symbolic primitive with given dimensions.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1db

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1213

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1213-L1215



    .............


    .......

    ::

      sym(str name, int nrow, int ncol, int p)



    [INTERNAL] 
    Create a vector of length p with nrow-by-ncol symbolic 
    primitives.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1de

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1234

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1234-L1237



    .............


    .......

    ::

      sym(str name, int nrow, int ncol)



    [INTERNAL] 
    Create an nrow-by-ncol symbolic primitive.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1da

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1206

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1206-L1208



    .............


    .......

    ::

      sym(str name, Sparsity sp, int p)



    [INTERNAL] 
    Create a vector of length p with with matrices.

    with symbolic primitives of given sparsity

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dd

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1229

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1355-L1365



    .............


    .......

    ::

      sym(str name, Sparsity sp)



    [INTERNAL] 
    Create symbolic primitive with a given sparsity pattern.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dc

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1220

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1220-L1222



    .............


    .......

    ::

      sym(str name, Sparsity sp, int p, int r)



    [INTERNAL] 
    Create a vector of length r of vectors of length p with.

    symbolic primitives with given sparsity

    Extra doc: https://github.com/casadi/casadi/wiki/L_1df

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1245

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1368-L1378



    .............


    .......

    ::

      sym(str name, int nrow, int ncol, int p, int r)



    [INTERNAL] 
    Create a vector of length r of vectors of length p.

    with nrow-by-ncol symbolic primitives

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dg

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1253-L1255



    .............



    """
    return _casadi.GenMX_sym(*args)

def GenMX_zeros(*args) -> "casadi::MX":
    """
      [INTERNAL] 

    ::

      zeros(int nrow, int ncol) -> MX
      zeros((int,int) rc) -> MX
      zeros(Sparsity sp) -> MX

    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries zero.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266-L1268



    .......

    ::

      zeros(int nrow, int ncol)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries zero.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1262

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1262-L1264



    .............


    .......

    ::

      zeros((int,int) rc)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries zero.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1266-L1268



    .............


    .......

    ::

      zeros(Sparsity sp)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries zero.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1dh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1265

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1265-L1265



    .............



    """
    return _casadi.GenMX_zeros(*args)

def GenMX_ones(*args) -> "casadi::MX":
    """
      [INTERNAL] 

    ::

      ones(int nrow, int ncol) -> MX
      ones((int,int) rc) -> MX
      ones(Sparsity sp) -> MX

    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries one.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1di

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279-L1281



    .......

    ::

      ones(int nrow, int ncol)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries one.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1di

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1275

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1275-L1277



    .............


    .......

    ::

      ones((int,int) rc)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries one.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1di

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1279-L1281



    .............


    .......

    ::

      ones(Sparsity sp)



    [INTERNAL] 
    Create a dense matrix or a matrix with specified sparsity with 
    all 
    entries one.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1di

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1278

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1278-L1278



    .............



    """
    return _casadi.GenMX_ones(*args)

class GenericExpressionCommon(_object):
    """
      [INTERNAL] 

    ::

      GenericExpressionCommon() -> 

    Expression interface.

    This is a common base class for SX,  MX and Matrix<>, introducing a uniform 
    syntax and implementing common 
    functionality using the curiously recurring 
    template pattern (CRTP) 
    idiom.
    Joel Andersson

    C++ includes: generic_expression.hpp



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, GenericExpressionCommon, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, GenericExpressionCommon, name)
    __repr__ = _swig_repr

    def __hash__(self):
      try:
        return self.element_hash()
      except:
        return SharedObject.__hash__(self)
    def __matmul__(x, y): return _casadi.mtimes(x, y)
    def __rmatmul__(x, y): return _casadi.mtimes(y, x)


    def __add__(x, y): return _casadi.plus(x, y)
    def __radd__(x, y): return _casadi.plus(y, x)
    def __sub__(x, y): return _casadi.minus(x, y)
    def __rsub__(x, y): return _casadi.minus(y, x)
    def __mul__(x, y): return _casadi.times(x, y)
    def __rmul__(x, y): return _casadi.times(y, x)
    def __div__(x, y): return _casadi.rdivide(x, y)
    def __rdiv__(x, y): return _casadi.rdivide(y, x)
    def __truediv__(x, y): return _casadi.rdivide(x, y)
    def __rtruediv__(x, y): return _casadi.rdivide(y, x)
    def __lt__(x, y): return _casadi.lt(x, y)
    def __rlt__(x, y): return _casadi.lt(y, x)
    def __le__(x, y): return _casadi.le(x, y)
    def __rle__(x, y): return _casadi.le(y, x)
    def __gt__(x, y): return _casadi.lt(y, x)
    def __rgt__(x, y): return _casadi.lt(x, y)
    def __ge__(x, y): return _casadi.le(y, x)
    def __rge__(x, y): return _casadi.le(x, y)
    def __eq__(x, y): return _casadi.eq(x, y)
    def __req__(x, y): return _casadi.eq(y, x)
    def __ne__(x, y): return _casadi.ne(x, y)
    def __rne__(x, y): return _casadi.ne(y, x)
    def __pow__(x, n): return _casadi.power(x, n)
    def __rpow__(n, x): return _casadi.power(x, n)
    def __arctan2__(x, y): return _casadi.atan2(x, y)
    def __rarctan2__(y, x): return _casadi.atan2(x, y)
    def fmin(x, y): return _casadi.fmin(x, y)
    def fmax(x, y): return _casadi.fmax(x, y)
    def __fmin__(x, y): return _casadi.fmin(x, y)
    def __rfmin__(y, x): return _casadi.fmin(x, y)
    def __fmax__(x, y): return _casadi.fmax(x, y)
    def __rfmax__(y, x): return _casadi.fmax(x, y)
    def logic_and(x, y): return _casadi.logic_and(x, y)
    def logic_or(x, y): return _casadi.logic_or(x, y)
    def fabs(x): return _casadi.fabs(x)
    def sqrt(x): return _casadi.sqrt(x)
    def sin(x): return _casadi.sin(x)
    def cos(x): return _casadi.cos(x)
    def tan(x): return _casadi.tan(x)
    def arcsin(x): return _casadi.asin(x)
    def arccos(x): return _casadi.acos(x)
    def arctan(x): return _casadi.atan(x)
    def sinh(x): return _casadi.sinh(x)
    def cosh(x): return _casadi.cosh(x)
    def tanh(x): return _casadi.tanh(x)
    def arcsinh(x): return _casadi.asinh(x)
    def arccosh(x): return _casadi.acosh(x)
    def arctanh(x): return _casadi.atanh(x)
    def exp(x): return _casadi.exp(x)
    def log(x): return _casadi.log(x)
    def log10(x): return _casadi.log10(x)
    def log1p(x): return _casadi.log1p(x)
    def expm1(x): return _casadi.expm1(x)
    def floor(x): return _casadi.floor(x)
    def ceil(x): return _casadi.ceil(x)
    def erf(x): return _casadi.erf(x)
    def sign(x): return _casadi.sign(x)
    def fmod(x, y): return _casadi.mod(x, y)
    def hypot(x, y): return _casadi.hypot(x, y)
    def remainder(x, y): return _casadi.remainder(x, y)
    def __copysign__(x, y): return _casadi.copysign(x, y)
    def __rcopysign__(y, x): return _casadi.copysign(x, y)
    def copysign(x, y): return _casadi.copysign(x, y)
    def rcopysign(y, x): return _casadi.copysign(x, y)
    def __constpow__(x, y): return _casadi.constpow(x, y)
    def __rconstpow__(y, x): return _casadi.constpow(x, y)
    def constpow(x, y): return _casadi.constpow(x, y)
    def rconstpow(y, x): return _casadi.constpow(x, y)


    def __init__(self, *args):
        """


        ::

          GenericExpressionCommon()
          GenericExpressionCommon(GenericExpressionCommon other)



        """
        this = _casadi.new_GenericExpressionCommon(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_GenericExpressionCommon
GenericExpressionCommon_swigregister = _casadi.GenericExpressionCommon_swigregister
GenericExpressionCommon_swigregister(GenericExpressionCommon)

IS_GLOBAL = _casadi.IS_GLOBAL
IS_MEMBER = _casadi.IS_MEMBER
IS_SPARSITY = _casadi.IS_SPARSITY
IS_DMATRIX = _casadi.IS_DMATRIX
IS_IMATRIX = _casadi.IS_IMATRIX
IS_SX = _casadi.IS_SX
IS_MX = _casadi.IS_MX
IS_DOUBLE = _casadi.IS_DOUBLE
class MatrixCommon(_object):
    """
      [INTERNAL] 

    ::

      MatrixCommon() -> 

    Sparse matrix class. SX and DM are specializations.

    General sparse matrix class that is designed with the idea that 

    "everything is a matrix", that is, also scalars and vectors.
    This 
    philosophy makes it easy to use and to interface in particularly
     with 
    Python and Matlab/Octave.
     Index starts with 0.
    Index vec happens as 
    follows: (rr, cc) -> k = rr+cc*size1()
    Vectors are column vectors.
     The 
    storage format is Compressed Column Storage (CCS), similar to 
    that used for
     sparse matrices in Matlab, 
    but unlike this format, we do allow for 
    elements to be structurally 
    non-zero but numerically zero.
     Matrix<Scalar> 
    is polymorphic with a std::vector<Scalar> that 
    contain all non-identical-
    zero elements.
    The sparsity can be accessed with Sparsity&  sparsity()
    Joel 
    Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_18e

    C++ includes: matrix_decl.hpp



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, MatrixCommon, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, MatrixCommon, name)
    __repr__ = _swig_repr

    def __init__(self, *args):
        """


        ::

          MatrixCommon()
          MatrixCommon(MatrixCommon other)


        .......

        ::

          MatrixCommon()



        [INTERNAL] 
        constructors

        Extra doc: https://github.com/casadi/casadi/wiki/L_18f  empty 0-by-0 matrix 
        constructor

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L106

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L576-L577



        .............


        .......

        ::

          MatrixCommon(MatrixCommon other)



        .............



        """
        this = _casadi.new_MatrixCommon(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_MatrixCommon
MatrixCommon_swigregister = _casadi.MatrixCommon_swigregister
MatrixCommon_swigregister(MatrixCommon)

class DM(MatrixCommon, GenericExpressionCommon, GenDM, PrintableCommon):
    """


    ::




    """

    __swig_setmethods__ = {}
    for _s in [MatrixCommon, GenericExpressionCommon, GenDM, PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, DM, name, value)
    __swig_getmethods__ = {}
    for _s in [MatrixCommon, GenericExpressionCommon, GenDM, PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, DM, name)
    __repr__ = _swig_repr

    def has_nz(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_nz(self, int rr, int cc) -> bool

        Returns true if the matrix has a non-zero at location rr, cc.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L226

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L65-L67




        """
        return _casadi.DM_has_nz(self, *args)


    def __bool__(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          __bool__(self) -> bool

        Returns the truth value of a  Matrix.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L229

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L70-L76




        """
        return _casadi.DM___bool__(self, *args)


    def get(self, *args) -> "void":
        """


        ::

          get(self, bool ind1, Sparsity sp) -> DM
          get(self, bool ind1, Slice rr) -> DM
          get(self, bool ind1, IM rr) -> DM
          get(self, bool ind1, Slice rr, Slice cc) -> DM
          get(self, bool ind1, Slice rr, IM cc) -> DM
          get(self, bool ind1, IM rr, Slice cc) -> DM
          get(self, bool ind1, IM rr, IM cc) -> DM



        """
        return _casadi.DM_get(self, *args)


    def set(self, *args) -> "void":
        """


        ::

          set(self, DM m, bool ind1, Sparsity sp)
          set(self, DM m, bool ind1, Slice rr)
          set(self, DM m, bool ind1, IM rr)
          set(self, DM m, bool ind1, Slice rr, Slice cc)
          set(self, DM m, bool ind1, Slice rr, IM cc)
          set(self, DM m, bool ind1, IM rr, Slice cc)
          set(self, DM m, bool ind1, IM rr, IM cc)



        """
        return _casadi.DM_set(self, *args)


    def get_nz(self, *args) -> "void":
        """


        ::

          get_nz(self, bool ind1, Slice k) -> DM
          get_nz(self, bool ind1, IM k) -> DM



        """
        return _casadi.DM_get_nz(self, *args)


    def set_nz(self, *args) -> "void":
        """


        ::

          set_nz(self, DM m, bool ind1, Slice k)
          set_nz(self, DM m, bool ind1, IM k)



        """
        return _casadi.DM_set_nz(self, *args)


    def __pos__(self, *args) -> "casadi::Matrix< double >":
        """


        ::

          __pos__(self) -> DM



        """
        return _casadi.DM___pos__(self, *args)


    def __neg__(self, *args) -> "casadi::Matrix< double >":
        """


        ::

          __neg__(self) -> DM



        """
        return _casadi.DM___neg__(self, *args)


    def binary(*args) -> "casadi::Matrix< double >":
        """


        ::

          binary(int op, DM x, DM y) -> DM



        """
        return _casadi.DM_binary(*args)

    binary = staticmethod(binary)

    def unary(*args) -> "casadi::Matrix< double >":
        """


        ::

          unary(int op, DM x) -> DM



        """
        return _casadi.DM_unary(*args)

    unary = staticmethod(unary)

    def scalar_matrix(*args) -> "casadi::Matrix< double >":
        """


        ::

          scalar_matrix(int op, DM x, DM y) -> DM



        """
        return _casadi.DM_scalar_matrix(*args)

    scalar_matrix = staticmethod(scalar_matrix)

    def matrix_scalar(*args) -> "casadi::Matrix< double >":
        """


        ::

          matrix_scalar(int op, DM x, DM y) -> DM



        """
        return _casadi.DM_matrix_scalar(*args)

    matrix_scalar = staticmethod(matrix_scalar)

    def matrix_matrix(*args) -> "casadi::Matrix< double >":
        """


        ::

          matrix_matrix(int op, DM x, DM y) -> DM



        """
        return _casadi.DM_matrix_matrix(*args)

    matrix_matrix = staticmethod(matrix_matrix)

    def call(*args) -> "std::vector< double,std::allocator< double > >":
        """


        ::

          call(Function f, [float] x) -> [float]
          call(Function f, [DM] x) -> [DM]



        """
        return _casadi.DM_call(*args)

    call = staticmethod(call)

    def printme(self, *args) -> "casadi::Matrix< double >":
        """


        ::

          printme(self, DM y) -> DM



        """
        return _casadi.DM_printme(self, *args)


    def set_max_depth(*args) -> "void":
        """


        ::

          set_max_depth(int eq_depth)



        """
        return _casadi.DM_set_max_depth(*args)

    set_max_depth = staticmethod(set_max_depth)

    def get_max_depth(*args) -> "casadi_int":
        """


        ::

          get_max_depth() -> int



        """
        return _casadi.DM_get_max_depth(*args)

    get_max_depth = staticmethod(get_max_depth)

    def get_input(*args) -> "std::vector< casadi::Matrix< double >,std::allocator< casadi::Matrix< double > > >":
        """


        ::

          get_input(Function f) -> [DM]



        """
        return _casadi.DM_get_input(*args)

    get_input = staticmethod(get_input)

    def get_free(*args) -> "std::vector< casadi::Matrix< double >,std::allocator< casadi::Matrix< double > > >":
        """


        ::

          get_free(Function f) -> [DM]



        """
        return _casadi.DM_get_free(*args)

    get_free = staticmethod(get_free)

    def type_name(*args) -> "std::string":
        """


        ::

          type_name() -> str



        """
        return _casadi.DM_type_name(*args)

    type_name = staticmethod(type_name)

    def print_split(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_split(self) -> ([str] OUTPUT, [str] OUTPUT)

        Get strings corresponding to the nonzeros and the 
        interdependencies.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L906

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L691-L695




        """
        return _casadi.DM_print_split(self, *args)


    def disp(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          disp(self, bool more)

        Print a representation of the object.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L910




        """
        return _casadi.DM_disp(self, *args)


    def str(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          str(self, bool more) -> str

        Get string representation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L913




        """
        return _casadi.DM_str(self, *args)


    def print_scalar(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_scalar(self)

        Print scalar.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L916

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L609-L628




        """
        return _casadi.DM_print_scalar(self, *args)


    def print_vector(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_vector(self, bool truncate)

        Print vector-style.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L919

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L631-L633




        """
        return _casadi.DM_print_vector(self, *args)


    def print_dense(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_dense(self, bool truncate)

        Print dense matrix-stype.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L922

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L681-L683




        """
        return _casadi.DM_print_dense(self, *args)


    def print_sparse(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_sparse(self, bool truncate)

        Print sparse matrix style.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L925

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L686-L688




        """
        return _casadi.DM_print_sparse(self, *args)


    def clear(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          clear(self)



        """
        return _casadi.DM_clear(self, *args)


    def resize(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          resize(self, int nrow, int ncol)



        """
        return _casadi.DM_resize(self, *args)


    def reserve(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          reserve(self, int nnz)
          reserve(self, int nnz, int ncol)



        """
        return _casadi.DM_reserve(self, *args)


    def erase(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          erase(self, [int] rr, bool ind1)
          erase(self, [int] rr, [int] cc, bool ind1)

        Erase a submatrix (leaving structural zeros in its place)

        Erase elements of a matrix

        Extra doc: https://github.com/casadi/casadi/wiki/L_19g

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L974



        .......

        ::

          erase(self, [int] rr, bool ind1)



        [INTERNAL] 
        Erase a submatrix (leaving structural zeros in its place)

        Erase elements of a matrix

        Extra doc: https://github.com/casadi/casadi/wiki/L_19g

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L974



        .............


        .......

        ::

          erase(self, [int] rr, [int] cc, bool ind1)



        [INTERNAL] 
        Erase a submatrix (leaving structural zeros in its place)

        Erase rows and/or columns of a matrix

        Extra doc: https://github.com/casadi/casadi/wiki/L_19f

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L966



        .............



        """
        return _casadi.DM_erase(self, *args)


    def remove(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          remove(self, [int] rr, [int] cc)

        Remove columns and rows.

        Remove/delete rows and/or columns of a matrix

        Extra doc: https://github.com/casadi/casadi/wiki/L_19h

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L981




        """
        return _casadi.DM_remove(self, *args)


    def enlarge(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          enlarge(self, int nrow, int ncol, [int] rr, [int] cc, bool ind1)

        Enlarge matrix.

        Make the matrix larger by inserting empty rows and columns, keeping 
        the 
        existing non-zeros

        Extra doc: https://github.com/casadi/casadi/wiki/L_19i

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L989




        """
        return _casadi.DM_enlarge(self, *args)


    def sparsity(self, *args) -> "casadi::Sparsity":
        """
          [INTERNAL] 

        ::

          sparsity(self) -> Sparsity

        Get an owning reference to the sparsity pattern.

        Extra doc: https://github.com/casadi/casadi/wiki/L_19j

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1016




        """
        return _casadi.DM_sparsity(self, *args)


    def get_output(self, *args) -> "casadi::Matrix< double >":
        """


        ::

          get_output(self, int oind) -> DM



        """
        return _casadi.DM_get_output(self, *args)


    def triplet(*args) -> "casadi::Matrix< double >":
        """


        ::

          triplet([int] row, [int] col, DM d) -> DM
          triplet([int] row, [int] col, DM d, (int,int) rc) -> DM
          triplet([int] row, [int] col, DM d, int nrow, int ncol) -> DM



        """
        return _casadi.DM_triplet(*args)

    triplet = staticmethod(triplet)

    def inf(*args) -> "casadi::Matrix< double >":
        """
          [INTERNAL] 

        ::

          inf(int nrow, int ncol) -> DM
          inf((int,int) rc) -> DM
          inf(Sparsity sp) -> DM

        create a matrix with all inf

        Extra doc: https://github.com/casadi/casadi/wiki/L_19k

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1047



        .......

        ::

          inf(int nrow, int ncol)



        [INTERNAL] 
        create a matrix with all inf

        Extra doc: https://github.com/casadi/casadi/wiki/L_19k

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1046



        .............


        .......

        ::

          inf((int,int) rc)



        [INTERNAL] 
        create a matrix with all inf

        Extra doc: https://github.com/casadi/casadi/wiki/L_19k

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1047



        .............


        .......

        ::

          inf(Sparsity sp)



        [INTERNAL] 
        create a matrix with all inf

        Extra doc: https://github.com/casadi/casadi/wiki/L_19k

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1045



        .............



        """
        return _casadi.DM_inf(*args)

    inf = staticmethod(inf)

    def nan(*args) -> "casadi::Matrix< double >":
        """
          [INTERNAL] 

        ::

          nan(int nrow, int ncol) -> DM
          nan((int,int) rc) -> DM
          nan(Sparsity sp) -> DM

        create a matrix with all nan

        Extra doc: https://github.com/casadi/casadi/wiki/L_19l

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1056



        .......

        ::

          nan(int nrow, int ncol)



        [INTERNAL] 
        create a matrix with all nan

        Extra doc: https://github.com/casadi/casadi/wiki/L_19l

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1055



        .............


        .......

        ::

          nan((int,int) rc)



        [INTERNAL] 
        create a matrix with all nan

        Extra doc: https://github.com/casadi/casadi/wiki/L_19l

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1056



        .............


        .......

        ::

          nan(Sparsity sp)



        [INTERNAL] 
        create a matrix with all nan

        Extra doc: https://github.com/casadi/casadi/wiki/L_19l

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1054



        .............



        """
        return _casadi.DM_nan(*args)

    nan = staticmethod(nan)

    def eye(*args) -> "casadi::Matrix< double >":
        """


        ::

          eye(int n) -> DM



        """
        return _casadi.DM_eye(*args)

    eye = staticmethod(eye)

    def element_hash(self, *args) -> "casadi_int":
        """


        ::

          element_hash(self) -> int



        """
        return _casadi.DM_element_hash(self, *args)


    def is_regular(self, *args) -> "bool":
        """


        ::

          is_regular(self) -> bool



        """
        return _casadi.DM_is_regular(self, *args)


    def is_smooth(self, *args) -> "bool":
        """


        ::

          is_smooth(self) -> bool



        """
        return _casadi.DM_is_smooth(self, *args)


    def is_leaf(self, *args) -> "bool":
        """


        ::

          is_leaf(self) -> bool



        """
        return _casadi.DM_is_leaf(self, *args)


    def is_commutative(self, *args) -> "bool":
        """


        ::

          is_commutative(self) -> bool



        """
        return _casadi.DM_is_commutative(self, *args)


    def is_symbolic(self, *args) -> "bool":
        """


        ::

          is_symbolic(self) -> bool



        """
        return _casadi.DM_is_symbolic(self, *args)


    def is_valid_input(self, *args) -> "bool":
        """


        ::

          is_valid_input(self) -> bool



        """
        return _casadi.DM_is_valid_input(self, *args)


    def has_duplicates(self, *args) -> "bool":
        """


        ::

          has_duplicates(self) -> bool



        """
        return _casadi.DM_has_duplicates(self, *args)


    def reset_input(self, *args) -> "void":
        """


        ::

          reset_input(self)



        """
        return _casadi.DM_reset_input(self, *args)


    def is_constant(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_constant(self) -> bool

        Check if the matrix is constant (note that false negative 
        answers are 
        possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_19v

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1142




        """
        return _casadi.DM_is_constant(self, *args)


    def is_call(self, *args) -> "bool":
        """


        ::

          is_call(self) -> bool



        """
        return _casadi.DM_is_call(self, *args)


    def is_output(self, *args) -> "bool":
        """


        ::

          is_output(self) -> bool



        """
        return _casadi.DM_is_output(self, *args)


    def has_output(self, *args) -> "bool":
        """


        ::

          has_output(self) -> bool



        """
        return _casadi.DM_has_output(self, *args)


    def which_output(self, *args) -> "casadi_int":
        """


        ::

          which_output(self) -> int



        """
        return _casadi.DM_which_output(self, *args)


    def which_function(self, *args) -> "casadi::Function":
        """


        ::

          which_function(self) -> Function



        """
        return _casadi.DM_which_function(self, *args)


    def is_integer(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_integer(self) -> bool

        Check if the matrix is integer-valued.

        (note that false negative answers are possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_19w

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1174




        """
        return _casadi.DM_is_integer(self, *args)


    def is_zero(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_zero(self) -> bool

        check if the matrix is 0 (note that false negative answers are 

        possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_19x

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1179




        """
        return _casadi.DM_is_zero(self, *args)


    def is_one(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_one(self) -> bool

        check if the matrix is 1 (note that false negative answers are 

        possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_19y

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1184




        """
        return _casadi.DM_is_one(self, *args)


    def is_minus_one(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_minus_one(self) -> bool

        check if the matrix is -1 (note that false negative answers are

        possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_19z

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1189




        """
        return _casadi.DM_is_minus_one(self, *args)


    def is_eye(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_eye(self) -> bool

        check if the matrix is an identity matrix (note that false 
        negative 
        answers

        are possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1a0

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1196




        """
        return _casadi.DM_is_eye(self, *args)


    def op(self, *args) -> "casadi_int":
        """


        ::

          op(self) -> int



        """
        return _casadi.DM_op(self, *args)


    def is_op(self, *args) -> "bool":
        """


        ::

          is_op(self, int op) -> bool



        """
        return _casadi.DM_is_op(self, *args)


    def has_zeros(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_zeros(self) -> bool

        Check if the matrix has any zero entries which are not 
        structural 
        zeros.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1a1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1207




        """
        return _casadi.DM_has_zeros(self, *args)


    def nonzeros(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          nonzeros(self) -> [float]

        Get all nonzeros.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1a4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1224




        """
        return _casadi.DM_nonzeros(self, *args)


    def elements(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          elements(self) -> [float]

        Get all elements.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1a3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1217




        """
        return _casadi.DM_elements(self, *args)


    def __float__(self, *args) -> "double":
        """


        ::

          __float__(self) -> float



        """
        return _casadi.DM___float__(self, *args)


    def __int__(self, *args) -> "casadi_int":
        """


        ::

          __int__(self) -> int



        """
        return _casadi.DM___int__(self, *args)


    def name(self, *args) -> "std::string":
        """


        ::

          name(self) -> str



        """
        return _casadi.DM_name(self, *args)


    def dep(self, *args) -> "casadi::Matrix< double >":
        """


        ::

          dep(self, int ch) -> DM



        """
        return _casadi.DM_dep(self, *args)


    def n_dep(self, *args) -> "casadi_int":
        """


        ::

          n_dep(self) -> int



        """
        return _casadi.DM_n_dep(self, *args)


    def set_precision(*args) -> "void":
        """


        ::

          set_precision(int precision)



        """
        return _casadi.DM_set_precision(*args)

    set_precision = staticmethod(set_precision)

    def set_width(*args) -> "void":
        """


        ::

          set_width(int width)



        """
        return _casadi.DM_set_width(*args)

    set_width = staticmethod(set_width)

    def set_scientific(*args) -> "void":
        """


        ::

          set_scientific(bool scientific)



        """
        return _casadi.DM_set_scientific(*args)

    set_scientific = staticmethod(set_scientific)

    def rng(*args) -> "void":
        """


        ::

          rng(int seed)



        """
        return _casadi.DM_rng(*args)

    rng = staticmethod(rng)

    def rand(*args) -> "casadi::Matrix< double >":
        """
          [INTERNAL] 

        ::

          rand(int nrow, int ncol) -> DM
          rand((int,int) rc) -> DM
          rand(Sparsity sp) -> DM

        Create a matrix with uniformly distributed random numbers.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1283



        .......

        ::

          rand(int nrow, int ncol)



        [INTERNAL] 
        Create a matrix with uniformly distributed random numbers.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1279



        .............


        .......

        ::

          rand((int,int) rc)



        [INTERNAL] 
        Create a matrix with uniformly distributed random numbers.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1283



        .............


        .......

        ::

          rand(Sparsity sp)



        [INTERNAL] 
        Create a matrix with uniformly distributed random numbers.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1282



        .............



        """
        return _casadi.DM_rand(*args)

    rand = staticmethod(rand)

    def export_code(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          export_code(self, str lang, dict options)

        Export matrix in specific language.

        lang: only 'matlab' supported for now

        ::

          * options:
          *   inline: Indicates if you want everything on a single line (default: False)
          *   name: Name of exported variable (default: 'm')
          *   indent_level: Level of indentation (default: 0)
          *   spoof_zero: Replace numerical zero by a 1e-200 (default: false)
          *               might be needed for matlab sparse construct,
          *               which doesn't allow numerical zero
          * 



        Extra doc: https://github.com/casadi/casadi/wiki/L_1ac

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1301




        """
        return _casadi.DM_export_code(self, *args)


    def info(self, *args) -> "casadi::Dict":
        """


        ::

          info(self) -> dict



        """
        return _casadi.DM_info(self, *args)


    def serialize(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          serialize(self) -> str
          serialize(self, casadi::SerializingStream & s)

        Serialize an object.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ah

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1331



        .......

        ::

          serialize(self, casadi::SerializingStream & s)



        [INTERNAL] 
        Serialize an object.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ah

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1331



        .............


        .......

        ::

          serialize(self)



        [INTERNAL] 
        Serialize.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ae

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1316



        .............



        """
        return _casadi.DM_serialize(self, *args)


    def deserialize(*args) -> "casadi::Matrix< double >":
        """


        ::

          deserialize(std::istream & stream) -> DM
          deserialize(casadi::DeserializingStream & s) -> DM
          deserialize(str s) -> DM



        """
        return _casadi.DM_deserialize(*args)

    deserialize = staticmethod(deserialize)

    def to_file(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          to_file(self, str filename, str format)

        Export numerical matrix to file

        Supported formats:



        ::

          *   - .mtx   Matrix Market (sparse)
          *   - .txt   Ascii full precision representation (sparse)
          *            Whitespace separated, aligned.
          *            Comments with # % or /
          *            Uses C locale
          *            Structural zeros represented by 00
          *            Does not scale well for large sparse matrices
          * 



        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1351




        """
        return _casadi.DM_to_file(self, *args)


    def from_file(*args) -> "casadi::Matrix< double >":
        """


        ::

          from_file(str filename, str format_hint) -> DM



        """
        return _casadi.DM_from_file(*args)

    from_file = staticmethod(from_file)

    def __init__(self, *args):
        """


        ::

          DM()
          DM(Sparsity sp)
          DM(float val)
          DM([[float]] m)
          DM(DM m)
          DM([SXElem] x)
          DM(SX x)
          DM(int nrow, int ncol)
          DM(Sparsity sp, DM d)



        """
        this = _casadi.new_DM(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this

    def assign(self, *args) -> "void":
        """


        ::

          assign(self, DM rhs)



        """
        return _casadi.DM_assign(self, *args)


    @property
    def shape(self):
        return (self.size1(),self.size2())

    def reshape(self,arg):
        return _casadi.reshape(self,arg)

    @property
    def T(self):
        return _casadi.transpose(self)

    def __getitem__(self, s):
          if isinstance(s, tuple) and len(s)==2:
            if s[1] is None: raise TypeError("Cannot slice with None")
            return self.get(False, s[0], s[1])
          return self.get(False, s)

    def __iter__(self):
      raise Exception("""CasADi matrices are not iterable by design.
                      Did you mean to iterate over m.nz, with m IM/DM/SX?
                      Did you mean to iterate over horzsplit(m,1)/vertsplit(m,1) with m IM/DM/SX/MX?
                      """)

    def __setitem__(self,s,val):
          if isinstance(s,tuple) and len(s)==2:
            return self.set(val, False, s[0], s[1])
          return self.set(val, False, s)

    @property
    def nz(self):
      return NZproxy(self)



    def full(self, *args) -> "PyObject *":
        """


        ::

          full(self) -> PyObject *



        """
        return _casadi.DM_full(self, *args)


    def sparse(self, *args) -> "PyObject *":
        """


        ::

          sparse(self) -> PyObject *



        """
        return _casadi.DM_sparse(self, *args)



    __array_priority__ = 999.0

    def __array_wrap__(self,out_arr,context=None):
      if context is None:
        return out_arr
      name = context[0].__name__
      args = list(context[1])

      if len(context[1])==3:
        raise Exception("Error with %s. Looks like you are using an assignment operator, such as 'a+=b' where 'a' is a numpy type. This is not supported, and cannot be supported without changing numpy." % name)

      if "vectorized" in name:
          name = name[:-len(" (vectorized)")]

      conversion = {"multiply": "mul", "divide": "div", "true_divide": "div", "subtract":"sub","power":"pow","greater_equal":"ge","less_equal": "le", "less": "lt", "greater": "gt", "equal": "eq", "not_equal": "ne"}
      if name in conversion:
        name = conversion[name]
      if len(context[1])==2 and context[1][1] is self and not(context[1][0] is self):
        name = 'r' + name
        args.reverse()
      if not(hasattr(self,name)) or ('mul' in name):
        name = '__' + name + '__'
      fun=getattr(self, name)
      return fun(*args[1:])

    def __array_ufunc__(self, ufunc, method, *inputs, **kwargs):
      conversion = {"multiply": "mul", "divide": "div", "true_divide": "div", "subtract":"sub","power":"pow","greater_equal":"ge","less_equal": "le", "less": "lt", "greater": "gt", "equal": "eq", "not_equal": "ne"}
      name = ufunc.__name__
      inputs = list(inputs)
      if len(inputs)==3:
        import warnings
        warnings.warn("Error with %s. Looks like you are using an assignment operator, such as 'a+=b' where 'a' is a numpy type. This is not supported, and cannot be supported without changing numpy." % name, RuntimeWarning)
        return NotImplemented
      if "vectorized" in name:
          name = name[:-len(" (vectorized)")]
      if name in conversion:
        name = conversion[name]
      if len(inputs)==2 and inputs[1] is self and not(inputs[0] is self):
        name = 'r' + name
        inputs.reverse()
      if not(hasattr(self,name)) or ('mul' in name):
        name = '__' + name + '__'
      if method=="reduce" and name=="add":
        assert len(inputs)==1
        axis = kwargs["axis"]
        if axis is None:
            return inputs[0].sum()
        else:
            return inputs[0].sum(axis)
      try:
        assert method=="__call__"
        fun=getattr(self, name)
        return fun(*inputs[1:])
      except Exception as e:
        if "Dimension mismatch" in str(e):
          import sys
          if sys.version_info[0] < 3:
              raise RuntimeError(str(e))
          else:
              raise e
#Fall back to numpy conversion
        new_inputs = list(inputs)
        try:
          new_inputs[0] = new_inputs[0].full()
        except:
          import warnings
          warnings.warn("Implicit conversion of symbolic CasADi type to numeric matrix not supported.\n"
                                 + "This may occur when you pass a CasADi object to a numpy function.\n"
                                 + "Use an equivalent CasADi function instead of that numpy function.", RuntimeWarning)
          return NotImplemented
        return new_inputs[0].__array_ufunc__(ufunc, method, *new_inputs, **kwargs)


    def __array__(self,*args,**kwargs):
      import numpy as n
      if len(args) > 1 and isinstance(args[1],tuple) and isinstance(args[1][0],n.ufunc) and isinstance(args[1][0],n.ufunc) and len(args[1])>1 and args[1][0].nin==len(args[1][1]):
        if len(args[1][1])==3:
          raise Exception("Error with %s. Looks like you are using an assignment operator, such as 'a+=b'. This is not supported when 'a' is a numpy type, and cannot be supported without changing numpy itself. Either upgrade a to a CasADi type first, or use 'a = a + b'. " % args[1][0].__name__)
        return n.array([n.nan])
      else:
        if hasattr(self,'__array_custom__'):
          return self.__array_custom__(*args,**kwargs)
        else:
          try:
            return self.full()
          except:
            if self.is_scalar(True):
#Needed for#2743
              E=n.empty((),dtype=object)
              E[()] = self
              return E
            else:
              raise Exception("Implicit conversion of symbolic CasADi type to numeric matrix not supported.\n"
                        + "This may occur when you pass a CasADi object to a numpy function.\n"
                        + "Use an equivalent CasADi function instead of that numpy function.")



    def __array_custom__(self,*args,**kwargs):
      if "dtype" in kwargs and not(isinstance(kwargs["dtype"],n.double)):
        return n.array(self.full(),dtype=kwargs["dtype"])
      else:
        return self.full()


    def tocsc(self):
      import numpy as np
      import warnings
      with warnings.catch_warnings():
        warnings.simplefilter("ignore")
        from scipy.sparse import csc_matrix
      return csc_matrix( (self.nonzeros(),self.row(),self.colind()), shape = self.shape, dtype=np.double )
    def toarray(self,simplify=False):
      import numpy as np
      if simplify:
        if self.is_scalar():
          return float(self)
        elif self.is_vector():
          return np.array(self.T.elements())
      return np.array(self.T.elements()).reshape(self.shape)


    def __bool__(self):
      if self.numel()!=1:
        raise Exception("Only a scalar can be cast to a float")
      if self.nnz()==0:
        return False
      return float(self)!=0


    def __abs__(self):
      return abs(float(self))


    def __setstate__(self, state):
        self.__init__(DM.deserialize(state["serialization"]))

    def __getstate__(self):
        return {"serialization": self.serialize()}

    __swig_destroy__ = _casadi.delete_DM
DM_swigregister = _casadi.DM_swigregister
DM_swigregister(DM)

def DM_binary(*args) -> "casadi::Matrix< double >":
    """


    ::

      binary(int op, DM x, DM y) -> DM



    """
    return _casadi.DM_binary(*args)

def DM_unary(*args) -> "casadi::Matrix< double >":
    """


    ::

      unary(int op, DM x) -> DM



    """
    return _casadi.DM_unary(*args)

def DM_scalar_matrix(*args) -> "casadi::Matrix< double >":
    """


    ::

      scalar_matrix(int op, DM x, DM y) -> DM



    """
    return _casadi.DM_scalar_matrix(*args)

def DM_matrix_scalar(*args) -> "casadi::Matrix< double >":
    """


    ::

      matrix_scalar(int op, DM x, DM y) -> DM



    """
    return _casadi.DM_matrix_scalar(*args)

def DM_matrix_matrix(*args) -> "casadi::Matrix< double >":
    """


    ::

      matrix_matrix(int op, DM x, DM y) -> DM



    """
    return _casadi.DM_matrix_matrix(*args)

def DM_call(*args) -> "std::vector< double,std::allocator< double > >":
    """


    ::

      call(Function f, [float] x) -> [float]
      call(Function f, [DM] x) -> [DM]



    """
    return _casadi.DM_call(*args)

def DM_set_max_depth(*args) -> "void":
    """


    ::

      set_max_depth(int eq_depth)



    """
    return _casadi.DM_set_max_depth(*args)

def DM_get_max_depth(*args) -> "casadi_int":
    """


    ::

      get_max_depth() -> int



    """
    return _casadi.DM_get_max_depth(*args)

def DM_get_input(*args) -> "std::vector< casadi::Matrix< double >,std::allocator< casadi::Matrix< double > > >":
    """


    ::

      get_input(Function f) -> [DM]



    """
    return _casadi.DM_get_input(*args)

def DM_get_free(*args) -> "std::vector< casadi::Matrix< double >,std::allocator< casadi::Matrix< double > > >":
    """


    ::

      get_free(Function f) -> [DM]



    """
    return _casadi.DM_get_free(*args)

def DM_type_name(*args) -> "std::string":
    """


    ::

      type_name() -> str



    """
    return _casadi.DM_type_name(*args)

def DM_triplet(*args) -> "casadi::Matrix< double >":
    """


    ::

      triplet([int] row, [int] col, DM d) -> DM
      triplet([int] row, [int] col, DM d, (int,int) rc) -> DM
      triplet([int] row, [int] col, DM d, int nrow, int ncol) -> DM



    """
    return _casadi.DM_triplet(*args)

def DM_inf(*args) -> "casadi::Matrix< double >":
    """
      [INTERNAL] 

    ::

      inf(int nrow, int ncol) -> DM
      inf((int,int) rc) -> DM
      inf(Sparsity sp) -> DM

    create a matrix with all inf

    Extra doc: https://github.com/casadi/casadi/wiki/L_19k

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1047



    .......

    ::

      inf(int nrow, int ncol)



    [INTERNAL] 
    create a matrix with all inf

    Extra doc: https://github.com/casadi/casadi/wiki/L_19k

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1046



    .............


    .......

    ::

      inf((int,int) rc)



    [INTERNAL] 
    create a matrix with all inf

    Extra doc: https://github.com/casadi/casadi/wiki/L_19k

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1047



    .............


    .......

    ::

      inf(Sparsity sp)



    [INTERNAL] 
    create a matrix with all inf

    Extra doc: https://github.com/casadi/casadi/wiki/L_19k

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1045



    .............



    """
    return _casadi.DM_inf(*args)

def DM_nan(*args) -> "casadi::Matrix< double >":
    """
      [INTERNAL] 

    ::

      nan(int nrow, int ncol) -> DM
      nan((int,int) rc) -> DM
      nan(Sparsity sp) -> DM

    create a matrix with all nan

    Extra doc: https://github.com/casadi/casadi/wiki/L_19l

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1056



    .......

    ::

      nan(int nrow, int ncol)



    [INTERNAL] 
    create a matrix with all nan

    Extra doc: https://github.com/casadi/casadi/wiki/L_19l

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1055



    .............


    .......

    ::

      nan((int,int) rc)



    [INTERNAL] 
    create a matrix with all nan

    Extra doc: https://github.com/casadi/casadi/wiki/L_19l

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1056



    .............


    .......

    ::

      nan(Sparsity sp)



    [INTERNAL] 
    create a matrix with all nan

    Extra doc: https://github.com/casadi/casadi/wiki/L_19l

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1054



    .............



    """
    return _casadi.DM_nan(*args)

def DM_eye(*args) -> "casadi::Matrix< double >":
    """


    ::

      eye(int n) -> DM



    """
    return _casadi.DM_eye(*args)

def DM_set_precision(*args) -> "void":
    """


    ::

      set_precision(int precision)



    """
    return _casadi.DM_set_precision(*args)

def DM_set_width(*args) -> "void":
    """


    ::

      set_width(int width)



    """
    return _casadi.DM_set_width(*args)

def DM_set_scientific(*args) -> "void":
    """


    ::

      set_scientific(bool scientific)



    """
    return _casadi.DM_set_scientific(*args)

def DM_rng(*args) -> "void":
    """


    ::

      rng(int seed)



    """
    return _casadi.DM_rng(*args)

def DM_rand(*args) -> "casadi::Matrix< double >":
    """
      [INTERNAL] 

    ::

      rand(int nrow, int ncol) -> DM
      rand((int,int) rc) -> DM
      rand(Sparsity sp) -> DM

    Create a matrix with uniformly distributed random numbers.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1283



    .......

    ::

      rand(int nrow, int ncol)



    [INTERNAL] 
    Create a matrix with uniformly distributed random numbers.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1279



    .............


    .......

    ::

      rand((int,int) rc)



    [INTERNAL] 
    Create a matrix with uniformly distributed random numbers.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1283



    .............


    .......

    ::

      rand(Sparsity sp)



    [INTERNAL] 
    Create a matrix with uniformly distributed random numbers.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1282



    .............



    """
    return _casadi.DM_rand(*args)

def DM_deserialize(*args) -> "casadi::Matrix< double >":
    """


    ::

      deserialize(std::istream & stream) -> DM
      deserialize(casadi::DeserializingStream & s) -> DM
      deserialize(str s) -> DM



    """
    return _casadi.DM_deserialize(*args)

def DM_from_file(*args) -> "casadi::Matrix< double >":
    """


    ::

      from_file(str filename, str format_hint) -> DM



    """
    return _casadi.DM_from_file(*args)

class SXElem(_object):
    """
      [INTERNAL] 

    ::

      SXElem() -> 

    The basic scalar symbolic class of CasADi.

    SXElem is exposed only as an empty struct to SWIG

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_10i

    C++ includes: sx_elem.hpp



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, SXElem, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, SXElem, name)
    __repr__ = _swig_repr

    def __init__(self, *args):
        """


        ::

          SXElem()
          SXElem(SXElem other)


        .......

        ::

          SXElem(SXElem other)



        .............


        .......

        ::

          SXElem()



        [INTERNAL] 
        Default constructor (not-a-number)

        Object is initialized as not-a-number.

        Extra doc: https://github.com/casadi/casadi/wiki/L_10j

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/sx_elem.hpp#L87

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/sx_elem.cpp#L53-L56



        .............



        """
        this = _casadi.new_SXElem(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_SXElem
SXElem_swigregister = _casadi.SXElem_swigregister
SXElem_swigregister(SXElem)



try:
  import numpy

  def constpow(x,y):
    pass

  constpow=numpy.frompyfunc(constpow,2,1)
except:
  pass

class SX(MatrixCommon, GenericExpressionCommon, GenSX, PrintableCommon):
    """


    ::




    """

    __swig_setmethods__ = {}
    for _s in [MatrixCommon, GenericExpressionCommon, GenSX, PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, SX, name, value)
    __swig_getmethods__ = {}
    for _s in [MatrixCommon, GenericExpressionCommon, GenSX, PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, SX, name)
    __repr__ = _swig_repr

    def has_nz(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_nz(self, int rr, int cc) -> bool

        Returns true if the matrix has a non-zero at location rr, cc.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L226

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L65-L67




        """
        return _casadi.SX_has_nz(self, *args)


    def __bool__(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          __bool__(self) -> bool

        Returns the truth value of a  Matrix.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L229

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L70-L76




        """
        return _casadi.SX___bool__(self, *args)


    def get(self, *args) -> "void":
        """


        ::

          get(self, bool ind1, Sparsity sp) -> SX
          get(self, bool ind1, Slice rr) -> SX
          get(self, bool ind1, IM rr) -> SX
          get(self, bool ind1, Slice rr, Slice cc) -> SX
          get(self, bool ind1, Slice rr, IM cc) -> SX
          get(self, bool ind1, IM rr, Slice cc) -> SX
          get(self, bool ind1, IM rr, IM cc) -> SX



        """
        return _casadi.SX_get(self, *args)


    def set(self, *args) -> "void":
        """


        ::

          set(self, SX m, bool ind1, Sparsity sp)
          set(self, SX m, bool ind1, Slice rr)
          set(self, SX m, bool ind1, IM rr)
          set(self, SX m, bool ind1, Slice rr, Slice cc)
          set(self, SX m, bool ind1, Slice rr, IM cc)
          set(self, SX m, bool ind1, IM rr, Slice cc)
          set(self, SX m, bool ind1, IM rr, IM cc)



        """
        return _casadi.SX_set(self, *args)


    def get_nz(self, *args) -> "void":
        """


        ::

          get_nz(self, bool ind1, Slice k) -> SX
          get_nz(self, bool ind1, IM k) -> SX



        """
        return _casadi.SX_get_nz(self, *args)


    def set_nz(self, *args) -> "void":
        """


        ::

          set_nz(self, SX m, bool ind1, Slice k)
          set_nz(self, SX m, bool ind1, IM k)



        """
        return _casadi.SX_set_nz(self, *args)


    def __pos__(self, *args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          __pos__(self) -> SX



        """
        return _casadi.SX___pos__(self, *args)


    def __neg__(self, *args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          __neg__(self) -> SX



        """
        return _casadi.SX___neg__(self, *args)


    def binary(*args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          binary(int op, SX x, SX y) -> SX



        """
        return _casadi.SX_binary(*args)

    binary = staticmethod(binary)

    def unary(*args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          unary(int op, SX x) -> SX



        """
        return _casadi.SX_unary(*args)

    unary = staticmethod(unary)

    def scalar_matrix(*args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          scalar_matrix(int op, SX x, SX y) -> SX



        """
        return _casadi.SX_scalar_matrix(*args)

    scalar_matrix = staticmethod(scalar_matrix)

    def matrix_scalar(*args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          matrix_scalar(int op, SX x, SX y) -> SX



        """
        return _casadi.SX_matrix_scalar(*args)

    matrix_scalar = staticmethod(matrix_scalar)

    def matrix_matrix(*args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          matrix_matrix(int op, SX x, SX y) -> SX



        """
        return _casadi.SX_matrix_matrix(*args)

    matrix_matrix = staticmethod(matrix_matrix)

    def call(*args) -> "std::vector< casadi::SXElem,std::allocator< casadi::SXElem > >":
        """


        ::

          call(Function f, [SX] x) -> [SX]
          call(Function f, [SXElem] x) -> [SXElem]



        """
        return _casadi.SX_call(*args)

    call = staticmethod(call)

    def printme(self, *args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          printme(self, SX y) -> SX



        """
        return _casadi.SX_printme(self, *args)


    def set_max_depth(*args) -> "void":
        """


        ::

          set_max_depth(int eq_depth)



        """
        return _casadi.SX_set_max_depth(*args)

    set_max_depth = staticmethod(set_max_depth)

    def get_max_depth(*args) -> "casadi_int":
        """


        ::

          get_max_depth() -> int



        """
        return _casadi.SX_get_max_depth(*args)

    get_max_depth = staticmethod(get_max_depth)

    def get_input(*args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
        """


        ::

          get_input(Function f) -> [SX]



        """
        return _casadi.SX_get_input(*args)

    get_input = staticmethod(get_input)

    def get_free(*args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
        """


        ::

          get_free(Function f) -> [SX]



        """
        return _casadi.SX_get_free(*args)

    get_free = staticmethod(get_free)

    def type_name(*args) -> "std::string":
        """


        ::

          type_name() -> str



        """
        return _casadi.SX_type_name(*args)

    type_name = staticmethod(type_name)

    def print_split(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_split(self) -> ([str] OUTPUT, [str] OUTPUT)

        Get strings corresponding to the nonzeros and the 
        interdependencies.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L906

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L691-L695




        """
        return _casadi.SX_print_split(self, *args)


    def disp(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          disp(self, bool more)

        Print a representation of the object.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L910




        """
        return _casadi.SX_disp(self, *args)


    def str(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          str(self, bool more) -> str

        Get string representation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L913




        """
        return _casadi.SX_str(self, *args)


    def print_scalar(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_scalar(self)

        Print scalar.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L916

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L609-L628




        """
        return _casadi.SX_print_scalar(self, *args)


    def print_vector(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_vector(self, bool truncate)

        Print vector-style.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L919

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L631-L633




        """
        return _casadi.SX_print_vector(self, *args)


    def print_dense(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_dense(self, bool truncate)

        Print dense matrix-stype.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L922

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L681-L683




        """
        return _casadi.SX_print_dense(self, *args)


    def print_sparse(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_sparse(self, bool truncate)

        Print sparse matrix style.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L925

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_impl.hpp#L686-L688




        """
        return _casadi.SX_print_sparse(self, *args)


    def clear(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          clear(self)



        """
        return _casadi.SX_clear(self, *args)


    def resize(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          resize(self, int nrow, int ncol)



        """
        return _casadi.SX_resize(self, *args)


    def reserve(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          reserve(self, int nnz)
          reserve(self, int nnz, int ncol)



        """
        return _casadi.SX_reserve(self, *args)


    def erase(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          erase(self, [int] rr, bool ind1)
          erase(self, [int] rr, [int] cc, bool ind1)

        Erase a submatrix (leaving structural zeros in its place)

        Erase elements of a matrix

        Extra doc: https://github.com/casadi/casadi/wiki/L_19g

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L974



        .......

        ::

          erase(self, [int] rr, bool ind1)



        [INTERNAL] 
        Erase a submatrix (leaving structural zeros in its place)

        Erase elements of a matrix

        Extra doc: https://github.com/casadi/casadi/wiki/L_19g

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L974



        .............


        .......

        ::

          erase(self, [int] rr, [int] cc, bool ind1)



        [INTERNAL] 
        Erase a submatrix (leaving structural zeros in its place)

        Erase rows and/or columns of a matrix

        Extra doc: https://github.com/casadi/casadi/wiki/L_19f

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L966



        .............



        """
        return _casadi.SX_erase(self, *args)


    def remove(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          remove(self, [int] rr, [int] cc)

        Remove columns and rows.

        Remove/delete rows and/or columns of a matrix

        Extra doc: https://github.com/casadi/casadi/wiki/L_19h

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L981




        """
        return _casadi.SX_remove(self, *args)


    def enlarge(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          enlarge(self, int nrow, int ncol, [int] rr, [int] cc, bool ind1)

        Enlarge matrix.

        Make the matrix larger by inserting empty rows and columns, keeping 
        the 
        existing non-zeros

        Extra doc: https://github.com/casadi/casadi/wiki/L_19i

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L989




        """
        return _casadi.SX_enlarge(self, *args)


    def sparsity(self, *args) -> "casadi::Sparsity":
        """
          [INTERNAL] 

        ::

          sparsity(self) -> Sparsity

        Get an owning reference to the sparsity pattern.

        Extra doc: https://github.com/casadi/casadi/wiki/L_19j

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1016




        """
        return _casadi.SX_sparsity(self, *args)


    def get_output(self, *args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          get_output(self, int oind) -> SX



        """
        return _casadi.SX_get_output(self, *args)


    def triplet(*args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          triplet([int] row, [int] col, SX d) -> SX
          triplet([int] row, [int] col, SX d, (int,int) rc) -> SX
          triplet([int] row, [int] col, SX d, int nrow, int ncol) -> SX



        """
        return _casadi.SX_triplet(*args)

    triplet = staticmethod(triplet)

    def inf(*args) -> "casadi::Matrix< casadi::SXElem >":
        """
          [INTERNAL] 

        ::

          inf(int nrow, int ncol) -> SX
          inf((int,int) rc) -> SX
          inf(Sparsity sp) -> SX

        create a matrix with all inf

        Extra doc: https://github.com/casadi/casadi/wiki/L_19k

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1047



        .......

        ::

          inf(int nrow, int ncol)



        [INTERNAL] 
        create a matrix with all inf

        Extra doc: https://github.com/casadi/casadi/wiki/L_19k

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1046



        .............


        .......

        ::

          inf((int,int) rc)



        [INTERNAL] 
        create a matrix with all inf

        Extra doc: https://github.com/casadi/casadi/wiki/L_19k

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1047



        .............


        .......

        ::

          inf(Sparsity sp)



        [INTERNAL] 
        create a matrix with all inf

        Extra doc: https://github.com/casadi/casadi/wiki/L_19k

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1045



        .............



        """
        return _casadi.SX_inf(*args)

    inf = staticmethod(inf)

    def nan(*args) -> "casadi::Matrix< casadi::SXElem >":
        """
          [INTERNAL] 

        ::

          nan(int nrow, int ncol) -> SX
          nan((int,int) rc) -> SX
          nan(Sparsity sp) -> SX

        create a matrix with all nan

        Extra doc: https://github.com/casadi/casadi/wiki/L_19l

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1056



        .......

        ::

          nan(int nrow, int ncol)



        [INTERNAL] 
        create a matrix with all nan

        Extra doc: https://github.com/casadi/casadi/wiki/L_19l

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1055



        .............


        .......

        ::

          nan((int,int) rc)



        [INTERNAL] 
        create a matrix with all nan

        Extra doc: https://github.com/casadi/casadi/wiki/L_19l

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1056



        .............


        .......

        ::

          nan(Sparsity sp)



        [INTERNAL] 
        create a matrix with all nan

        Extra doc: https://github.com/casadi/casadi/wiki/L_19l

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1054



        .............



        """
        return _casadi.SX_nan(*args)

    nan = staticmethod(nan)

    def eye(*args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          eye(int n) -> SX



        """
        return _casadi.SX_eye(*args)

    eye = staticmethod(eye)

    def element_hash(self, *args) -> "casadi_int":
        """


        ::

          element_hash(self) -> int



        """
        return _casadi.SX_element_hash(self, *args)


    def is_regular(self, *args) -> "bool":
        """


        ::

          is_regular(self) -> bool



        """
        return _casadi.SX_is_regular(self, *args)


    def is_smooth(self, *args) -> "bool":
        """


        ::

          is_smooth(self) -> bool



        """
        return _casadi.SX_is_smooth(self, *args)


    def is_leaf(self, *args) -> "bool":
        """


        ::

          is_leaf(self) -> bool



        """
        return _casadi.SX_is_leaf(self, *args)


    def is_commutative(self, *args) -> "bool":
        """


        ::

          is_commutative(self) -> bool



        """
        return _casadi.SX_is_commutative(self, *args)


    def is_symbolic(self, *args) -> "bool":
        """


        ::

          is_symbolic(self) -> bool



        """
        return _casadi.SX_is_symbolic(self, *args)


    def is_valid_input(self, *args) -> "bool":
        """


        ::

          is_valid_input(self) -> bool



        """
        return _casadi.SX_is_valid_input(self, *args)


    def has_duplicates(self, *args) -> "bool":
        """


        ::

          has_duplicates(self) -> bool



        """
        return _casadi.SX_has_duplicates(self, *args)


    def reset_input(self, *args) -> "void":
        """


        ::

          reset_input(self)



        """
        return _casadi.SX_reset_input(self, *args)


    def is_constant(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_constant(self) -> bool

        Check if the matrix is constant (note that false negative 
        answers are 
        possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_19v

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1142




        """
        return _casadi.SX_is_constant(self, *args)


    def is_call(self, *args) -> "bool":
        """


        ::

          is_call(self) -> bool



        """
        return _casadi.SX_is_call(self, *args)


    def is_output(self, *args) -> "bool":
        """


        ::

          is_output(self) -> bool



        """
        return _casadi.SX_is_output(self, *args)


    def has_output(self, *args) -> "bool":
        """


        ::

          has_output(self) -> bool



        """
        return _casadi.SX_has_output(self, *args)


    def which_output(self, *args) -> "casadi_int":
        """


        ::

          which_output(self) -> int



        """
        return _casadi.SX_which_output(self, *args)


    def which_function(self, *args) -> "casadi::Function":
        """


        ::

          which_function(self) -> Function



        """
        return _casadi.SX_which_function(self, *args)


    def is_integer(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_integer(self) -> bool

        Check if the matrix is integer-valued.

        (note that false negative answers are possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_19w

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1174




        """
        return _casadi.SX_is_integer(self, *args)


    def is_zero(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_zero(self) -> bool

        check if the matrix is 0 (note that false negative answers are 

        possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_19x

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1179




        """
        return _casadi.SX_is_zero(self, *args)


    def is_one(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_one(self) -> bool

        check if the matrix is 1 (note that false negative answers are 

        possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_19y

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1184




        """
        return _casadi.SX_is_one(self, *args)


    def is_minus_one(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_minus_one(self) -> bool

        check if the matrix is -1 (note that false negative answers are

        possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_19z

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1189




        """
        return _casadi.SX_is_minus_one(self, *args)


    def is_eye(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_eye(self) -> bool

        check if the matrix is an identity matrix (note that false 
        negative 
        answers

        are possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1a0

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1196




        """
        return _casadi.SX_is_eye(self, *args)


    def op(self, *args) -> "casadi_int":
        """


        ::

          op(self) -> int



        """
        return _casadi.SX_op(self, *args)


    def is_op(self, *args) -> "bool":
        """


        ::

          is_op(self, int op) -> bool



        """
        return _casadi.SX_is_op(self, *args)


    def has_zeros(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_zeros(self) -> bool

        Check if the matrix has any zero entries which are not 
        structural 
        zeros.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1a1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1207




        """
        return _casadi.SX_has_zeros(self, *args)


    def nonzeros(self, *args) -> "std::vector< casadi::SXElem,std::allocator< casadi::SXElem > >":
        """
          [INTERNAL] 

        ::

          nonzeros(self) -> [SXElem]

        Get all nonzeros.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1a4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1224




        """
        return _casadi.SX_nonzeros(self, *args)


    def elements(self, *args) -> "std::vector< casadi::SXElem,std::allocator< casadi::SXElem > >":
        """
          [INTERNAL] 

        ::

          elements(self) -> [SXElem]

        Get all elements.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1a3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1217




        """
        return _casadi.SX_elements(self, *args)


    def __float__(self, *args) -> "double":
        """


        ::

          __float__(self) -> float



        """
        return _casadi.SX___float__(self, *args)


    def __int__(self, *args) -> "casadi_int":
        """


        ::

          __int__(self) -> int



        """
        return _casadi.SX___int__(self, *args)


    def name(self, *args) -> "std::string":
        """


        ::

          name(self) -> str



        """
        return _casadi.SX_name(self, *args)


    def dep(self, *args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          dep(self, int ch) -> SX



        """
        return _casadi.SX_dep(self, *args)


    def n_dep(self, *args) -> "casadi_int":
        """


        ::

          n_dep(self) -> int



        """
        return _casadi.SX_n_dep(self, *args)


    def set_precision(*args) -> "void":
        """


        ::

          set_precision(int precision)



        """
        return _casadi.SX_set_precision(*args)

    set_precision = staticmethod(set_precision)

    def set_width(*args) -> "void":
        """


        ::

          set_width(int width)



        """
        return _casadi.SX_set_width(*args)

    set_width = staticmethod(set_width)

    def set_scientific(*args) -> "void":
        """


        ::

          set_scientific(bool scientific)



        """
        return _casadi.SX_set_scientific(*args)

    set_scientific = staticmethod(set_scientific)

    def rng(*args) -> "void":
        """


        ::

          rng(int seed)



        """
        return _casadi.SX_rng(*args)

    rng = staticmethod(rng)

    def rand(*args) -> "casadi::Matrix< casadi::SXElem >":
        """
          [INTERNAL] 

        ::

          rand(int nrow, int ncol) -> SX
          rand((int,int) rc) -> SX
          rand(Sparsity sp) -> SX

        Create a matrix with uniformly distributed random numbers.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1283



        .......

        ::

          rand(int nrow, int ncol)



        [INTERNAL] 
        Create a matrix with uniformly distributed random numbers.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1279



        .............


        .......

        ::

          rand((int,int) rc)



        [INTERNAL] 
        Create a matrix with uniformly distributed random numbers.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1283



        .............


        .......

        ::

          rand(Sparsity sp)



        [INTERNAL] 
        Create a matrix with uniformly distributed random numbers.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1282



        .............



        """
        return _casadi.SX_rand(*args)

    rand = staticmethod(rand)

    def export_code(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          export_code(self, str lang, dict options)

        Export matrix in specific language.

        lang: only 'matlab' supported for now

        ::

          * options:
          *   inline: Indicates if you want everything on a single line (default: False)
          *   name: Name of exported variable (default: 'm')
          *   indent_level: Level of indentation (default: 0)
          *   spoof_zero: Replace numerical zero by a 1e-200 (default: false)
          *               might be needed for matlab sparse construct,
          *               which doesn't allow numerical zero
          * 



        Extra doc: https://github.com/casadi/casadi/wiki/L_1ac

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1301




        """
        return _casadi.SX_export_code(self, *args)


    def info(self, *args) -> "casadi::Dict":
        """


        ::

          info(self) -> dict



        """
        return _casadi.SX_info(self, *args)


    def serialize(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          serialize(self) -> str
          serialize(self, casadi::SerializingStream & s)

        Serialize an object.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ah

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1331



        .......

        ::

          serialize(self, casadi::SerializingStream & s)



        [INTERNAL] 
        Serialize an object.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ah

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1331



        .............


        .......

        ::

          serialize(self)



        [INTERNAL] 
        Serialize.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ae

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1316



        .............



        """
        return _casadi.SX_serialize(self, *args)


    def deserialize(*args) -> "casadi::Matrix< casadi::SXElem >":
        """


        ::

          deserialize(std::istream & stream) -> SX
          deserialize(casadi::DeserializingStream & s) -> SX
          deserialize(str s) -> SX



        """
        return _casadi.SX_deserialize(*args)

    deserialize = staticmethod(deserialize)

    def to_file(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          to_file(self, str filename, str format)

        Export numerical matrix to file

        Supported formats:



        ::

          *   - .mtx   Matrix Market (sparse)
          *   - .txt   Ascii full precision representation (sparse)
          *            Whitespace separated, aligned.
          *            Comments with # % or /
          *            Uses C locale
          *            Structural zeros represented by 00
          *            Does not scale well for large sparse matrices
          * 



        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1351




        """
        return _casadi.SX_to_file(self, *args)


    def from_file(*args) -> "casadi::Matrix< double >":
        """


        ::

          from_file(str filename, str format_hint) -> DM



        """
        return _casadi.SX_from_file(*args)

    from_file = staticmethod(from_file)

    def __setstate__(self, state):
      ctx = _current_unpickle_context()
      if not ctx:
        raise Exception("Cannot unpickle SX objects without a casadi context. " +
          "Use something like:\n"+
          "with ca.global_unpickle_context(): \n"+
          "  f_ref = pickle.load(open(filename,'rb'))")
      ctx.decode(state)
      self.__init__(ctx.unpack())

    def __getstate__(self):
      ctx = _current_pickle_context()
      if not ctx:
        raise Exception("Cannot pickle SX objects without a casadi context. " +
          "Use something like:\n"+
          "with ca.global_pickle_context(): \n"+
          "  pickle.dump(f,open(filename,'wb'))")
      ctx.pack(self)
      return ctx.encode()


    @property
    def shape(self):
        return (self.size1(),self.size2())

    def reshape(self,arg):
        return _casadi.reshape(self,arg)

    @property
    def T(self):
        return _casadi.transpose(self)

    def __getitem__(self, s):
          if isinstance(s, tuple) and len(s)==2:
            if s[1] is None: raise TypeError("Cannot slice with None")
            return self.get(False, s[0], s[1])
          return self.get(False, s)

    def __iter__(self):
      raise Exception("""CasADi matrices are not iterable by design.
                      Did you mean to iterate over m.nz, with m IM/DM/SX?
                      Did you mean to iterate over horzsplit(m,1)/vertsplit(m,1) with m IM/DM/SX/MX?
                      """)

    def __setitem__(self,s,val):
          if isinstance(s,tuple) and len(s)==2:
            return self.set(val, False, s[0], s[1])
          return self.set(val, False, s)

    @property
    def nz(self):
      return NZproxy(self)




    __array_priority__ = 1001.0

    def __array_wrap__(self,out_arr,context=None):
      if context is None:
        return out_arr
      name = context[0].__name__
      args = list(context[1])

      if len(context[1])==3:
        raise Exception("Error with %s. Looks like you are using an assignment operator, such as 'a+=b' where 'a' is a numpy type. This is not supported, and cannot be supported without changing numpy." % name)

      if "vectorized" in name:
          name = name[:-len(" (vectorized)")]

      conversion = {"multiply": "mul", "divide": "div", "true_divide": "div", "subtract":"sub","power":"pow","greater_equal":"ge","less_equal": "le", "less": "lt", "greater": "gt", "equal": "eq", "not_equal": "ne"}
      if name in conversion:
        name = conversion[name]
      if len(context[1])==2 and context[1][1] is self and not(context[1][0] is self):
        name = 'r' + name
        args.reverse()
      if not(hasattr(self,name)) or ('mul' in name):
        name = '__' + name + '__'
      fun=getattr(self, name)
      return fun(*args[1:])

    def __array_ufunc__(self, ufunc, method, *inputs, **kwargs):
      conversion = {"multiply": "mul", "divide": "div", "true_divide": "div", "subtract":"sub","power":"pow","greater_equal":"ge","less_equal": "le", "less": "lt", "greater": "gt", "equal": "eq", "not_equal": "ne"}
      name = ufunc.__name__
      inputs = list(inputs)
      if len(inputs)==3:
        import warnings
        warnings.warn("Error with %s. Looks like you are using an assignment operator, such as 'a+=b' where 'a' is a numpy type. This is not supported, and cannot be supported without changing numpy." % name, RuntimeWarning)
        return NotImplemented
      if "vectorized" in name:
          name = name[:-len(" (vectorized)")]
      if name in conversion:
        name = conversion[name]
      if len(inputs)==2 and inputs[1] is self and not(inputs[0] is self):
        name = 'r' + name
        inputs.reverse()
      if not(hasattr(self,name)) or ('mul' in name):
        name = '__' + name + '__'
      if method=="reduce" and name=="add":
        assert len(inputs)==1
        axis = kwargs["axis"]
        if axis is None:
            return inputs[0].sum()
        else:
            return inputs[0].sum(axis)
      try:
        assert method=="__call__"
        fun=getattr(self, name)
        return fun(*inputs[1:])
      except Exception as e:
        if "Dimension mismatch" in str(e):
          import sys
          if sys.version_info[0] < 3:
              raise RuntimeError(str(e))
          else:
              raise e
#Fall back to numpy conversion
        new_inputs = list(inputs)
        try:
          new_inputs[0] = new_inputs[0].full()
        except:
          import warnings
          warnings.warn("Implicit conversion of symbolic CasADi type to numeric matrix not supported.\n"
                                 + "This may occur when you pass a CasADi object to a numpy function.\n"
                                 + "Use an equivalent CasADi function instead of that numpy function.", RuntimeWarning)
          return NotImplemented
        return new_inputs[0].__array_ufunc__(ufunc, method, *new_inputs, **kwargs)


    def __array__(self,*args,**kwargs):
      import numpy as n
      if len(args) > 1 and isinstance(args[1],tuple) and isinstance(args[1][0],n.ufunc) and isinstance(args[1][0],n.ufunc) and len(args[1])>1 and args[1][0].nin==len(args[1][1]):
        if len(args[1][1])==3:
          raise Exception("Error with %s. Looks like you are using an assignment operator, such as 'a+=b'. This is not supported when 'a' is a numpy type, and cannot be supported without changing numpy itself. Either upgrade a to a CasADi type first, or use 'a = a + b'. " % args[1][0].__name__)
        return n.array([n.nan])
      else:
        if hasattr(self,'__array_custom__'):
          return self.__array_custom__(*args,**kwargs)
        else:
          try:
            return self.full()
          except:
            if self.is_scalar(True):
#Needed for#2743
              E=n.empty((),dtype=object)
              E[()] = self
              return E
            else:
              raise Exception("Implicit conversion of symbolic CasADi type to numeric matrix not supported.\n"
                        + "This may occur when you pass a CasADi object to a numpy function.\n"
                        + "Use an equivalent CasADi function instead of that numpy function.")



    def __init__(self, *args):
        """


        ::

          SX()
          SX(Sparsity sp)
          SX(float val)
          SX([[float]] m)
          SX([float] x)
          SX(DM x)
          SX(SX m)
          SX(int nrow, int ncol)
          SX(Sparsity sp, SX d)



        """
        this = _casadi.new_SX(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_SX
SX_swigregister = _casadi.SX_swigregister
SX_swigregister(SX)

def SX_binary(*args) -> "casadi::Matrix< casadi::SXElem >":
    """


    ::

      binary(int op, SX x, SX y) -> SX



    """
    return _casadi.SX_binary(*args)

def SX_unary(*args) -> "casadi::Matrix< casadi::SXElem >":
    """


    ::

      unary(int op, SX x) -> SX



    """
    return _casadi.SX_unary(*args)

def SX_scalar_matrix(*args) -> "casadi::Matrix< casadi::SXElem >":
    """


    ::

      scalar_matrix(int op, SX x, SX y) -> SX



    """
    return _casadi.SX_scalar_matrix(*args)

def SX_matrix_scalar(*args) -> "casadi::Matrix< casadi::SXElem >":
    """


    ::

      matrix_scalar(int op, SX x, SX y) -> SX



    """
    return _casadi.SX_matrix_scalar(*args)

def SX_matrix_matrix(*args) -> "casadi::Matrix< casadi::SXElem >":
    """


    ::

      matrix_matrix(int op, SX x, SX y) -> SX



    """
    return _casadi.SX_matrix_matrix(*args)

def SX_call(*args) -> "std::vector< casadi::SXElem,std::allocator< casadi::SXElem > >":
    """


    ::

      call(Function f, [SX] x) -> [SX]
      call(Function f, [SXElem] x) -> [SXElem]



    """
    return _casadi.SX_call(*args)

def SX_set_max_depth(*args) -> "void":
    """


    ::

      set_max_depth(int eq_depth)



    """
    return _casadi.SX_set_max_depth(*args)

def SX_get_max_depth(*args) -> "casadi_int":
    """


    ::

      get_max_depth() -> int



    """
    return _casadi.SX_get_max_depth(*args)

def SX_get_input(*args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
    """


    ::

      get_input(Function f) -> [SX]



    """
    return _casadi.SX_get_input(*args)

def SX_get_free(*args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
    """


    ::

      get_free(Function f) -> [SX]



    """
    return _casadi.SX_get_free(*args)

def SX_type_name(*args) -> "std::string":
    """


    ::

      type_name() -> str



    """
    return _casadi.SX_type_name(*args)

def SX_triplet(*args) -> "casadi::Matrix< casadi::SXElem >":
    """


    ::

      triplet([int] row, [int] col, SX d) -> SX
      triplet([int] row, [int] col, SX d, (int,int) rc) -> SX
      triplet([int] row, [int] col, SX d, int nrow, int ncol) -> SX



    """
    return _casadi.SX_triplet(*args)

def SX_inf(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      [INTERNAL] 

    ::

      inf(int nrow, int ncol) -> SX
      inf((int,int) rc) -> SX
      inf(Sparsity sp) -> SX

    create a matrix with all inf

    Extra doc: https://github.com/casadi/casadi/wiki/L_19k

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1047



    .......

    ::

      inf(int nrow, int ncol)



    [INTERNAL] 
    create a matrix with all inf

    Extra doc: https://github.com/casadi/casadi/wiki/L_19k

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1046



    .............


    .......

    ::

      inf((int,int) rc)



    [INTERNAL] 
    create a matrix with all inf

    Extra doc: https://github.com/casadi/casadi/wiki/L_19k

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1047



    .............


    .......

    ::

      inf(Sparsity sp)



    [INTERNAL] 
    create a matrix with all inf

    Extra doc: https://github.com/casadi/casadi/wiki/L_19k

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1045



    .............



    """
    return _casadi.SX_inf(*args)

def SX_nan(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      [INTERNAL] 

    ::

      nan(int nrow, int ncol) -> SX
      nan((int,int) rc) -> SX
      nan(Sparsity sp) -> SX

    create a matrix with all nan

    Extra doc: https://github.com/casadi/casadi/wiki/L_19l

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1056



    .......

    ::

      nan(int nrow, int ncol)



    [INTERNAL] 
    create a matrix with all nan

    Extra doc: https://github.com/casadi/casadi/wiki/L_19l

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1055



    .............


    .......

    ::

      nan((int,int) rc)



    [INTERNAL] 
    create a matrix with all nan

    Extra doc: https://github.com/casadi/casadi/wiki/L_19l

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1056



    .............


    .......

    ::

      nan(Sparsity sp)



    [INTERNAL] 
    create a matrix with all nan

    Extra doc: https://github.com/casadi/casadi/wiki/L_19l

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1054



    .............



    """
    return _casadi.SX_nan(*args)

def SX_eye(*args) -> "casadi::Matrix< casadi::SXElem >":
    """


    ::

      eye(int n) -> SX



    """
    return _casadi.SX_eye(*args)

def SX_set_precision(*args) -> "void":
    """


    ::

      set_precision(int precision)



    """
    return _casadi.SX_set_precision(*args)

def SX_set_width(*args) -> "void":
    """


    ::

      set_width(int width)



    """
    return _casadi.SX_set_width(*args)

def SX_set_scientific(*args) -> "void":
    """


    ::

      set_scientific(bool scientific)



    """
    return _casadi.SX_set_scientific(*args)

def SX_rng(*args) -> "void":
    """


    ::

      rng(int seed)



    """
    return _casadi.SX_rng(*args)

def SX_rand(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      [INTERNAL] 

    ::

      rand(int nrow, int ncol) -> SX
      rand((int,int) rc) -> SX
      rand(Sparsity sp) -> SX

    Create a matrix with uniformly distributed random numbers.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1283



    .......

    ::

      rand(int nrow, int ncol)



    [INTERNAL] 
    Create a matrix with uniformly distributed random numbers.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1279



    .............


    .......

    ::

      rand((int,int) rc)



    [INTERNAL] 
    Create a matrix with uniformly distributed random numbers.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1283



    .............


    .......

    ::

      rand(Sparsity sp)



    [INTERNAL] 
    Create a matrix with uniformly distributed random numbers.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ab

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L1282



    .............



    """
    return _casadi.SX_rand(*args)

def SX_deserialize(*args) -> "casadi::Matrix< casadi::SXElem >":
    """


    ::

      deserialize(std::istream & stream) -> SX
      deserialize(casadi::DeserializingStream & s) -> SX
      deserialize(str s) -> SX



    """
    return _casadi.SX_deserialize(*args)

def SX_from_file(*args) -> "casadi::Matrix< double >":
    """


    ::

      from_file(str filename, str format_hint) -> DM



    """
    return _casadi.SX_from_file(*args)

class MX(GenericExpressionCommon, PrintableCommon, GenMX, SharedObject):
    """
      [INTERNAL] 

    ::


     MX -  Matrix expression.

    The  MX class is used to build up trees made up from MXNodes. It is a more 

    general graph representation than the scalar expression, SX, and much 
    less 
    efficient for small objects. On the other hand, the class allows 
    much more 
    general operations than does SX, in particular matrix valued
     operations and
     calls to arbitrary differentiable functions.

    The  MX class is designed to have identical syntax with the Matrix<> 
    template
     class, and uses DM (i.e.  Matrix<double>) as its internal 
    representation of the values at a node. By keeping 
    the syntaxes identical, 
    it is possible to switch from one class to the
     other, as well as inlining  
    MX functions to  SXElem functions.

    Note that an operation is always "lazy", making a matrix 
    multiplication 
    will create a matrix multiplication node, not perform 
    the actual 
    multiplication.

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_py

    C++ includes: mx.hpp



    """

    __swig_setmethods__ = {}
    for _s in [GenericExpressionCommon, PrintableCommon, GenMX, SharedObject]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, MX, name, value)
    __swig_getmethods__ = {}
    for _s in [GenericExpressionCommon, PrintableCommon, GenMX, SharedObject]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, MX, name)
    __repr__ = _swig_repr

    def type_name(*args) -> "std::string":
        """


        ::

          type_name() -> str



        """
        return _casadi.MX_type_name(*args)

    type_name = staticmethod(type_name)
    __swig_destroy__ = _casadi.delete_MX

    def __bool__(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          __bool__(self) -> bool

        Returns the truth value of an  MX expression.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L200

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L143-L145



        """
        return _casadi.MX___bool__(self, *args)


    def sparsity(self, *args) -> "casadi::Sparsity":
        """
          [INTERNAL] 

        ::

          sparsity(self) -> Sparsity

        Get an owning reference to the sparsity pattern.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qd

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L205

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L205-L205



        """
        return _casadi.MX_sparsity(self, *args)


    def nonzeros(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          nonzeros(self) -> [MX]

        Get nonzeros as list of scalar MXes.

        Since  MX is not a containter, the scalar MXes may be complex When the 

        expression satisfies is_valid_input, the results may be simple

        For example: vertcat(x,y).nonzeros() will return {x,y}

        See: 
        expr.nz[:]

        Extra doc: https://github.com/casadi/casadi/wiki/L_2bh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L220

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L610-L626



        """
        return _casadi.MX_nonzeros(self, *args)


    def erase(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          erase(self, [int] rr, bool ind1)
          erase(self, [int] rr, [int] cc, bool ind1)

        Erase a submatrix (leaving structural zeros in its place)

        Erase elements of a matrix

        Extra doc: https://github.com/casadi/casadi/wiki/L_qf

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L235

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L628-L640


        .......

        ::

          erase(self, [int] rr, bool ind1)



        [INTERNAL] 
        Erase a submatrix (leaving structural zeros in its place)

        Erase elements of a matrix

        Extra doc: https://github.com/casadi/casadi/wiki/L_qf

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L235

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L628-L640


        .............


        .......

        ::

          erase(self, [int] rr, [int] cc, bool ind1)



        [INTERNAL] 
        Erase a submatrix (leaving structural zeros in its place)

        Erase rows and/or columns of a matrix

        Extra doc: https://github.com/casadi/casadi/wiki/L_qe

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L227

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L596-L608


        .............



        """
        return _casadi.MX_erase(self, *args)


    def enlarge(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          enlarge(self, int nrow, int ncol, [int] rr, [int] cc, bool ind1)

        Enlarge matrix.

        Make the matrix larger by inserting empty rows and columns, keeping 
        the 
        existing non-zeros

        Extra doc: https://github.com/casadi/casadi/wiki/L_qg

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L242

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L642-L650



        """
        return _casadi.MX_enlarge(self, *args)


    def __neg__(self, *args) -> "casadi::MX":
        """


        ::

          __neg__(self) -> MX



        """
        return _casadi.MX___neg__(self, *args)


    def dep(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          dep(self, int ch) -> MX

        Get the nth dependency as  MX.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qj

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L267

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L754-L756



        """
        return _casadi.MX_dep(self, *args)


    def n_out(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          n_out(self) -> int

        Number of outputs.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qk

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L272

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L869-L871



        """
        return _casadi.MX_n_out(self, *args)


    def get_output(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          get_output(self, int oind) -> MX

        Get an output.

        Extra doc: https://github.com/casadi/casadi/wiki/L_ql

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L277

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L873-L875



        """
        return _casadi.MX_get_output(self, *args)


    def n_dep(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          n_dep(self) -> int

        Get the number of dependencies of a binary  SXElem.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qm

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L282

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L758-L760



        """
        return _casadi.MX_n_dep(self, *args)


    def name(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          name(self) -> str

        Get the name.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L285

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L762-L764



        """
        return _casadi.MX_name(self, *args)


    def __float__(self, *args) -> "double":
        """


        ::

          __float__(self) -> float



        """
        return _casadi.MX___float__(self, *args)


    def to_DM(self, *args) -> "casadi::Matrix< double >":
        """


        ::

          to_DM(self) -> DM



        """
        return _casadi.MX_to_DM(self, *args)


    def is_symbolic(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_symbolic(self) -> bool

        Check if symbolic.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L294

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L766-L768



        """
        return _casadi.MX_is_symbolic(self, *args)


    def is_constant(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_constant(self) -> bool

        Check if constant.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L297

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L770-L772



        """
        return _casadi.MX_is_constant(self, *args)


    def is_call(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_call(self) -> bool

        Check if evaluation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L300

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L774-L776



        """
        return _casadi.MX_is_call(self, *args)


    def which_function(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          which_function(self) -> Function

        Get function - only valid when  is_call() is true.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L303

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L778-L780



        """
        return _casadi.MX_which_function(self, *args)


    def is_output(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_output(self) -> bool

        Check if evaluation output.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L306

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L782-L784



        """
        return _casadi.MX_is_output(self, *args)


    def has_output(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_output(self) -> bool

        Check if a multiple output node.

        Extra doc: https://github.com/casadi/casadi/wiki/L_284

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L311

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L786-L788



        """
        return _casadi.MX_has_output(self, *args)


    def which_output(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          which_output(self) -> int

        Get the index of evaluation output - only valid when  
        is_output() is true.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L314

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L790-L792



        """
        return _casadi.MX_which_output(self, *args)


    def is_op(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_op(self, int op) -> bool

        Is it a certain operation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L317

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L794-L796



        """
        return _casadi.MX_is_op(self, *args)


    def is_multiplication(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_multiplication(self) -> bool

        Check if multiplication.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L320

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L798-L800



        """
        return _casadi.MX_is_multiplication(self, *args)


    def is_commutative(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_commutative(self) -> bool

        Check if commutative operation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L323

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L850-L855



        """
        return _casadi.MX_is_commutative(self, *args)


    def is_norm(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_norm(self) -> bool

        Check if norm.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L326

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L802-L804



        """
        return _casadi.MX_is_norm(self, *args)


    def is_valid_input(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_valid_input(self) -> bool

        Check if matrix can be used to define function inputs.

        Valid inputs for MXFunctions are combinations of Reshape, 
        concatenations 
        and SymbolicMX

        Extra doc: https://github.com/casadi/casadi/wiki/L_qn

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L333

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L925-L927



        """
        return _casadi.MX_is_valid_input(self, *args)


    def n_primitives(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          n_primitives(self) -> int

        Get the number of primitives for MXFunction inputs/outputs.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qo

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L338

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L929-L931



        """
        return _casadi.MX_n_primitives(self, *args)


    def primitives(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          primitives(self) -> [MX]

        Get primitives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qp

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L343

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L933-L939



        """
        return _casadi.MX_primitives(self, *args)


    def split_primitives(self, *args) -> "std::vector< casadi::DM,std::allocator< casadi::DM > >":
        """
          [INTERNAL] 

        ::

          split_primitives(self, DM x) -> [DM]
          split_primitives(self, SX x) -> [SX]
          split_primitives(self, MX x) -> [MX]

        Split up an expression along symbolic primitives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qq

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L351

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L957-L963


        .......

        ::

          split_primitives(self, DM x)



        [INTERNAL] 
        Split up an expression along symbolic primitives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qq

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L351

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L957-L963


        .............


        .......

        ::

          split_primitives(self, SX x)



        [INTERNAL] 
        Split up an expression along symbolic primitives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qq

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L350

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L949-L955


        .............


        .......

        ::

          split_primitives(self, MX x)



        [INTERNAL] 
        Split up an expression along symbolic primitives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qq

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L349

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L941-L947


        .............



        """
        return _casadi.MX_split_primitives(self, *args)


    def join_primitives(self, *args) -> "casadi::DM":
        """
          [INTERNAL] 

        ::

          join_primitives(self, [DM] v) -> DM
          join_primitives(self, [SX] v) -> SX
          join_primitives(self, [MX] v) -> MX

        Join an expression along symbolic primitives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qr

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L360

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L981-L987


        .......

        ::

          join_primitives(self, [DM] v)



        [INTERNAL] 
        Join an expression along symbolic primitives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qr

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L360

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L981-L987


        .............


        .......

        ::

          join_primitives(self, [SX] v)



        [INTERNAL] 
        Join an expression along symbolic primitives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qr

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L359

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L973-L979


        .............


        .......

        ::

          join_primitives(self, [MX] v)



        [INTERNAL] 
        Join an expression along symbolic primitives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qr

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L358

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L965-L971


        .............



        """
        return _casadi.MX_join_primitives(self, *args)


    def has_duplicates(self, *args) -> "bool":
        """


        ::

          has_duplicates(self) -> bool



        """
        return _casadi.MX_has_duplicates(self, *args)


    def reset_input(self, *args) -> "void":
        """


        ::

          reset_input(self)



        """
        return _casadi.MX_reset_input(self, *args)


    def is_eye(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_eye(self) -> bool

        check if identity

        Extra doc: https://github.com/casadi/casadi/wiki/L_qu

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L383

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L997-L999



        """
        return _casadi.MX_is_eye(self, *args)


    def is_zero(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_zero(self) -> bool

        check if zero (note that false negative answers are possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_qv

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L388

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L1001-L1007



        """
        return _casadi.MX_is_zero(self, *args)


    def is_one(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_one(self) -> bool

        check if zero (note that false negative answers are possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_qw

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L393

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L1009-L1011



        """
        return _casadi.MX_is_one(self, *args)


    def is_minus_one(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_minus_one(self) -> bool

        check if zero (note that false negative answers are possible)

        Extra doc: https://github.com/casadi/casadi/wiki/L_qx

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L398

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L1013-L1015



        """
        return _casadi.MX_is_minus_one(self, *args)


    def is_transpose(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_transpose(self) -> bool

        Is the expression a transpose?

        Extra doc: https://github.com/casadi/casadi/wiki/L_qy

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L403

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L1017-L1019



        """
        return _casadi.MX_is_transpose(self, *args)


    def is_regular(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_regular(self) -> bool

        Checks if expression does not contain NaN or Inf.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L406

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L1021-L1027



        """
        return _casadi.MX_is_regular(self, *args)


    def is_binary(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_binary(self) -> bool

        Is binary operation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L409

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L814-L816



        """
        return _casadi.MX_is_binary(self, *args)


    def is_unary(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_unary(self) -> bool

        Is unary operation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L412

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L818-L820



        """
        return _casadi.MX_is_unary(self, *args)


    def op(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          op(self) -> int

        Get operation type.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L415

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L822-L824



        """
        return _casadi.MX_op(self, *args)


    def info(self, *args) -> "casadi::Dict":
        """
          [INTERNAL] 

        ::

          info(self) -> dict

        Obtain information about node

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L418

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L826-L828



        """
        return _casadi.MX_info(self, *args)


    def serialize(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          serialize(self, casadi::SerializingStream & s)

        Serialize an object.

        Extra doc: https://github.com/casadi/casadi/wiki/L_qz

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L423

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L830-L832



        """
        return _casadi.MX_serialize(self, *args)


    def deserialize(*args) -> "casadi::MX":
        """


        ::

          deserialize(casadi::DeserializingStream & s) -> MX



        """
        return _casadi.MX_deserialize(*args)

    deserialize = staticmethod(deserialize)

    def get_temp(self, *args) -> "casadi_int":
        """


        ::

          get_temp(self) -> int



        """
        return _casadi.MX_get_temp(self, *args)


    def set_temp(self, *args) -> "void":
        """


        ::

          set_temp(self, int t)



        """
        return _casadi.MX_set_temp(self, *args)


    def binary(*args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          binary(int op, MX x, MX y) -> MX

        Create nodes by their ID.

        Extra doc: https://github.com/casadi/casadi/wiki/L_r1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L442

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L513-L538



        """
        return _casadi.MX_binary(*args)

    binary = staticmethod(binary)

    def unary(*args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          unary(int op, MX x) -> MX

        Create nodes by their ID.

        Extra doc: https://github.com/casadi/casadi/wiki/L_r1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L443

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L540-L542



        """
        return _casadi.MX_unary(*args)

    unary = staticmethod(unary)

    def inf(*args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          inf(int nrow, int ncol) -> MX
          inf((int,int) rc) -> MX
          inf(Sparsity sp) -> MX

        create a matrix with all inf

        Extra doc: https://github.com/casadi/casadi/wiki/L_r2

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L452

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L560-L562


        .......

        ::

          inf(int nrow, int ncol)



        [INTERNAL] 
        create a matrix with all inf

        Extra doc: https://github.com/casadi/casadi/wiki/L_r2

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L451

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L556-L558


        .............


        .......

        ::

          inf((int,int) rc)



        [INTERNAL] 
        create a matrix with all inf

        Extra doc: https://github.com/casadi/casadi/wiki/L_r2

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L452

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L560-L562


        .............


        .......

        ::

          inf(Sparsity sp)



        [INTERNAL] 
        create a matrix with all inf

        Extra doc: https://github.com/casadi/casadi/wiki/L_r2

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L450

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L564-L566


        .............



        """
        return _casadi.MX_inf(*args)

    inf = staticmethod(inf)

    def nan(*args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          nan(int nrow, int ncol) -> MX
          nan((int,int) rc) -> MX
          nan(Sparsity sp) -> MX

        create a matrix with all nan

        Extra doc: https://github.com/casadi/casadi/wiki/L_r3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L461

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L572-L574


        .......

        ::

          nan(int nrow, int ncol)



        [INTERNAL] 
        create a matrix with all nan

        Extra doc: https://github.com/casadi/casadi/wiki/L_r3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L460

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L568-L570


        .............


        .......

        ::

          nan((int,int) rc)



        [INTERNAL] 
        create a matrix with all nan

        Extra doc: https://github.com/casadi/casadi/wiki/L_r3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L461

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L572-L574


        .............


        .......

        ::

          nan(Sparsity sp)



        [INTERNAL] 
        create a matrix with all nan

        Extra doc: https://github.com/casadi/casadi/wiki/L_r3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L459

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L576-L578


        .............



        """
        return _casadi.MX_nan(*args)

    nan = staticmethod(nan)

    def eye(*args) -> "casadi::MX":
        """


        ::

          eye(int n) -> MX



        """
        return _casadi.MX_eye(*args)

    eye = staticmethod(eye)

    def get(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          get(self, bool ind1, int rr) -> MX
          get(self, bool ind1, Sparsity sp) -> MX
          get(self, bool ind1, Slice rr) -> MX
          get(self, bool ind1, IM rr) -> MX
          get(self, bool ind1, MX rr) -> MX
          get(self, bool ind1, int rr, int cc) -> MX
          get(self, bool ind1, int rr, Slice cc) -> MX
          get(self, bool ind1, Slice rr, int cc) -> MX
          get(self, bool ind1, Slice rr, Slice cc) -> MX
          get(self, bool ind1, Slice rr, IM cc) -> MX
          get(self, bool ind1, Slice rr, MX cc) -> MX
          get(self, bool ind1, IM rr, Slice cc) -> MX
          get(self, bool ind1, IM rr, IM cc) -> MX
          get(self, bool ind1, MX rr, Slice cc) -> MX
          get(self, bool ind1, MX rr, MX cc) -> MX

        Get a submatrix, two arguments

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L504

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L224-L227


        .......

        ::

          get(self, bool ind1, IM rr)
          get(self, bool ind1, Slice rr, IM cc)
          get(self, bool ind1, IM rr, Slice cc)
          get(self, bool ind1, IM rr, IM cc)



        .............


        .......

        ::

          get(self, bool ind1, int rr)



        [INTERNAL] 
        Get a submatrix, single argument

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L480

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L480-L482


        .............


        .......

        ::

          get(self, bool ind1, Sparsity sp)



        [INTERNAL] 
        Get a submatrix, single argument

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L478

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L200-L206


        .............


        .......

        ::

          get(self, bool ind1, Slice rr)



        [INTERNAL] 
        Get a submatrix, single argument

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L476

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L177-L180


        .............


        .......

        ::

          get(self, bool ind1, MX rr)



        [INTERNAL] 
        Get a submatrix, single argument

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L479

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L208-L212


        .............


        .......

        ::

          get(self, bool ind1, int rr, int cc)



        [INTERNAL] 
        Get a submatrix, two arguments

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L498

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L498-L501


        .............


        .......

        ::

          get(self, bool ind1, int rr, Slice cc)



        [INTERNAL] 
        Get a submatrix, two arguments

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L493

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L493-L495


        .............


        .......

        ::

          get(self, bool ind1, Slice rr, int cc)



        [INTERNAL] 
        Get a submatrix, two arguments

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L489

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L489-L491


        .............


        .......

        ::

          get(self, bool ind1, Slice rr, Slice cc)



        [INTERNAL] 
        Get a submatrix, two arguments

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L487

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L147-L150


        .............


        .......

        ::

          get(self, bool ind1, Slice rr, MX cc)



        [INTERNAL] 
        Get a submatrix, two arguments

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L503

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L214-L217


        .............


        .......

        ::

          get(self, bool ind1, MX rr, Slice cc)



        [INTERNAL] 
        Get a submatrix, two arguments

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L502

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L219-L222


        .............


        .......

        ::

          get(self, bool ind1, MX rr, MX cc)



        [INTERNAL] 
        Get a submatrix, two arguments

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L504

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L224-L227


        .............



        """
        return _casadi.MX_get(self, *args)


    def set(self, *args) -> "void":
        """


        ::

          set(self, MX m, bool ind1, Sparsity sp)
          set(self, MX m, bool ind1, Slice rr)
          set(self, MX m, bool ind1, IM rr)
          set(self, MX m, bool ind1, Slice rr, Slice cc)
          set(self, MX m, bool ind1, Slice rr, IM cc)
          set(self, MX m, bool ind1, IM rr, Slice cc)
          set(self, MX m, bool ind1, IM rr, IM cc)


        .......

        ::

          set(self, MX m, bool ind1, IM rr)
          set(self, MX m, bool ind1, Slice rr, IM cc)
          set(self, MX m, bool ind1, IM rr, Slice cc)
          set(self, MX m, bool ind1, IM rr, IM cc)



        .............


        .......

        ::

          set(self, MX m, bool ind1, Sparsity sp)



        [INTERNAL] 
        Set a submatrix, single argument

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L511

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L377-L388


        .............


        .......

        ::

          set(self, MX m, bool ind1, Slice rr)



        [INTERNAL] 
        Set a submatrix, single argument

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L509

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L304-L307


        .............


        .......

        ::

          set(self, MX m, bool ind1, Slice rr, Slice cc)



        [INTERNAL] 
        Set a submatrix, two arguments

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L516

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L229-L232


        .............



        """
        return _casadi.MX_set(self, *args)


    def get_nz(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          get_nz(self, bool ind1, int kk) -> MX
          get_nz(self, bool ind1, Slice kk) -> MX
          get_nz(self, bool ind1, IM kk) -> MX
          get_nz(self, bool ind1, MX kk) -> MX
          get_nz(self, bool ind1, Slice inner, MX outer) -> MX
          get_nz(self, bool ind1, MX inner, Slice outer) -> MX
          get_nz(self, bool ind1, MX inner, MX outer) -> MX

        Get a set of nonzeros

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L532

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L433-L436


        .......

        ::

          get_nz(self, bool ind1, IM kk)



        .............


        .......

        ::

          get_nz(self, bool ind1, int kk)



        [INTERNAL] 
        Get a set of nonzeros

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L527

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L527-L529


        .............


        .......

        ::

          get_nz(self, bool ind1, Slice kk)



        [INTERNAL] 
        Get a set of nonzeros

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L524

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L390-L393


        .............


        .......

        ::

          get_nz(self, bool ind1, MX kk)



        [INTERNAL] 
        Get a set of nonzeros

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L526

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L428-L431


        .............


        .......

        ::

          get_nz(self, bool ind1, Slice inner, MX outer)



        [INTERNAL] 
        Get a set of nonzeros

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L531

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L438-L441


        .............


        .......

        ::

          get_nz(self, bool ind1, MX inner, Slice outer)



        [INTERNAL] 
        Get a set of nonzeros

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L530

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L443-L446


        .............


        .......

        ::

          get_nz(self, bool ind1, MX inner, MX outer)



        [INTERNAL] 
        Get a set of nonzeros

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L532

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L433-L436


        .............



        """
        return _casadi.MX_get_nz(self, *args)


    def set_nz(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_nz(self, MX m, bool ind1, int kk)
          set_nz(self, MX m, bool ind1, Slice kk)
          set_nz(self, MX m, bool ind1, IM kk)
          set_nz(self, MX m, bool ind1, MX kk)

        Set a set of nonzeros

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L540

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L540-L540


        .......

        ::

          set_nz(self, MX m, bool ind1, IM kk)



        .............


        .......

        ::

          set_nz(self, MX m, bool ind1, int kk)



        [INTERNAL] 
        Set a set of nonzeros

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L540

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L540-L540


        .............


        .......

        ::

          set_nz(self, MX m, bool ind1, Slice kk)



        [INTERNAL] 
        Set a set of nonzeros

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L537

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L448-L451


        .............


        .......

        ::

          set_nz(self, MX m, bool ind1, MX kk)



        [INTERNAL] 
        Set a set of nonzeros

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L539

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L509-L511


        .............



        """
        return _casadi.MX_set_nz(self, *args)


    def einstein(*args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          einstein(MX A, MX B, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c) -> MX
          einstein(MX A, MX B, MX C, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c) -> MX

        Computes an einstein dense tensor contraction.

        Computes the product: C_c = A_a + B_b where a b c are index/einstein 

        notation in an encoded form

        For example, an matrix-matrix product may be written as: C_ij = A_ik 
        B_kj

        The encoded form uses strictly negative numbers to indicate labels. 
        For the
         above example, we would have: a {-1, -3} b {-3, -2} c {-1 -2}

        Extra doc: https://github.com/casadi/casadi/wiki/L_r5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L564

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L670-L676


        .......

        ::

          einstein(MX A, MX B, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c)



        [INTERNAL] 
        Computes an einstein dense tensor contraction.

        Computes the product: C_c = A_a + B_b where a b c are index/einstein 

        notation in an encoded form

        For example, an matrix-matrix product may be written as: C_ij = A_ik 
        B_kj

        The encoded form uses strictly negative numbers to indicate labels. 
        For the
         above example, we would have: a {-1, -3} b {-3, -2} c {-1 -2}

        Extra doc: https://github.com/casadi/casadi/wiki/L_r5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L564

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L670-L676


        .............


        .......

        ::

          einstein(MX A, MX B, MX C, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c)



        [INTERNAL] 
        Computes an einstein dense tensor contraction.

        Computes the product: C_c = A_a + B_b where a b c are index/einstein 

        notation in an encoded form

        For example, an matrix-matrix product may be written as: C_ij = A_ik 
        B_kj

        The encoded form uses strictly negative numbers to indicate labels. 
        For the
         above example, we would have: a {-1, -3} b {-3, -2} c {-1 -2}

        Extra doc: https://github.com/casadi/casadi/wiki/L_r5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L558

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L662-L668


        .............



        """
        return _casadi.MX_einstein(*args)

    einstein = staticmethod(einstein)

    def bspline_dual(*args) -> "casadi::DM":
        """
          [INTERNAL] 

        ::

          bspline_dual([float] x, [[float]] knots, [int] degree, dict opts) -> DM



        """
        return _casadi.MX_bspline_dual(*args)

    bspline_dual = staticmethod(bspline_dual)

    def interpn_linear(*args) -> "casadi::MX":
        """


        ::

          interpn_linear([MX] x, MX v, [MX] xq, dict opts) -> MX



        """
        return _casadi.MX_interpn_linear(*args)

    interpn_linear = staticmethod(interpn_linear)

    def printme(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          printme(self, MX b) -> MX



        """
        return _casadi.MX_printme(self, *args)


    def attachAssert(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          attachAssert(self, MX y, str fail_message) -> MX

        returns itself, but with an assertion attached

        If y does not evaluate to 1, a runtime error is raised

        Extra doc: https://github.com/casadi/casadi/wiki/L_rg

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L923

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L723-L728



        """
        return _casadi.MX_attachAssert(self, *args)


    def monitor(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          monitor(self, str comment) -> MX

        Monitor an expression.

        Returns itself, but with the side effect of printing the nonzeros 
        along 
        with a comment

        Extra doc: https://github.com/casadi/casadi/wiki/L_rh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L930

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L730-L732



        """
        return _casadi.MX_monitor(self, *args)


    def mapping(self, *args) -> "casadi::Matrix< casadi_int >":
        """
          [INTERNAL] 

        ::

          mapping(self) -> IM

        Get an IM representation of a GetNonzeros or SetNonzeros node.

        Extra doc: https://github.com/casadi/casadi/wiki/L_ri

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L938

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L857-L859



        """
        return _casadi.MX_mapping(self, *args)


    def set_max_depth(*args) -> "void":
        """


        ::

          set_max_depth(int eq_depth)



        """
        return _casadi.MX_set_max_depth(*args)

    set_max_depth = staticmethod(set_max_depth)

    def get_max_depth(*args) -> "casadi_int":
        """


        ::

          get_max_depth() -> int



        """
        return _casadi.MX_get_max_depth(*args)

    get_max_depth = staticmethod(get_max_depth)

    def test_cast(*args) -> "bool":
        """


        ::

          test_cast(casadi::SharedObjectInternal const * ptr) -> bool



        """
        return _casadi.MX_test_cast(*args)

    test_cast = staticmethod(test_cast)

    def get_input(*args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """


        ::

          get_input(Function f) -> [MX]



        """
        return _casadi.MX_get_input(*args)

    get_input = staticmethod(get_input)

    def get_free(*args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """


        ::

          get_free(Function f) -> [MX]



        """
        return _casadi.MX_get_free(*args)

    get_free = staticmethod(get_free)

    def eval_mx(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          eval_mx(self, [MX] arg) -> [MX]

        Evaluate the  MX node with new symbolic dependencies.

        Extra doc: https://github.com/casadi/casadi/wiki/L_rn

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L969

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L2736-L2743



        """
        return _casadi.MX_eval_mx(self, *args)


    def __setstate__(self, state):
      ctx = _current_unpickle_context()
      if not ctx:
        raise Exception("Cannot unpickle MX objects without a casadi context. " +
          "Use something like:\n"+
          "with ca.global_unpickle_context(): \n"+
          "  f_ref = pickle.load(open(filename,'rb'))")
      ctx.decode(state)
      self.__init__(ctx.unpack())

    def __getstate__(self):
      ctx = _current_pickle_context()
      if not ctx:
        raise Exception("Cannot pickle MX objects without a casadi context. " +
          "Use something like:\n"+
          "with ca.global_pickle_context(): \n"+
          "  pickle.dump(f,open(filename,'wb'))")
      ctx.pack(self)
      return ctx.encode()


    @property
    def shape(self):
        return (self.size1(),self.size2())

    def reshape(self,arg):
        return _casadi.reshape(self,arg)

    @property
    def T(self):
        return _casadi.transpose(self)

    def __getitem__(self, s):
          if isinstance(s, tuple) and len(s)==2:
            if s[1] is None: raise TypeError("Cannot slice with None")
            return self.get(False, s[0], s[1])
          return self.get(False, s)

    def __iter__(self):
      raise Exception("""CasADi matrices are not iterable by design.
                      Did you mean to iterate over m.nz, with m IM/DM/SX?
                      Did you mean to iterate over horzsplit(m,1)/vertsplit(m,1) with m IM/DM/SX/MX?
                      """)

    def __setitem__(self,s,val):
          if isinstance(s,tuple) and len(s)==2:
            return self.set(val, False, s[0], s[1])
          return self.set(val, False, s)

    @property
    def nz(self):
      return NZproxy(self)




    __array_priority__ = 1002.0

    def __array_wrap__(self,out_arr,context=None):
      if context is None:
        return out_arr
      name = context[0].__name__
      args = list(context[1])

      if len(context[1])==3:
        raise Exception("Error with %s. Looks like you are using an assignment operator, such as 'a+=b' where 'a' is a numpy type. This is not supported, and cannot be supported without changing numpy." % name)

      if "vectorized" in name:
          name = name[:-len(" (vectorized)")]

      conversion = {"multiply": "mul", "divide": "div", "true_divide": "div", "subtract":"sub","power":"pow","greater_equal":"ge","less_equal": "le", "less": "lt", "greater": "gt", "equal": "eq", "not_equal": "ne"}
      if name in conversion:
        name = conversion[name]
      if len(context[1])==2 and context[1][1] is self and not(context[1][0] is self):
        name = 'r' + name
        args.reverse()
      if not(hasattr(self,name)) or ('mul' in name):
        name = '__' + name + '__'
      fun=getattr(self, name)
      return fun(*args[1:])

    def __array_ufunc__(self, ufunc, method, *inputs, **kwargs):
      conversion = {"multiply": "mul", "divide": "div", "true_divide": "div", "subtract":"sub","power":"pow","greater_equal":"ge","less_equal": "le", "less": "lt", "greater": "gt", "equal": "eq", "not_equal": "ne"}
      name = ufunc.__name__
      inputs = list(inputs)
      if len(inputs)==3:
        import warnings
        warnings.warn("Error with %s. Looks like you are using an assignment operator, such as 'a+=b' where 'a' is a numpy type. This is not supported, and cannot be supported without changing numpy." % name, RuntimeWarning)
        return NotImplemented
      if "vectorized" in name:
          name = name[:-len(" (vectorized)")]
      if name in conversion:
        name = conversion[name]
      if len(inputs)==2 and inputs[1] is self and not(inputs[0] is self):
        name = 'r' + name
        inputs.reverse()
      if not(hasattr(self,name)) or ('mul' in name):
        name = '__' + name + '__'
      if method=="reduce" and name=="add":
        assert len(inputs)==1
        axis = kwargs["axis"]
        if axis is None:
            return inputs[0].sum()
        else:
            return inputs[0].sum(axis)
      try:
        assert method=="__call__"
        fun=getattr(self, name)
        return fun(*inputs[1:])
      except Exception as e:
        if "Dimension mismatch" in str(e):
          import sys
          if sys.version_info[0] < 3:
              raise RuntimeError(str(e))
          else:
              raise e
#Fall back to numpy conversion
        new_inputs = list(inputs)
        try:
          new_inputs[0] = new_inputs[0].full()
        except:
          import warnings
          warnings.warn("Implicit conversion of symbolic CasADi type to numeric matrix not supported.\n"
                                 + "This may occur when you pass a CasADi object to a numpy function.\n"
                                 + "Use an equivalent CasADi function instead of that numpy function.", RuntimeWarning)
          return NotImplemented
        return new_inputs[0].__array_ufunc__(ufunc, method, *new_inputs, **kwargs)


    def __array__(self,*args,**kwargs):
      import numpy as n
      if len(args) > 1 and isinstance(args[1],tuple) and isinstance(args[1][0],n.ufunc) and isinstance(args[1][0],n.ufunc) and len(args[1])>1 and args[1][0].nin==len(args[1][1]):
        if len(args[1][1])==3:
          raise Exception("Error with %s. Looks like you are using an assignment operator, such as 'a+=b'. This is not supported when 'a' is a numpy type, and cannot be supported without changing numpy itself. Either upgrade a to a CasADi type first, or use 'a = a + b'. " % args[1][0].__name__)
        return n.array([n.nan])
      else:
        if hasattr(self,'__array_custom__'):
          return self.__array_custom__(*args,**kwargs)
        else:
          try:
            return self.full()
          except:
            if self.is_scalar(True):
#Needed for#2743
              E=n.empty((),dtype=object)
              E[()] = self
              return E
            else:
              raise Exception("Implicit conversion of symbolic CasADi type to numeric matrix not supported.\n"
                        + "This may occur when you pass a CasADi object to a numpy function.\n"
                        + "Use an equivalent CasADi function instead of that numpy function.")



    def __init__(self, *args):
        """


        ::

          MX()
          MX(Sparsity sp)
          MX(float x)
          MX(DM x)
          MX(MX other)
          MX(int nrow, int ncol)
          MX(Sparsity sp, MX val)
          MX(Sparsity sp, str fname)
          MX(DM val, str name)


        .......

        ::

          MX(DM x)
          MX(MX other)
          MX(DM val, str name)



        .............


        .......

        ::

          MX()



        [INTERNAL] 
        Default constructor.

        Extra doc: https://github.com/casadi/casadi/wiki/L_q0

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L102

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L59-L61


        .............


        .......

        ::

          MX(int nrow, int ncol)



        [INTERNAL] 
        Create a sparse matrix with all structural zeros.

        Extra doc: https://github.com/casadi/casadi/wiki/L_q1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L107

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L108-L110


        .............


        .......

        ::

          MX(Sparsity sp)



        [INTERNAL] 
        Create a sparse matrix from a sparsity pattern.

        Same as MX::ones(sparsity)

        Extra doc: https://github.com/casadi/casadi/wiki/L_q3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L121

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L104-L106


        .............


        .......

        ::

          MX(float x)



        [INTERNAL] 
        Create scalar constant (also implicit type conversion)

        Extra doc: https://github.com/casadi/casadi/wiki/L_q6

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L144

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L71-L73


        .............


        .......

        ::

          MX(Sparsity sp, MX val)



        [INTERNAL] 
        Construct matrix with a given sparsity and nonzeros.

        Extra doc: https://github.com/casadi/casadi/wiki/L_q4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L126

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L83-L102


        .............


        .......

        ::

          MX(Sparsity sp, str fname)



        [INTERNAL] 
        Construct matrix with a given sparsity and a file with nonzeros.

        Extra doc: https://github.com/casadi/casadi/wiki/L_q5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L131

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L120-L122


        .............



        """
        this = _casadi.new_MX(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
MX_swigregister = _casadi.MX_swigregister
MX_swigregister(MX)

def MX_type_name(*args) -> "std::string":
    """


    ::

      type_name() -> str



    """
    return _casadi.MX_type_name(*args)

def MX_deserialize(*args) -> "casadi::MX":
    """


    ::

      deserialize(casadi::DeserializingStream & s) -> MX



    """
    return _casadi.MX_deserialize(*args)

def MX_binary(*args) -> "casadi::MX":
    """
      [INTERNAL] 

    ::

      binary(int op, MX x, MX y) -> MX

    Create nodes by their ID.

    Extra doc: https://github.com/casadi/casadi/wiki/L_r1

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L442

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L513-L538



    """
    return _casadi.MX_binary(*args)

def MX_unary(*args) -> "casadi::MX":
    """
      [INTERNAL] 

    ::

      unary(int op, MX x) -> MX

    Create nodes by their ID.

    Extra doc: https://github.com/casadi/casadi/wiki/L_r1

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L443

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L540-L542



    """
    return _casadi.MX_unary(*args)

def MX_inf(*args) -> "casadi::MX":
    """
      [INTERNAL] 

    ::

      inf(int nrow, int ncol) -> MX
      inf((int,int) rc) -> MX
      inf(Sparsity sp) -> MX

    create a matrix with all inf

    Extra doc: https://github.com/casadi/casadi/wiki/L_r2

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L452

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L560-L562


    .......

    ::

      inf(int nrow, int ncol)



    [INTERNAL] 
    create a matrix with all inf

    Extra doc: https://github.com/casadi/casadi/wiki/L_r2

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L451

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L556-L558


    .............


    .......

    ::

      inf((int,int) rc)



    [INTERNAL] 
    create a matrix with all inf

    Extra doc: https://github.com/casadi/casadi/wiki/L_r2

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L452

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L560-L562


    .............


    .......

    ::

      inf(Sparsity sp)



    [INTERNAL] 
    create a matrix with all inf

    Extra doc: https://github.com/casadi/casadi/wiki/L_r2

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L450

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L564-L566


    .............



    """
    return _casadi.MX_inf(*args)

def MX_nan(*args) -> "casadi::MX":
    """
      [INTERNAL] 

    ::

      nan(int nrow, int ncol) -> MX
      nan((int,int) rc) -> MX
      nan(Sparsity sp) -> MX

    create a matrix with all nan

    Extra doc: https://github.com/casadi/casadi/wiki/L_r3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L461

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L572-L574


    .......

    ::

      nan(int nrow, int ncol)



    [INTERNAL] 
    create a matrix with all nan

    Extra doc: https://github.com/casadi/casadi/wiki/L_r3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L460

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L568-L570


    .............


    .......

    ::

      nan((int,int) rc)



    [INTERNAL] 
    create a matrix with all nan

    Extra doc: https://github.com/casadi/casadi/wiki/L_r3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L461

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L572-L574


    .............


    .......

    ::

      nan(Sparsity sp)



    [INTERNAL] 
    create a matrix with all nan

    Extra doc: https://github.com/casadi/casadi/wiki/L_r3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L459

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L576-L578


    .............



    """
    return _casadi.MX_nan(*args)

def MX_eye(*args) -> "casadi::MX":
    """


    ::

      eye(int n) -> MX



    """
    return _casadi.MX_eye(*args)

def MX_einstein(*args) -> "casadi::MX":
    """
      [INTERNAL] 

    ::

      einstein(MX A, MX B, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c) -> MX
      einstein(MX A, MX B, MX C, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c) -> MX

    Computes an einstein dense tensor contraction.

    Computes the product: C_c = A_a + B_b where a b c are index/einstein 

    notation in an encoded form

    For example, an matrix-matrix product may be written as: C_ij = A_ik 
    B_kj

    The encoded form uses strictly negative numbers to indicate labels. 
    For the
     above example, we would have: a {-1, -3} b {-3, -2} c {-1 -2}

    Extra doc: https://github.com/casadi/casadi/wiki/L_r5

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L564

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L670-L676


    .......

    ::

      einstein(MX A, MX B, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c)



    [INTERNAL] 
    Computes an einstein dense tensor contraction.

    Computes the product: C_c = A_a + B_b where a b c are index/einstein 

    notation in an encoded form

    For example, an matrix-matrix product may be written as: C_ij = A_ik 
    B_kj

    The encoded form uses strictly negative numbers to indicate labels. 
    For the
     above example, we would have: a {-1, -3} b {-3, -2} c {-1 -2}

    Extra doc: https://github.com/casadi/casadi/wiki/L_r5

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L564

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L670-L676


    .............


    .......

    ::

      einstein(MX A, MX B, MX C, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c)



    [INTERNAL] 
    Computes an einstein dense tensor contraction.

    Computes the product: C_c = A_a + B_b where a b c are index/einstein 

    notation in an encoded form

    For example, an matrix-matrix product may be written as: C_ij = A_ik 
    B_kj

    The encoded form uses strictly negative numbers to indicate labels. 
    For the
     above example, we would have: a {-1, -3} b {-3, -2} c {-1 -2}

    Extra doc: https://github.com/casadi/casadi/wiki/L_r5

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L558

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L662-L668


    .............



    """
    return _casadi.MX_einstein(*args)

def MX_bspline_dual(*args) -> "casadi::DM":
    """
      [INTERNAL] 

    ::

      bspline_dual([float] x, [[float]] knots, [int] degree, dict opts) -> DM



    """
    return _casadi.MX_bspline_dual(*args)

def MX_interpn_linear(*args) -> "casadi::MX":
    """


    ::

      interpn_linear([MX] x, MX v, [MX] xq, dict opts) -> MX



    """
    return _casadi.MX_interpn_linear(*args)

def MX_set_max_depth(*args) -> "void":
    """


    ::

      set_max_depth(int eq_depth)



    """
    return _casadi.MX_set_max_depth(*args)

def MX_get_max_depth(*args) -> "casadi_int":
    """


    ::

      get_max_depth() -> int



    """
    return _casadi.MX_get_max_depth(*args)

def MX_test_cast(*args) -> "bool":
    """


    ::

      test_cast(casadi::SharedObjectInternal const * ptr) -> bool



    """
    return _casadi.MX_test_cast(*args)

def MX_get_input(*args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
    """


    ::

      get_input(Function f) -> [MX]



    """
    return _casadi.MX_get_input(*args)

def MX_get_free(*args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
    """


    ::

      get_free(Function f) -> [MX]



    """
    return _casadi.MX_get_free(*args)


def attach_return_type(f,t):
  if not(hasattr(f,'func_annotations')):
    f.func_annotations = {}
  if not(isinstance(getattr(f,'func_annotations'),dict)):
    raise Exception("Cannot annotate this python Method to be a sparsitygenerator. Method has func_annotations attribute with unknown type.")
  f.func_annotations["return"] = t
  return f

def pyevaluate(f):
  return attach_return_type(f,None)

def pycallback(f):
  return attach_return_type(f,int)


def pyfunction(inputs,outputs):
  def wrap(f):

    @pyevaluate
    def fcustom(f2):
      res = f([f2.getInput(i) for i in range(f2.n_in())])
      if not isinstance(res,list):
        res = [res]
      for i in range(f2.n_out()):
        f2.setOutput(res[i],i)
    import warnings

    with warnings.catch_warnings():
      warnings.filterwarnings("ignore",category=DeprecationWarning)
      Fun = CustomFunction("CustomFunction",fcustom,inputs,outputs)
      return Fun

  return wrap

def PyFunction(name, obj, inputs, outputs, opts={}):
    @pyevaluate
    def fcustom(f):
      res = [f.getOutput(i) for i in range(f.n_out())]
      obj.evaluate([f.getInput(i) for i in range(f.n_in())],res)
      for i in range(f.n_out()): f.setOutput(res[i], i)

    import warnings

    with warnings.catch_warnings():
      warnings.filterwarnings("ignore",category=DeprecationWarning)
      return CustomFunction("CustomFunction", fcustom,
                            inputs, outputs, opts)


class Function(SharedObject, PrintableCommon):
    """
      [INTERNAL] 

    ::


     Function object.

    A  Function instance is a general multiple-input, multiple-output function 
    where 
    each input and output can be a sparse matrix.
     For an introduction to
     this class, see the CasADi user guide. Function is a reference counted and 
    immutable class; copying a class instance 
    is very cheap and its behavior 
    (with some exceptions) is not affected 
    by calling its member functions.

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_1uw

    >List of available options

    +------------------+-----------------+------------------+------------------+
    |        Id        |      Type       |   Description    |     Used in      |
    +==================+=================+==================+==================+
    | ad_weight        | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for derivative   | Internal         |
    |                  |                 | calculation.When |                  |
    |                  |                 | there is an      |                  |
    |                  |                 | option of either |                  |
    |                  |                 | using forward or |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | directional      |                  |
    |                  |                 | derivatives, the |                  |
    |                  |                 | condition ad_wei |                  |
    |                  |                 | ght*nf<=(1-      |                  |
    |                  |                 | ad_weight)*na is |                  |
    |                  |                 | used where nf    |                  |
    |                  |                 | and na are       |                  |
    |                  |                 | estimates of the |                  |
    |                  |                 | number of        |                  |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | mode directional |                  |
    |                  |                 | derivatives      |                  |
    |                  |                 | needed. By       |                  |
    |                  |                 | default,         |                  |
    |                  |                 | ad_weight is     |                  |
    |                  |                 | calculated       |                  |
    |                  |                 | automatically,   |                  |
    |                  |                 | but this can be  |                  |
    |                  |                 | overridden by    |                  |
    |                  |                 | setting this     |                  |
    |                  |                 | option. In       |                  |
    |                  |                 | particular, 0    |                  |
    |                  |                 | means forcing    |                  |
    |                  |                 | forward mode and |                  |
    |                  |                 | 1 forcing        |                  |
    |                  |                 | reverse mode.    |                  |
    |                  |                 | Leave unset for  |                  |
    |                  |                 | (class specific) |                  |
    |                  |                 | heuristics.      |                  |
    +------------------+-----------------+------------------+------------------+
    | ad_weight_sp     | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for sparsity     | Internal         |
    |                  |                 | pattern          |                  |
    |                  |                 | calculation calc |                  |
    |                  |                 | ulation.Override |                  |
    |                  |                 | s default        |                  |
    |                  |                 | behavior. Set to |                  |
    |                  |                 | 0 and 1 to force |                  |
    |                  |                 | forward and      |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | respectively.    |                  |
    |                  |                 | Cf. option       |                  |
    |                  |                 | "ad_weight".     |                  |
    |                  |                 | When set to -1,  |                  |
    |                  |                 | sparsity is      |                  |
    |                  |                 | completely       |                  |
    |                  |                 | ignored and      |                  |
    |                  |                 | dense matrices   |                  |
    |                  |                 | are used.        |                  |
    +------------------+-----------------+------------------+------------------+
    | always_inline    | OT_BOOL         | Force inlining.  | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | cache            | OT_DICT         | Prepopulate the  | casadi::Function |
    |                  |                 | function cache.  | Internal         |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | compiler         | OT_STRING       | Just-in-time     | casadi::Function |
    |                  |                 | compiler plugin  | Internal         |
    |                  |                 | to be used.      |                  |
    +------------------+-----------------+------------------+------------------+
    | custom_jacobian  | OT_FUNCTION     | Override         | casadi::Function |
    |                  |                 | CasADi's AD. Use | Internal         |
    |                  |                 | together with    |                  |
    |                  |                 | 'jac_penalty':   |                  |
    |                  |                 | 0. Note: Highly  |                  |
    |                  |                 | experimental.    |                  |
    |                  |                 | Syntax may break |                  |
    |                  |                 | often.           |                  |
    +------------------+-----------------+------------------+------------------+
    | der_options      | OT_DICT         | Default options  | casadi::Function |
    |                  |                 | to be used to    | Internal         |
    |                  |                 | populate         |                  |
    |                  |                 | forward_options, |                  |
    |                  |                 | reverse_options, |                  |
    |                  |                 | and              |                  |
    |                  |                 | jacobian_options |                  |
    |                  |                 | before those     |                  |
    |                  |                 | options are      |                  |
    |                  |                 | merged in.       |                  |
    +------------------+-----------------+------------------+------------------+
    | derivative_of    | OT_FUNCTION     | The function is  | casadi::Function |
    |                  |                 | a derivative of  | Internal         |
    |                  |                 | another          |                  |
    |                  |                 | function. The    |                  |
    |                  |                 | type of          |                  |
    |                  |                 | derivative       |                  |
    |                  |                 | (directional     |                  |
    |                  |                 | derivative,      |                  |
    |                  |                 | Jacobian) is     |                  |
    |                  |                 | inferred from    |                  |
    |                  |                 | the function     |                  |
    |                  |                 | name.            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump             | OT_BOOL         | Dump function to | casadi::Function |
    |                  |                 | file upon first  | Internal         |
    |                  |                 | evaluation.      |                  |
    |                  |                 | [false]          |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_dir         | OT_STRING       | Directory to     | casadi::Function |
    |                  |                 | dump             | Internal         |
    |                  |                 | inputs/outputs   |                  |
    |                  |                 | to. Make sure    |                  |
    |                  |                 | the directory    |                  |
    |                  |                 | exists [.]       |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_format      | OT_STRING       | Choose file      | casadi::Function |
    |                  |                 | format to dump   | Internal         |
    |                  |                 | matrices. See    |                  |
    |                  |                 | DM.from_file     |                  |
    |                  |                 | [mtx]            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_in          | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | to file          |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_out         | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs to file  |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_fd        | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation by   |                  |
    |                  |                 | finite           |                  |
    |                  |                 | differencing.    |                  |
    |                  |                 | [default:        |                  |
    |                  |                 | false]]          |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_forward   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using forward    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_jacobian  | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobians of all |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | outputs with     |                  |
    |                  |                 | respect to all   |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | inputs - if      |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_reverse   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | transposed       |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using reverse    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | error_on_fail    | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when function    | ction            |
    |                  |                 | evaluation fails |                  |
    |                  |                 | (default true).  |                  |
    +------------------+-----------------+------------------+------------------+
    | external_transfo | OT_VECTORVECTOR | List of external | casadi::Function |
    | rm               |                 | _transform       | Internal         |
    |                  |                 | instruction      |                  |
    |                  |                 | arguments.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_method        | OT_STRING       | Method for       | casadi::Function |
    |                  |                 | finite           | Internal         |
    |                  |                 | differencing     |                  |
    |                  |                 | [default         |                  |
    |                  |                 | 'central']       |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_options       | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | finite           |                  |
    |                  |                 | difference       |                  |
    |                  |                 | instance         |                  |
    +------------------+-----------------+------------------+------------------+
    | forward_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | forward mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | gather_stats     | OT_BOOL         | Deprecated       | casadi::Function |
    |                  |                 | option           | Internal         |
    |                  |                 | (ignored):       |                  |
    |                  |                 | Statistics are   |                  |
    |                  |                 | now always       |                  |
    |                  |                 | collected.       |                  |
    +------------------+-----------------+------------------+------------------+
    | input_scheme     | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | inputs_check     | OT_BOOL         | Throw exceptions | casadi::Function |
    |                  |                 | when the         | Internal         |
    |                  |                 | numerical values |                  |
    |                  |                 | of the inputs    |                  |
    |                  |                 | don't make sense |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_in       | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each input if it | Internal         |
    |                  |                 | should be        |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_out      | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each output if   | Internal         |
    |                  |                 | it should be     |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | jac_penalty      | OT_DOUBLE       | When requested   | casadi::Function |
    |                  |                 | for a number of  | Internal         |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | directions, it   |                  |
    |                  |                 | may be cheaper   |                  |
    |                  |                 | to compute first |                  |
    |                  |                 | the full         |                  |
    |                  |                 | jacobian and     |                  |
    |                  |                 | then multiply    |                  |
    |                  |                 | with seeds,      |                  |
    |                  |                 | rather than      |                  |
    |                  |                 | obtain the       |                  |
    |                  |                 | requested        |                  |
    |                  |                 | directions in a  |                  |
    |                  |                 | straightforward  |                  |
    |                  |                 | manner. Casadi   |                  |
    |                  |                 | uses a heuristic |                  |
    |                  |                 | to decide which  |                  |
    |                  |                 | is cheaper. A    |                  |
    |                  |                 | high value of    |                  |
    |                  |                 | 'jac_penalty'    |                  |
    |                  |                 | makes it less    |                  |
    |                  |                 | likely for the   |                  |
    |                  |                 | heurstic to      |                  |
    |                  |                 | chose the full   |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy. The    |                  |
    |                  |                 | special value -1 |                  |
    |                  |                 | indicates never  |                  |
    |                  |                 | to use the full  |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy         |                  |
    +------------------+-----------------+------------------+------------------+
    | jacobian_options | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | Jacobian         |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | jit              | OT_BOOL         | Use just-in-time | casadi::Function |
    |                  |                 | compiler to      | Internal         |
    |                  |                 | speed up the     |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_cleanup      | OT_BOOL         | Cleanup up the   | casadi::Function |
    |                  |                 | temporary source | Internal         |
    |                  |                 | file that jit    |                  |
    |                  |                 | creates.         |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_name         | OT_STRING       | The file name    | casadi::Function |
    |                  |                 | used to write    | Internal         |
    |                  |                 | out code. The    |                  |
    |                  |                 | actual file      |                  |
    |                  |                 | names used       |                  |
    |                  |                 | depend on 'jit_t |                  |
    |                  |                 | emp_suffix' and  |                  |
    |                  |                 | include          |                  |
    |                  |                 | extensions.      |                  |
    |                  |                 | Default:         |                  |
    |                  |                 | 'jit_tmp'        |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_options      | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | jit compiler.    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_serialize    | OT_STRING       | Specify          | casadi::Function |
    |                  |                 | behaviour when   | Internal         |
    |                  |                 | serializing a    |                  |
    |                  |                 | jitted function: |                  |
    |                  |                 | SOURCE|link|embe |                  |
    |                  |                 | d.               |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_temp_suffix  | OT_BOOL         | Use a temporary  | casadi::Function |
    |                  |                 | (seemingly       | Internal         |
    |                  |                 | random) filename |                  |
    |                  |                 | suffix for       |                  |
    |                  |                 | generated code   |                  |
    |                  |                 | and libraries.   |                  |
    |                  |                 | This is desired  |                  |
    |                  |                 | for thread-      |                  |
    |                  |                 | safety. This     |                  |
    |                  |                 | behaviour may    |                  |
    |                  |                 | defeat caching   |                  |
    |                  |                 | compiler         |                  |
    |                  |                 | wrappers.        |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | max_io           | OT_INT          | Acceptable       | casadi::Function |
    |                  |                 | number of inputs | Internal         |
    |                  |                 | and outputs.     |                  |
    |                  |                 | Warn if          |                  |
    |                  |                 | exceeded.        |                  |
    +------------------+-----------------+------------------+------------------+
    | max_num_dir      | OT_INT          | Specify the      | casadi::Function |
    |                  |                 | maximum number   | Internal         |
    |                  |                 | of directions    |                  |
    |                  |                 | for derivative   |                  |
    |                  |                 | functions.       |                  |
    |                  |                 | Overrules the    |                  |
    |                  |                 | builtin optimize |                  |
    |                  |                 | d_num_dir.       |                  |
    +------------------+-----------------+------------------+------------------+
    | never_inline     | OT_BOOL         | Forbid inlining. | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | output_scheme    | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | post_expand      | OT_BOOL         | After            | casadi::Function |
    |                  |                 | construction,    | Internal         |
    |                  |                 | expand this      |                  |
    |                  |                 | Function .       |                  |
    |                  |                 | Default: False   |                  |
    +------------------+-----------------+------------------+------------------+
    | post_expand_opti | OT_DICT         | Options to be    | casadi::Function |
    | ons              |                 | passed to post-  | Internal         |
    |                  |                 | construction     |                  |
    |                  |                 | expansion.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | print_canonical  | OT_BOOL         | When printing    | casadi::Function |
    |                  |                 | numerical        | Internal         |
    |                  |                 | matrices, use a  |                  |
    |                  |                 | format that is   |                  |
    |                  |                 | exact and        |                  |
    |                  |                 | reproducible in  |                  |
    |                  |                 | generated C      |                  |
    |                  |                 | code.            |                  |
    +------------------+-----------------+------------------+------------------+
    | print_in         | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_out        | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs          |                  |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_time       | OT_BOOL         | print            | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time. Implies    |                  |
    |                  |                 | record_time.     |                  |
    +------------------+-----------------+------------------+------------------+
    | record_time      | OT_BOOL         | record           | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time, for        |                  |
    |                  |                 | retrieval with   |                  |
    |                  |                 | stats() .        |                  |
    +------------------+-----------------+------------------+------------------+
    | regularity_check | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when NaN or Inf  | ction            |
    |                  |                 | appears during   |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | reverse_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | reverse mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | user_data        | OT_VOIDPTR      | A user-defined   | casadi::Function |
    |                  |                 | field that can   | Internal         |
    |                  |                 | be used to       |                  |
    |                  |                 | identify the     |                  |
    |                  |                 | function or pass |                  |
    |                  |                 | additional       |                  |
    |                  |                 | information      |                  |
    +------------------+-----------------+------------------+------------------+
    | verbose          | OT_BOOL         | Verbose          | casadi::ProtoFun |
    |                  |                 | evaluation  for  | ction            |
    |                  |                 | debugging        |                  |
    +------------------+-----------------+------------------+------------------+

    C++ includes: function.hpp



    """

    __swig_setmethods__ = {}
    for _s in [SharedObject, PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, Function, name, value)
    __swig_getmethods__ = {}
    for _s in [SharedObject, PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, Function, name)
    __repr__ = _swig_repr

    def type_name(*args) -> "std::string":
        """


        ::

          type_name() -> str



        """
        return _casadi.Function_type_name(*args)

    type_name = staticmethod(type_name)

    def jit(*args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          jit(str name, str body, [str] name_in, [str] name_out, dict opts) -> Function
          jit(str name, str body, [str] name_in, [str] name_out, [Sparsity] sparsity_in, [Sparsity] sparsity_out, dict opts) -> Function

        Create a just-in-time compiled function from a C language 
        string.

        The names and sparsity patterns of all the inputs and outputs must be 

        provided. If sparsities are not provided, all inputs and outputs are 

        assumed to be scalar. Only specify the function body, assuming that 
        input 
        and output nonzeros are stored in arrays with the specified 
        naming 
        convension. The data type used is 'casadi_real', which is 
        typically equal 
        to 'double or another data type with the same API as 'double.

        Inputs may be null pointers. This means that the all entries are zero.

        Outputs may be null points. This means that the corresponding result 
        can be
         ignored.

        If an error occurs in the evaluation, issue "return 1;";

        The final generated function will have a structure similar to:

        casadi_int fname(const casadi_real** arg, casadi_real** res, 
        casadi_int* 
        iw, casadi_real* w, void* mem) { const casadi_real *x1, 
        *x2; casadi_real 
        *r1, *r2; x1 = *arg++; x2 = *arg++; r1 = *res++; r2 =
         *res++; 
        <FUNCTION_BODY> return 0; }

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L189

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L294-L306



        .......

        ::

          jit(str name, str body, [str] name_in, [str] name_out, dict opts)



        [INTERNAL] 
        Create a just-in-time compiled function from a C language 
        string.

        The names and sparsity patterns of all the inputs and outputs must be 

        provided. If sparsities are not provided, all inputs and outputs are 

        assumed to be scalar. Only specify the function body, assuming that 
        input 
        and output nonzeros are stored in arrays with the specified 
        naming 
        convension. The data type used is 'casadi_real', which is 
        typically equal 
        to 'double or another data type with the same API as 'double.

        Inputs may be null pointers. This means that the all entries are zero.

        Outputs may be null points. This means that the corresponding result 
        can be
         ignored.

        If an error occurs in the evaluation, issue "return 1;";

        The final generated function will have a structure similar to:

        casadi_int fname(const casadi_real** arg, casadi_real** res, 
        casadi_int* 
        iw, casadi_real* w, void* mem) { const casadi_real *x1, 
        *x2; casadi_real 
        *r1, *r2; x1 = *arg++; x2 = *arg++; r1 = *res++; r2 =
         *res++; 
        <FUNCTION_BODY> return 0; }

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L185

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L285-L292



        .............


        .......

        ::

          jit(str name, str body, [str] name_in, [str] name_out, [Sparsity] sparsity_in, [Sparsity] sparsity_out, dict opts)



        [INTERNAL] 
        Create a just-in-time compiled function from a C language 
        string.

        The names and sparsity patterns of all the inputs and outputs must be 

        provided. If sparsities are not provided, all inputs and outputs are 

        assumed to be scalar. Only specify the function body, assuming that 
        input 
        and output nonzeros are stored in arrays with the specified 
        naming 
        convension. The data type used is 'casadi_real', which is 
        typically equal 
        to 'double or another data type with the same API as 'double.

        Inputs may be null pointers. This means that the all entries are zero.

        Outputs may be null points. This means that the corresponding result 
        can be
         ignored.

        If an error occurs in the evaluation, issue "return 1;";

        The final generated function will have a structure similar to:

        casadi_int fname(const casadi_real** arg, casadi_real** res, 
        casadi_int* 
        iw, casadi_real* w, void* mem) { const casadi_real *x1, 
        *x2; casadi_real 
        *r1, *r2; x1 = *arg++; x2 = *arg++; r1 = *res++; r2 =
         *res++; 
        <FUNCTION_BODY> return 0; }

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L189

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L294-L306



        .............



        """
        return _casadi.Function_jit(*args)

    jit = staticmethod(jit)
    __swig_destroy__ = _casadi.delete_Function

    def expand(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          expand(self) -> Function
          expand(self, str name, dict opts) -> Function

        Expand a function to SX.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L207

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L318-L334



        .......

        ::

          expand(self)



        [INTERNAL] 
        Expand a function to SX.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L206

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L308-L316



        .............


        .......

        ::

          expand(self, str name, dict opts)



        [INTERNAL] 
        Expand a function to SX.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L207

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L318-L334



        .............



        """
        return _casadi.Function_expand(self, *args)


    def n_in(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          n_in(self) -> int

        Get the number of function inputs.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L228

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L819-L821




        """
        return _casadi.Function_n_in(self, *args)


    def n_out(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          n_out(self) -> int

        Get the number of function outputs.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v9

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L233

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L823-L825




        """
        return _casadi.Function_n_out(self, *args)


    def size1_in(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size1_in(self, int ind) -> int
          size1_in(self, str iname) -> int

        Get input dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1va

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L240

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L240-L240



        .......

        ::

          size1_in(self, int ind)



        [INTERNAL] 
        Get input dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1va

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L239

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L827-L829



        .............


        .......

        ::

          size1_in(self, str iname)



        [INTERNAL] 
        Get input dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1va

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L240

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L240-L240



        .............



        """
        return _casadi.Function_size1_in(self, *args)


    def size2_in(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size2_in(self, int ind) -> int
          size2_in(self, str iname) -> int

        Get input dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1va

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L242

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L242-L242



        .......

        ::

          size2_in(self, int ind)



        [INTERNAL] 
        Get input dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1va

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L241

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L831-L833



        .............


        .......

        ::

          size2_in(self, str iname)



        [INTERNAL] 
        Get input dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1va

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L242

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L242-L242



        .............



        """
        return _casadi.Function_size2_in(self, *args)


    def size_in(self, *args) -> "std::pair< casadi_int,casadi_int >":
        """
          [INTERNAL] 

        ::

          size_in(self, int ind) -> (int,int)
          size_in(self, str iname) -> (int,int)

        Get input dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1va

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L244

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L244-L246



        .......

        ::

          size_in(self, int ind)



        [INTERNAL] 
        Get input dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1va

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L243

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L843-L845



        .............


        .......

        ::

          size_in(self, str iname)



        [INTERNAL] 
        Get input dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1va

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L244

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L244-L246



        .............



        """
        return _casadi.Function_size_in(self, *args)


    def size1_out(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size1_out(self, int ind) -> int
          size1_out(self, str oname) -> int

        Get output dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vb

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L254

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L254-L254



        .......

        ::

          size1_out(self, int ind)



        [INTERNAL] 
        Get output dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vb

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L253

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L835-L837



        .............


        .......

        ::

          size1_out(self, str oname)



        [INTERNAL] 
        Get output dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vb

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L254

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L254-L254



        .............



        """
        return _casadi.Function_size1_out(self, *args)


    def size2_out(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          size2_out(self, int ind) -> int
          size2_out(self, str oname) -> int

        Get output dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vb

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L256

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L256-L256



        .......

        ::

          size2_out(self, int ind)



        [INTERNAL] 
        Get output dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vb

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L255

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L839-L841



        .............


        .......

        ::

          size2_out(self, str oname)



        [INTERNAL] 
        Get output dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vb

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L256

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L256-L256



        .............



        """
        return _casadi.Function_size2_out(self, *args)


    def size_out(self, *args) -> "std::pair< casadi_int,casadi_int >":
        """
          [INTERNAL] 

        ::

          size_out(self, int ind) -> (int,int)
          size_out(self, str oname) -> (int,int)

        Get output dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vb

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L258

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L258-L260



        .......

        ::

          size_out(self, int ind)



        [INTERNAL] 
        Get output dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vb

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L257

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L847-L849



        .............


        .......

        ::

          size_out(self, str oname)



        [INTERNAL] 
        Get output dimension.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vb

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L258

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L258-L260



        .............



        """
        return _casadi.Function_size_out(self, *args)


    def nnz_in(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz_in(self) -> int
          nnz_in(self, int ind) -> int
          nnz_in(self, str iname) -> int

        Get number of input nonzeros.

        For a particular input or for all of the inputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vc

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L271

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L271-L271



        .......

        ::

          nnz_in(self)



        [INTERNAL] 
        Get number of input nonzeros.

        For a particular input or for all of the inputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vc

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L269

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L851-L853



        .............


        .......

        ::

          nnz_in(self, int ind)



        [INTERNAL] 
        Get number of input nonzeros.

        For a particular input or for all of the inputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vc

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L270

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L867-L869



        .............


        .......

        ::

          nnz_in(self, str iname)



        [INTERNAL] 
        Get number of input nonzeros.

        For a particular input or for all of the inputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vc

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L271

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L271-L271



        .............



        """
        return _casadi.Function_nnz_in(self, *args)


    def nnz_out(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nnz_out(self) -> int
          nnz_out(self, int ind) -> int
          nnz_out(self, str oname) -> int

        Get number of output nonzeros.

        For a particular output or for all of the outputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vd

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L282

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L282-L282



        .......

        ::

          nnz_out(self)



        [INTERNAL] 
        Get number of output nonzeros.

        For a particular output or for all of the outputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vd

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L280

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L855-L857



        .............


        .......

        ::

          nnz_out(self, int ind)



        [INTERNAL] 
        Get number of output nonzeros.

        For a particular output or for all of the outputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vd

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L281

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L871-L873



        .............


        .......

        ::

          nnz_out(self, str oname)



        [INTERNAL] 
        Get number of output nonzeros.

        For a particular output or for all of the outputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vd

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L282

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L282-L282



        .............



        """
        return _casadi.Function_nnz_out(self, *args)


    def numel_in(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          numel_in(self) -> int
          numel_in(self, int ind) -> int
          numel_in(self, str iname) -> int

        Get number of input elements.

        For a particular input or for all of the inputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ve

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L293

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L293-L293



        .......

        ::

          numel_in(self)



        [INTERNAL] 
        Get number of input elements.

        For a particular input or for all of the inputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ve

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L291

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L859-L861



        .............


        .......

        ::

          numel_in(self, int ind)



        [INTERNAL] 
        Get number of input elements.

        For a particular input or for all of the inputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ve

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L292

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L875-L877



        .............


        .......

        ::

          numel_in(self, str iname)



        [INTERNAL] 
        Get number of input elements.

        For a particular input or for all of the inputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ve

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L293

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L293-L293



        .............



        """
        return _casadi.Function_numel_in(self, *args)


    def numel_out(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          numel_out(self) -> int
          numel_out(self, int ind) -> int
          numel_out(self, str oname) -> int

        Get number of output elements.

        For a particular output or for all of the outputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vf

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L304

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L304-L304



        .......

        ::

          numel_out(self)



        [INTERNAL] 
        Get number of output elements.

        For a particular output or for all of the outputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vf

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L302

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L863-L865



        .............


        .......

        ::

          numel_out(self, int ind)



        [INTERNAL] 
        Get number of output elements.

        For a particular output or for all of the outputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vf

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L303

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L879-L881



        .............


        .......

        ::

          numel_out(self, str oname)



        [INTERNAL] 
        Get number of output elements.

        For a particular output or for all of the outputs

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vf

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L304

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L304-L304



        .............



        """
        return _casadi.Function_numel_out(self, *args)


    def name_in(self, *args) -> "std::string const &":
        """
          [INTERNAL] 

        ::

          name_in(self) -> [str]
          name_in(self, int ind) -> str

        Get input scheme name by index.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vi

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L320

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L999-L1005



        .......

        ::

          name_in(self, int ind)



        [INTERNAL] 
        Get input scheme name by index.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vi

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L320

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L999-L1005



        .............


        .......

        ::

          name_in(self)



        [INTERNAL] 
        Get input scheme.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vg

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L310

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L961-L963



        .............



        """
        return _casadi.Function_name_in(self, *args)


    def name_out(self, *args) -> "std::string const &":
        """
          [INTERNAL] 

        ::

          name_out(self) -> [str]
          name_out(self, int ind) -> str

        Get output scheme name by index.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vj

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L325

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1007-L1013



        .......

        ::

          name_out(self, int ind)



        [INTERNAL] 
        Get output scheme name by index.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vj

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L325

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1007-L1013



        .............


        .......

        ::

          name_out(self)



        [INTERNAL] 
        Get output scheme.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L315

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L965-L967



        .............



        """
        return _casadi.Function_name_out(self, *args)


    def index_in(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          index_in(self, str name) -> int

        Find the index for a string describing a particular entry of an 
        input 
        scheme.

        example: schemeEntry("x_opt") -> returns NLPSOL_X if 
        FunctionInternal 
        adheres to SCHEME_NLPINput

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vk

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L333

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L969-L975




        """
        return _casadi.Function_index_in(self, *args)


    def index_out(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          index_out(self, str name) -> int

        Find the index for a string describing a particular entry of an 
        output
         scheme.

        example: schemeEntry("x_opt") -> returns NLPSOL_X if 
        FunctionInternal 
        adheres to SCHEME_NLPINput

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vl

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L341

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L977-L983




        """
        return _casadi.Function_index_out(self, *args)


    def has_in(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_in(self, str name) -> bool

        Does the function have a particularly named input?

        Extra doc: https://github.com/casadi/casadi/wiki/L_2c9

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L346

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L985-L990




        """
        return _casadi.Function_has_in(self, *args)


    def has_out(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_out(self, str name) -> bool

        Does the function have a particularly named output?

        Extra doc: https://github.com/casadi/casadi/wiki/L_2ca

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L350

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L992-L997




        """
        return _casadi.Function_has_out(self, *args)


    def default_in(self, *args) -> "double":
        """
          [INTERNAL] 

        ::

          default_in(self, int ind) -> float

        Get default input value.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vm

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L355

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1489-L1491




        """
        return _casadi.Function_default_in(self, *args)


    def max_in(self, *args) -> "double":
        """
          [INTERNAL] 

        ::

          max_in(self, int ind) -> float

        Get largest input value.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vn

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L360

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1493-L1495




        """
        return _casadi.Function_max_in(self, *args)


    def min_in(self, *args) -> "double":
        """
          [INTERNAL] 

        ::

          min_in(self, int ind) -> float

        Get smallest input value.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vo

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L365

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1497-L1499




        """
        return _casadi.Function_min_in(self, *args)


    def nominal_in(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          nominal_in(self, int ind) -> [float]

        Get nominal input value.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vp

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L370

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1501-L1503




        """
        return _casadi.Function_nominal_in(self, *args)


    def nominal_out(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          nominal_out(self, int ind) -> [float]

        Get nominal output value.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vq

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L375

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1505-L1507




        """
        return _casadi.Function_nominal_out(self, *args)


    def sparsity_in(self, *args) -> "casadi::Sparsity const &":
        """
          [INTERNAL] 

        ::

          sparsity_in(self, int ind) -> Sparsity
          sparsity_in(self, str iname) -> Sparsity

        Get sparsity of a given input.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vr

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L382

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1023-L1029



        .......

        ::

          sparsity_in(self, int ind)



        [INTERNAL] 
        Get sparsity of a given input.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vr

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L381

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1015-L1021



        .............


        .......

        ::

          sparsity_in(self, str iname)



        [INTERNAL] 
        Get sparsity of a given input.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vr

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L382

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1023-L1029



        .............



        """
        return _casadi.Function_sparsity_in(self, *args)


    def sparsity_out(self, *args) -> "casadi::Sparsity const &":
        """
          [INTERNAL] 

        ::

          sparsity_out(self, int ind) -> Sparsity
          sparsity_out(self, str iname) -> Sparsity

        Get sparsity of a given output.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vs

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L390

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1039-L1045



        .......

        ::

          sparsity_out(self, int ind)



        [INTERNAL] 
        Get sparsity of a given output.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vs

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L389

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1031-L1037



        .............


        .......

        ::

          sparsity_out(self, str iname)



        [INTERNAL] 
        Get sparsity of a given output.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vs

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L390

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1039-L1045



        .............



        """
        return _casadi.Function_sparsity_out(self, *args)


    def is_diff_in(self, *args) -> "std::vector< bool,std::allocator< bool > >":
        """
          [INTERNAL] 

        ::

          is_diff_in(self) -> [bool]
          is_diff_in(self, int ind) -> bool

        Get differentiability of inputs/output.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vt

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L399

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1063-L1069



        .......

        ::

          is_diff_in(self)



        [INTERNAL] 
        Get differentiability of inputs/output.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vt

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L399

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1063-L1069



        .............


        .......

        ::

          is_diff_in(self, int ind)



        [INTERNAL] 
        Get differentiability of inputs/output.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vt

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L397

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1047-L1053



        .............



        """
        return _casadi.Function_is_diff_in(self, *args)


    def is_diff_out(self, *args) -> "std::vector< bool,std::allocator< bool > >":
        """
          [INTERNAL] 

        ::

          is_diff_out(self) -> [bool]
          is_diff_out(self, int ind) -> bool

        Get differentiability of inputs/output.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vt

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L400

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1071-L1077



        .......

        ::

          is_diff_out(self)



        [INTERNAL] 
        Get differentiability of inputs/output.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vt

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L400

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1071-L1077



        .............


        .......

        ::

          is_diff_out(self, int ind)



        [INTERNAL] 
        Get differentiability of inputs/output.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vt

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L398

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1055-L1061



        .............



        """
        return _casadi.Function_is_diff_out(self, *args)


    def factory(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          factory(self, str name, [str] s_in, [str] s_out, dict:[str] aux, dict opts) -> Function



        """
        return _casadi.Function_factory(self, *args)


    def oracle(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          oracle(self) -> Function

        Get oracle.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vu

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L416

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1917-L1923




        """
        return _casadi.Function_oracle(self, *args)


    def wrap(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          wrap(self) -> Function

        Wrap in an  Function instance consisting of only one  MX call.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vv

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L421

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1925-L1927




        """
        return _casadi.Function_wrap(self, *args)


    def wrap_as_needed(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          wrap_as_needed(self, dict opts) -> Function

        Wrap in a  Function with options.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vw

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L426

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1929-L1931




        """
        return _casadi.Function_wrap_as_needed(self, *args)


    def which_depends(self, *args) -> "std::vector< bool,std::allocator< bool > >":
        """
          [INTERNAL] 

        ::

          which_depends(self, str s_in, [str] s_out, int order, bool tr) -> [bool]

        Which variables enter with some order.

        Parameters:
        -----------

        order: 
        Only 1 (linear) and 2 (nonlinear) allowed

        tr: 
        Flip the relationship. Return which expressions contain the variables

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vx

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L434

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1835-L1842




        """
        return _casadi.Function_which_depends(self, *args)


    def print_dimensions(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_dimensions(self)

        Print dimensions of inputs and outputs.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vy

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L441

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1151-L1153




        """
        return _casadi.Function_print_dimensions(self, *args)


    def print_options(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_options(self)

        Print options to a stream.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1vz

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L446

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1155-L1157




        """
        return _casadi.Function_print_options(self, *args)


    def print_option(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          print_option(self, str name)

        Print all information there is to know about a certain option.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w0

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L451

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1159-L1161




        """
        return _casadi.Function_print_option(self, *args)


    def has_option(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_option(self, str option_name) -> bool

        Does a particular option exist.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L456

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1163-L1170




        """
        return _casadi.Function_has_option(self, *args)


    def change_option(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          change_option(self, str option_name, GenericType option_value)

        Change option after object creation for debugging.

        This is only possible for a selected number of options that do not 
        change 
        the numerical results of the computation, e.g. to enable a more
         verbose 
        output or saving to file.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w2

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L464

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1172-L1182




        """
        return _casadi.Function_change_option(self, *args)


    def reset_dump_count(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          reset_dump_count(self)

        Reset the counter used to name dump files.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2dy

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L469

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1184-L1190




        """
        return _casadi.Function_reset_dump_count(self, *args)


    def uses_output(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          uses_output(self) -> bool

        Do the derivative functions need nondifferentiated outputs?

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L474

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L883-L885




        """
        return _casadi.Function_uses_output(self, *args)


    def jacobian_old(self, *args) -> "casadi::Function":
        """
          [DEPRECATED] Replaced by  Function::factory.

        ::

          jacobian_old(self, int iind, int oind) -> Function


        Extra doc: https://github.com/casadi/casadi/wiki/L_1w4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L480

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L888-L894




        """
        return _casadi.Function_jacobian_old(self, *args)


    def hessian_old(self, *args) -> "casadi::Function":
        """
          [DEPRECATED] Replaced by  Function::factory.

        ::

          hessian_old(self, int iind, int oind) -> Function


        Extra doc: https://github.com/casadi/casadi/wiki/L_1w5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L485

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L896-L904




        """
        return _casadi.Function_hessian_old(self, *args)


    def sparsity_jac(self, *args) -> "casadi::Sparsity const":
        """
          [DEPRECATED] Get, if necessary generate, the sparsity of a Jacobian 

        ::

          sparsity_jac(self, str iind, int oind, bool compact, bool symmetric) -> Sparsity
          sparsity_jac(self, int iind, int oind, bool compact, bool symmetric) -> Sparsity
          sparsity_jac(self, int iind, str oind, bool compact, bool symmetric) -> Sparsity
          sparsity_jac(self, str iind, str oind, bool compact, bool symmetric) -> Sparsity

        block

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L499

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L499-L502



        .......

        ::

          sparsity_jac(self, str iind, int oind, bool compact, bool symmetric)



        [DEPRECATED] Get, if necessary generate, the sparsity of a Jacobian 
        block

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L491

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L491-L494



        .............


        .......

        ::

          sparsity_jac(self, int iind, int oind, bool compact, bool symmetric)



        [DEPRECATED] Get, if necessary generate, the sparsity of a Jacobian 
        block

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L489

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L907-L913



        .............


        .......

        ::

          sparsity_jac(self, int iind, str oind, bool compact, bool symmetric)



        [DEPRECATED] Get, if necessary generate, the sparsity of a Jacobian 
        block

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L495

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L495-L498



        .............


        .......

        ::

          sparsity_jac(self, str iind, str oind, bool compact, bool symmetric)



        [DEPRECATED] Get, if necessary generate, the sparsity of a Jacobian 
        block

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L499

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L499-L502



        .............



        """
        return _casadi.Function_sparsity_jac(self, *args)


    def jacobian(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          jacobian(self) -> Function

        Calculate all Jacobian blocks.

        Generates a function that takes all non-differentiated inputs and 
        outputs 
        and calculates all Jacobian blocks. Inputs that are not needed
         by the 
        routine are all-zero sparse matrices with the correct 
        dimensions.  Output 
        blocks that are not calculated, e.g. if the corresponding input or 
        output 
        is marked non-differentiated are also all-zero sparse. The 
        Jacobian blocks 
        are sorted starting by all the blocks for the first 
        output, then all the 
        blocks for the second output and so on. E.g. f : 
        (x, y) -> (r, s) results 
        in the function jac_f : (x, y, out_r, out_s) 
        -> (jac_r_x, jac_r_y, jac_s_x,
         jac_s_y)

        This function is cached.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w6

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L522

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L916-L922




        """
        return _casadi.Function_jacobian(self, *args)


    def call(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          call(self, dict:DM arg, bool always_inline, bool never_inline) -> dict:DM
          call(self, [DM] arg, bool always_inline, bool never_inline) -> [DM]
          call(self, [SX] arg, bool always_inline, bool never_inline) -> [SX]
          call(self, dict:SX arg, bool always_inline, bool never_inline) -> dict:SX
          call(self, dict:MX arg, bool always_inline, bool never_inline) -> dict:MX
          call(self, [MX] arg, bool always_inline, bool never_inline) -> [MX]

        Evaluate the function symbolically or numerically.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L538

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1480-L1487



        .......

        ::

          call(self, dict:DM arg, bool always_inline, bool never_inline)



        [INTERNAL] 
        Evaluate the function symbolically or numerically.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L534

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1462-L1469



        .............


        .......

        ::

          call(self, [DM] arg, bool always_inline, bool never_inline)



        [INTERNAL] 
        Evaluate the function symbolically or numerically.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L528

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L357-L364



        .............


        .......

        ::

          call(self, [SX] arg, bool always_inline, bool never_inline)



        [INTERNAL] 
        Evaluate the function symbolically or numerically.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L530

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L366-L373



        .............


        .......

        ::

          call(self, dict:SX arg, bool always_inline, bool never_inline)



        [INTERNAL] 
        Evaluate the function symbolically or numerically.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L536

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1471-L1478



        .............


        .......

        ::

          call(self, dict:MX arg, bool always_inline, bool never_inline)



        [INTERNAL] 
        Evaluate the function symbolically or numerically.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L538

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1480-L1487



        .............


        .......

        ::

          call(self, [MX] arg, bool always_inline, bool never_inline)



        [INTERNAL] 
        Evaluate the function symbolically or numerically.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L532

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L375-L382



        .............



        """
        return _casadi.Function_call(self, *args)


    def mapsum(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          mapsum(self, [MX] x, str parallelization) -> [MX]

        Evaluate symbolically in parallel and sum (matrix graph)

        Parameters:
        -----------

        parallelization: 
        Type of parallelization used: unroll|serial|openmp

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L656

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L756-L763




        """
        return _casadi.Function_mapsum(self, *args)


    def mapaccum(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          mapaccum(self, int N, dict opts) -> Function
          mapaccum(self, str name, int N, dict opts) -> Function
          mapaccum(self, str name, int N, int n_accum, dict opts) -> Function
          mapaccum(self, str name, int n, [str] accum_in, [str] accum_out, dict opts) -> Function
          mapaccum(self, str name, int n, [int] accum_in, [int] accum_out, dict opts) -> Function

        Create a mapaccumulated version of this function.

        Suppose the function has a signature of:

        ::

             f: (x, u) -> (x_next , y )




        The the mapaccumulated version has the signature:

        ::

             F: (x0, U) -> (X , Y )

              with
                  U: horzcat([u0, u1, ..., u_(N-1)])
                  X: horzcat([x1, x2, ..., x_N])
                  Y: horzcat([y0, y1, ..., y_(N-1)])

              and
                  x1, y0 <- f(x0, u0)
                  x2, y1 <- f(x1, u1)
                  ...
                  x_N, y_(N-1) <- f(x_(N-1), u_(N-1))




        Mapaccum has the following benefits over writing an equivalent for-
        loop:

        much faster at construction time

        potentially much faster compilation times (for codegen)

        offers a trade-off between memory and evaluation time

        The base (settable through the options dictionary, default 10), is 
        used to 
        create a tower of function calls, containing unrolled for-
        loops of length 
        maximum base.

        This technique is much more scalable in terms of memory-usage, but 
        slightly
         slower at evaluation, than a plain for-loop. The effect is 
        similar to that
         of a for-loop with a check-pointing instruction after 
        each chunk of 
        iterations with size base.

        Set base to -1 to unroll all the way; no gains in memory efficiency 
        here.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wi

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L711

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L516-L518



        .......

        ::

          mapaccum(self, int N, dict opts)



        [INTERNAL] 
        Create a mapaccumulated version of this function.

        Suppose the function has a signature of:

        ::

             f: (x, u) -> (x_next , y )




        The the mapaccumulated version has the signature:

        ::

             F: (x0, U) -> (X , Y )

              with
                  U: horzcat([u0, u1, ..., u_(N-1)])
                  X: horzcat([x1, x2, ..., x_N])
                  Y: horzcat([y0, y1, ..., y_(N-1)])

              and
                  x1, y0 <- f(x0, u0)
                  x2, y1 <- f(x1, u1)
                  ...
                  x_N, y_(N-1) <- f(x_(N-1), u_(N-1))




        Mapaccum has the following benefits over writing an equivalent for-
        loop:

        much faster at construction time

        potentially much faster compilation times (for codegen)

        offers a trade-off between memory and evaluation time

        The base (settable through the options dictionary, default 10), is 
        used to 
        create a tower of function calls, containing unrolled for-
        loops of length 
        maximum base.

        This technique is much more scalable in terms of memory-usage, but 
        slightly
         slower at evaluation, than a plain for-loop. The effect is 
        similar to that
         of a for-loop with a check-pointing instruction after 
        each chunk of 
        iterations with size base.

        Set base to -1 to unroll all the way; no gains in memory efficiency 
        here.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wi

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L711

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L516-L518



        .............


        .......

        ::

          mapaccum(self, str name, int N, dict opts)



        [INTERNAL] 
        Create a mapaccumulated version of this function.

        Suppose the function has a signature of:

        ::

             f: (x, u) -> (x_next , y )




        The the mapaccumulated version has the signature:

        ::

             F: (x0, U) -> (X , Y )

              with
                  U: horzcat([u0, u1, ..., u_(N-1)])
                  X: horzcat([x1, x2, ..., x_N])
                  Y: horzcat([y0, y1, ..., y_(N-1)])

              and
                  x1, y0 <- f(x0, u0)
                  x2, y1 <- f(x1, u1)
                  ...
                  x_N, y_(N-1) <- f(x_(N-1), u_(N-1))




        Mapaccum has the following benefits over writing an equivalent for-
        loop:

        much faster at construction time

        potentially much faster compilation times (for codegen)

        offers a trade-off between memory and evaluation time

        The base (settable through the options dictionary, default 10), is 
        used to 
        create a tower of function calls, containing unrolled for-
        loops of length 
        maximum base.

        This technique is much more scalable in terms of memory-usage, but 
        slightly
         slower at evaluation, than a plain for-loop. The effect is 
        similar to that
         of a for-loop with a check-pointing instruction after 
        each chunk of 
        iterations with size base.

        Set base to -1 to unroll all the way; no gains in memory efficiency 
        here.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wi

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L700

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L519-L521



        .............


        .......

        ::

          mapaccum(self, str name, int N, int n_accum, dict opts)



        [INTERNAL] 
        Create a mapaccumulated version of this function.

        Suppose the function has a signature of:

        ::

             f: (x, u) -> (x_next , y )




        The the mapaccumulated version has the signature:

        ::

             F: (x0, U) -> (X , Y )

              with
                  U: horzcat([u0, u1, ..., u_(N-1)])
                  X: horzcat([x1, x2, ..., x_N])
                  Y: horzcat([y0, y1, ..., y_(N-1)])

              and
                  x1, y0 <- f(x0, u0)
                  x2, y1 <- f(x1, u1)
                  ...
                  x_N, y_(N-1) <- f(x_(N-1), u_(N-1))




        Mapaccum has the following benefits over writing an equivalent for-
        loop:

        much faster at construction time

        potentially much faster compilation times (for codegen)

        offers a trade-off between memory and evaluation time

        The base (settable through the options dictionary, default 10), is 
        used to 
        create a tower of function calls, containing unrolled for-
        loops of length 
        maximum base.

        This technique is much more scalable in terms of memory-usage, but 
        slightly
         slower at evaluation, than a plain for-loop. The effect is 
        similar to that
         of a for-loop with a check-pointing instruction after 
        each chunk of 
        iterations with size base.

        Set base to -1 to unroll all the way; no gains in memory efficiency 
        here.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wi

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L701

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L522-L550



        .............


        .......

        ::

          mapaccum(self, str name, int n, [str] accum_in, [str] accum_out, dict opts)



        [INTERNAL] 
        Create a mapaccumulated version of this function.

        Suppose the function has a signature of:

        ::

             f: (x, u) -> (x_next , y )




        The the mapaccumulated version has the signature:

        ::

             F: (x0, U) -> (X , Y )

              with
                  U: horzcat([u0, u1, ..., u_(N-1)])
                  X: horzcat([x1, x2, ..., x_N])
                  Y: horzcat([y0, y1, ..., y_(N-1)])

              and
                  x1, y0 <- f(x0, u0)
                  x2, y1 <- f(x1, u1)
                  ...
                  x_N, y_(N-1) <- f(x_(N-1), u_(N-1))




        Mapaccum has the following benefits over writing an equivalent for-
        loop:

        much faster at construction time

        potentially much faster compilation times (for codegen)

        offers a trade-off between memory and evaluation time

        The base (settable through the options dictionary, default 10), is 
        used to 
        create a tower of function calls, containing unrolled for-
        loops of length 
        maximum base.

        This technique is much more scalable in terms of memory-usage, but 
        slightly
         slower at evaluation, than a plain for-loop. The effect is 
        similar to that
         of a for-loop with a check-pointing instruction after 
        each chunk of 
        iterations with size base.

        Set base to -1 to unroll all the way; no gains in memory efficiency 
        here.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wi

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L707

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L627-L635



        .............


        .......

        ::

          mapaccum(self, str name, int n, [int] accum_in, [int] accum_out, dict opts)



        [INTERNAL] 
        Create a mapaccumulated version of this function.

        Suppose the function has a signature of:

        ::

             f: (x, u) -> (x_next , y )




        The the mapaccumulated version has the signature:

        ::

             F: (x0, U) -> (X , Y )

              with
                  U: horzcat([u0, u1, ..., u_(N-1)])
                  X: horzcat([x1, x2, ..., x_N])
                  Y: horzcat([y0, y1, ..., y_(N-1)])

              and
                  x1, y0 <- f(x0, u0)
                  x2, y1 <- f(x1, u1)
                  ...
                  x_N, y_(N-1) <- f(x_(N-1), u_(N-1))




        Mapaccum has the following benefits over writing an equivalent for-
        loop:

        much faster at construction time

        potentially much faster compilation times (for codegen)

        offers a trade-off between memory and evaluation time

        The base (settable through the options dictionary, default 10), is 
        used to 
        create a tower of function calls, containing unrolled for-
        loops of length 
        maximum base.

        This technique is much more scalable in terms of memory-usage, but 
        slightly
         slower at evaluation, than a plain for-loop. The effect is 
        similar to that
         of a for-loop with a check-pointing instruction after 
        each chunk of 
        iterations with size base.

        Set base to -1 to unroll all the way; no gains in memory efficiency 
        here.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wi

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L703

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L597-L625



        .............



        """
        return _casadi.Function_mapaccum(self, *args)


    def fold(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          fold(self, int N, dict opts) -> Function

        Create a mapaccumulated version of this function.

        Suppose the function has a signature of:

        ::

             f: (x, u) -> (x_next , y )




        The the mapaccumulated version has the signature:

        ::

             F: (x0, U) -> (X , Y )

              with
                  U: horzcat([u0, u1, ..., u_(N-1)])
                  X: horzcat([x1, x2, ..., x_N])
                  Y: horzcat([y0, y1, ..., y_(N-1)])

              and
                  x1, y0 <- f(x0, u0)
                  x2, y1 <- f(x1, u1)
                  ...
                  x_N, y_(N-1) <- f(x_(N-1), u_(N-1))




        Mapaccum has the following benefits over writing an equivalent for-
        loop:

        much faster at construction time

        potentially much faster compilation times (for codegen)

        offers a trade-off between memory and evaluation time

        The base (settable through the options dictionary, default 10), is 
        used to 
        create a tower of function calls, containing unrolled for-
        loops of length 
        maximum base.

        This technique is much more scalable in terms of memory-usage, but 
        slightly
         slower at evaluation, than a plain for-loop. The effect is 
        similar to that
         of a for-loop with a check-pointing instruction after 
        each chunk of 
        iterations with size base.

        Set base to -1 to unroll all the way; no gains in memory efficiency 
        here.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wi

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L712

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L509-L515




        """
        return _casadi.Function_fold(self, *args)


    def map(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          map(self, int n, str parallelization) -> Function
          map(self, int n, [bool] reduce_in, [bool] reduce_out, dict opts) -> Function
          map(self, int n, str parallelization, int max_num_threads) -> Function
          map(self, str name, str parallelization, int n, [str] reduce_in, [str] reduce_out, dict opts) -> Function
          map(self, str name, str parallelization, int n, [int] reduce_in, [int] reduce_out, dict opts) -> Function

        Map with reduction.

        A subset of the inputs are non-repeated and a subset of the outputs 
        summed 
        up.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wk

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L759

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L637-L643



        .......

        ::

          map(self, int n, [bool] reduce_in, [bool] reduce_out, dict opts)



        [INTERNAL] 
        Map with reduction.

        A subset of the inputs are non-repeated and a subset of the outputs 
        summed 
        up.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wk

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L759

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L637-L643



        .............


        .......

        ::

          map(self, str name, str parallelization, int n, [str] reduce_in, [str] reduce_out, dict opts)



        [INTERNAL] 
        Map with reduction.

        A subset of the inputs are non-repeated and a subset of the outputs 
        summed 
        up.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wk

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L755

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L668-L675



        .............


        .......

        ::

          map(self, str name, str parallelization, int n, [int] reduce_in, [int] reduce_out, dict opts)



        [INTERNAL] 
        Map with reduction.

        A subset of the inputs are non-repeated and a subset of the outputs 
        summed 
        up.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wk

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L751

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L645-L666



        .............


        .......

        ::

          map(self, int n, str parallelization, int max_num_threads)



        [INTERNAL] 

        .............


        .......

        ::

          map(self, int n, str parallelization)



        [INTERNAL] 
        Create a mapped version of this function.

        Suppose the function has a signature of:

        ::

             f: (a, p) -> ( s )




        The the mapped version has the signature:

        ::

             F: (A, P) -> (S )

              with
                  A: horzcat([a0, a1, ..., a_(N-1)])
                  P: horzcat([p0, p1, ..., p_(N-1)])
                  S: horzcat([s0, s1, ..., s_(N-1)])
              and
                  s0 <- f(a0, p0)
                  s1 <- f(a1, p1)
                  ...
                  s_(N-1) <- f(a_(N-1), p_(N-1))




        Parameters:
        -----------

        parallelization: 
        Type of parallelization used: unroll|serial|openmp

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wj

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L740

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L709-L744



        .............



        """
        return _casadi.Function_map(self, *args)


    def slice(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          slice(self, str name, [int] order_in, [int] order_out, dict opts) -> Function

        returns a new function with a selection of inputs/outputs of the

        original

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wl

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L768

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L747-L754




        """
        return _casadi.Function_slice(self, *args)


    def conditional(*args) -> "casadi::Function":
        """


        ::

          conditional(str name, Function f, dict opts) -> Function
          conditional(str name, [Function] f, Function f_def, dict opts) -> Function



        """
        return _casadi.Function_conditional(*args)

    conditional = staticmethod(conditional)

    def bspline(*args) -> "casadi::Function":
        """


        ::

          bspline(str name, [[float]] knots, [float] coeffs, [int] degree, int m, dict opts) -> Function



        """
        return _casadi.Function_bspline(*args)

    bspline = staticmethod(bspline)

    def if_else(*args) -> "casadi::Function":
        """


        ::

          if_else(str name, Function f_true, Function f_false, dict opts) -> Function



        """
        return _casadi.Function_if_else(*args)

    if_else = staticmethod(if_else)

    def forward(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          forward(self, int nfwd) -> Function

        Get a function that calculates  nfwd forward derivatives.



        ::

             Returns a function with <tt>n_in + n_out + n_in</tt> inputs
             and <tt>nfwd</tt> outputs.
             The first <tt>n_in</tt> inputs correspond to nondifferentiated inputs.
             The next <tt>n_out</tt> inputs correspond to nondifferentiated outputs.
             and the last <tt>n_in</tt> inputs correspond to forward seeds,
             stacked horizontally
             The  <tt>n_out</tt> outputs correspond to forward sensitivities,
             stacked horizontally.     *
             <tt>(n_in = n_in(), n_out = n_out())</tt>

            The functions returned are cached, meaning that if called multiple timed
            with the same value, then multiple references to the same function will be returned.


        Extra doc: https://github.com/casadi/casadi/wiki/L_1wq

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L814

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1135-L1141




        """
        return _casadi.Function_forward(self, *args)


    def reverse(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          reverse(self, int nadj) -> Function

        Get a function that calculates  nadj adjoint derivatives.



        ::

             Returns a function with <tt>n_in + n_out + n_out</tt> inputs
             and <tt>n_in</tt> outputs.
             The first <tt>n_in</tt> inputs correspond to nondifferentiated inputs.
             The next <tt>n_out</tt> inputs correspond to nondifferentiated outputs.
             and the last <tt>n_out</tt> inputs correspond to adjoint seeds,
             stacked horizontally
             The  <tt>n_in</tt> outputs correspond to adjoint sensitivities,
             stacked horizontally.     *
             <tt>(n_in = n_in(), n_out = n_out())</tt>

             <tt>(n_in = n_in(), n_out = n_out())</tt>

            The functions returned are cached, meaning that if called multiple timed
            with the same value, then multiple references to the same function will be returned.


        Extra doc: https://github.com/casadi/casadi/wiki/L_1wr

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L834

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1143-L1149




        """
        return _casadi.Function_reverse(self, *args)


    def jac_sparsity(self, *args) -> "casadi::Sparsity":
        """
          [INTERNAL] 

        ::

          jac_sparsity(self, bool compact) -> [Sparsity]
          jac_sparsity(self, int oind, int iind, bool compact) -> Sparsity

        Get, if necessary generate, the sparsity of a single Jacobian 
        block.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wt

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L844

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L951-L959



        .......

        ::

          jac_sparsity(self, bool compact)



        [INTERNAL] 
        Get, if necessary generate, the sparsity of all Jacobian blocks.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ws

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L839

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L940-L949



        .............


        .......

        ::

          jac_sparsity(self, int oind, int iind, bool compact)



        [INTERNAL] 
        Get, if necessary generate, the sparsity of a single Jacobian 
        block.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wt

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L844

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L951-L959



        .............



        """
        return _casadi.Function_jac_sparsity(self, *args)


    def generate(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          generate(self, dict opts) -> str
          generate(self, str fname, dict opts) -> str

        Export / Generate C code for the function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wv

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L854

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1197-L1199



        .......

        ::

          generate(self, dict opts)



        [INTERNAL] 
        Export / Generate C code for the function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wv

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L854

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1197-L1199



        .............


        .......

        ::

          generate(self, str fname, dict opts)



        [INTERNAL] 
        Export / Generate C code for the function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wu

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L849

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1201-L1205



        .............



        """
        return _casadi.Function_generate(self, *args)


    def generate_dependencies(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          generate_dependencies(self, str fname, dict opts) -> str

        Export / Generate C code for the dependency function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ww

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L859

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1207-L1209




        """
        return _casadi.Function_generate_dependencies(self, *args)


    def generate_in(self, *args) -> "std::vector< casadi::DM,std::allocator< casadi::DM > >":
        """
          [INTERNAL] 

        ::

          generate_in(self, str fname) -> [DM]
          generate_in(self, str fname, [DM] arg)

        Export an input file that can be passed to generate C code with 
        a 
        main.

        See: 
         generate_out

        See: 
         convert_in to convert between dict/map and vector

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wx

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L869

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1241-L1251



        .......

        ::

          generate_in(self, str fname)



        [INTERNAL] 
        Export an input file that can be passed to generate C code with 
        a 
        main.

        See: 
         generate_out

        See: 
         convert_in to convert between dict/map and vector

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wx

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L869

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1241-L1251



        .............


        .......

        ::

          generate_in(self, str fname, [DM] arg)



        [INTERNAL] 
        Export an input file that can be passed to generate C code with 
        a 
        main.

        See: 
         generate_out

        See: 
         convert_in to convert between dict/map and vector

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wx

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L868

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1211-L1224



        .............



        """
        return _casadi.Function_generate_in(self, *args)


    def generate_out(self, *args) -> "std::vector< casadi::DM,std::allocator< casadi::DM > >":
        """
          [INTERNAL] 

        ::

          generate_out(self, str fname) -> [DM]
          generate_out(self, str fname, [DM] arg)

        Export an output file that can be checked with generated C code

        output.

        See: 
         generate_in

        See: 
         convert_out to convert between dict/map and vector

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wy

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L880

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1253-L1263



        .......

        ::

          generate_out(self, str fname)



        [INTERNAL] 
        Export an output file that can be checked with generated C code

        output.

        See: 
         generate_in

        See: 
         convert_out to convert between dict/map and vector

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wy

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L880

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1253-L1263



        .............


        .......

        ::

          generate_out(self, str fname, [DM] arg)



        [INTERNAL] 
        Export an output file that can be checked with generated C code

        output.

        See: 
         generate_in

        See: 
         convert_out to convert between dict/map and vector

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wy

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L879

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1226-L1239



        .............



        """
        return _casadi.Function_generate_out(self, *args)


    def serialize(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          serialize(self, dict opts) -> str

        Serialize.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x2

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L907

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1283-L1287




        """
        return _casadi.Function_serialize(self, *args)


    def save(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          save(self, str fname, dict opts)

        Save  Function to a file.

        See: 
         load

        Extra doc: https://github.com/casadi/casadi/wiki/L_240

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L914

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1278-L1281




        """
        return _casadi.Function_save(self, *args)


    def export_code(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          export_code(self, str lang, dict options) -> str
          export_code(self, str lang, str fname, dict options)

        Export function in specific language.

        Only allowed for (a subset of) SX/MX Functions

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wz

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L916

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1310-L1314



        .......

        ::

          export_code(self, str lang, dict options)



        [INTERNAL] 
        Export function in specific language.

        Only allowed for (a subset of) SX/MX Functions

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wz

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L916

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1310-L1314



        .............


        .......

        ::

          export_code(self, str lang, str fname, dict options)



        [INTERNAL] 
        Export function in specific language.

        Only allowed for (a subset of) SX/MX Functions

        Extra doc: https://github.com/casadi/casadi/wiki/L_1wz

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L889

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1270-L1275



        .............



        """
        return _casadi.Function_export_code(self, *args)


    def stats(self, *args) -> "casadi::Dict":
        """
          [INTERNAL] 

        ::

          stats(self, int mem) -> dict

        Get all statistics obtained at the end of the last evaluate 
        call.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L946

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L928-L938




        """
        return _casadi.Function_stats(self, *args)


    def sx_in(self, *args) -> "std::vector< casadi::SX,std::allocator< casadi::SX > > const":
        """
          [INTERNAL] 

        ::

          sx_in(self) -> [SX]
          sx_in(self, int iind) -> SX
          sx_in(self, str iname) -> SX

        Get symbolic primitives equivalent to the input expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L958

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1577-L1583



        .......

        ::

          sx_in(self)



        [INTERNAL] 
        Get symbolic primitives equivalent to the input expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L958

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1577-L1583



        .............


        .......

        ::

          sx_in(self, int iind)



        [INTERNAL] 
        Get symbolic primitives equivalent to the input expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L954

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1561-L1567



        .............


        .......

        ::

          sx_in(self, str iname)



        [INTERNAL] 
        Get symbolic primitives equivalent to the input expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L955

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L955-L957



        .............



        """
        return _casadi.Function_sx_in(self, *args)


    def mx_in(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > > const":
        """
          [INTERNAL] 

        ::

          mx_in(self) -> [MX]
          mx_in(self, int ind) -> MX
          mx_in(self, str iname) -> MX

        Get symbolic primitives equivalent to the input expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L963

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1601-L1603



        .......

        ::

          mx_in(self)



        [INTERNAL] 
        Get symbolic primitives equivalent to the input expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L963

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1601-L1603



        .............


        .......

        ::

          mx_in(self, int ind)



        [INTERNAL] 
        Get symbolic primitives equivalent to the input expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L959

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1593-L1595



        .............


        .......

        ::

          mx_in(self, str iname)



        [INTERNAL] 
        Get symbolic primitives equivalent to the input expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L960

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L960-L962



        .............



        """
        return _casadi.Function_mx_in(self, *args)


    def sx_out(self, *args) -> "std::vector< casadi::SX,std::allocator< casadi::SX > > const":
        """
          [INTERNAL] 

        ::

          sx_out(self) -> [SX]
          sx_out(self, int oind) -> SX
          sx_out(self, str oname) -> SX

        Get symbolic primitives equivalent to the output expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L976

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1585-L1591



        .......

        ::

          sx_out(self)



        [INTERNAL] 
        Get symbolic primitives equivalent to the output expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L976

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1585-L1591



        .............


        .......

        ::

          sx_out(self, int oind)



        [INTERNAL] 
        Get symbolic primitives equivalent to the output expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L972

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1569-L1575



        .............


        .......

        ::

          sx_out(self, str oname)



        [INTERNAL] 
        Get symbolic primitives equivalent to the output expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L973

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L973-L975



        .............



        """
        return _casadi.Function_sx_out(self, *args)


    def mx_out(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > > const":
        """
          [INTERNAL] 

        ::

          mx_out(self) -> [MX]
          mx_out(self, int ind) -> MX
          mx_out(self, str oname) -> MX

        Get symbolic primitives equivalent to the output expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L981

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1605-L1607



        .......

        ::

          mx_out(self)



        [INTERNAL] 
        Get symbolic primitives equivalent to the output expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L981

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1605-L1607



        .............


        .......

        ::

          mx_out(self, int ind)



        [INTERNAL] 
        Get symbolic primitives equivalent to the output expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L977

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1597-L1599



        .............


        .......

        ::

          mx_out(self, str oname)



        [INTERNAL] 
        Get symbolic primitives equivalent to the output expressions.

        There is no guarantee that subsequent calls return unique answers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L978

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L978-L980



        .............



        """
        return _casadi.Function_mx_out(self, *args)


    def nz_from_in(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          nz_from_in(self, [DM] arg) -> [float]

        Convert from/to flat vector of input/output nonzeros.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x6

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L988

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1609-L1611




        """
        return _casadi.Function_nz_from_in(self, *args)


    def nz_from_out(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          nz_from_out(self, [DM] arg) -> [float]

        Convert from/to flat vector of input/output nonzeros.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x6

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L989

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1613-L1615




        """
        return _casadi.Function_nz_from_out(self, *args)


    def nz_to_in(self, *args) -> "std::vector< casadi::DM,std::allocator< casadi::DM > >":
        """
          [INTERNAL] 

        ::

          nz_to_in(self, [float] arg) -> [DM]

        Convert from/to flat vector of input/output nonzeros.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x6

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L990

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1617-L1619




        """
        return _casadi.Function_nz_to_in(self, *args)


    def nz_to_out(self, *args) -> "std::vector< casadi::DM,std::allocator< casadi::DM > >":
        """
          [INTERNAL] 

        ::

          nz_to_out(self, [float] arg) -> [DM]

        Convert from/to flat vector of input/output nonzeros.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x6

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L991

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1621-L1623




        """
        return _casadi.Function_nz_to_out(self, *args)


    def convert_in(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          convert_in(self, dict:DM arg) -> [DM]
          convert_in(self, [DM] arg) -> dict:DM
          convert_in(self, [SX] arg) -> dict:SX
          convert_in(self, dict:SX arg) -> [SX]
          convert_in(self, dict:MX arg) -> [MX]
          convert_in(self, [MX] arg) -> dict:MX

        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1010

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1661-L1663



        .......

        ::

          convert_in(self, dict:DM arg)



        [INTERNAL] 
        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1002

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1629-L1631



        .............


        .......

        ::

          convert_in(self, [DM] arg)



        [INTERNAL] 
        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1001

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1625-L1627



        .............


        .......

        ::

          convert_in(self, [SX] arg)



        [INTERNAL] 
        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1005

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1641-L1643



        .............


        .......

        ::

          convert_in(self, dict:SX arg)



        [INTERNAL] 
        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1006

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1645-L1647



        .............


        .......

        ::

          convert_in(self, dict:MX arg)



        [INTERNAL] 
        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1010

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1661-L1663



        .............


        .......

        ::

          convert_in(self, [MX] arg)



        [INTERNAL] 
        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1009

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1657-L1659



        .............



        """
        return _casadi.Function_convert_in(self, *args)


    def convert_out(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          convert_out(self, dict:DM arg) -> [DM]
          convert_out(self, [DM] arg) -> dict:DM
          convert_out(self, [SX] arg) -> dict:SX
          convert_out(self, dict:SX arg) -> [SX]
          convert_out(self, dict:MX arg) -> [MX]
          convert_out(self, [MX] arg) -> dict:MX

        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1012

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1669-L1671



        .......

        ::

          convert_out(self, dict:DM arg)



        [INTERNAL] 
        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1004

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1637-L1639



        .............


        .......

        ::

          convert_out(self, [DM] arg)



        [INTERNAL] 
        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1003

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1633-L1635



        .............


        .......

        ::

          convert_out(self, [SX] arg)



        [INTERNAL] 
        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1007

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1649-L1651



        .............


        .......

        ::

          convert_out(self, dict:SX arg)



        [INTERNAL] 
        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1008

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1653-L1655



        .............


        .......

        ::

          convert_out(self, dict:MX arg)



        [INTERNAL] 
        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1012

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1669-L1671



        .............


        .......

        ::

          convert_out(self, [MX] arg)



        [INTERNAL] 
        Convert from/to input/output lists/map.

        Will raise an error when an unknown key is used or a list has 
        incorrect 
        size. Does not perform sparsity checking.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1011

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1665-L1667



        .............



        """
        return _casadi.Function_convert_out(self, *args)


    def has_free(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_free(self) -> bool

        Does the function have free variables.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1018

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1706-L1708




        """
        return _casadi.Function_has_free(self, *args)


    def get_free(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          get_free(self) -> [str]

        Get free variables as a string.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1x9

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1023

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1193-L1195




        """
        return _casadi.Function_get_free(self, *args)


    def free_sx(self, *args) -> "std::vector< casadi::SX,std::allocator< casadi::SX > >":
        """
          [INTERNAL] 

        ::

          free_sx(self) -> [SX]

        Get all the free variables of the function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xa

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1028

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1682-L1688




        """
        return _casadi.Function_free_sx(self, *args)


    def free_mx(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          free_mx(self) -> [MX]

        Get all the free variables of the function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xb

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1033

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1690-L1696




        """
        return _casadi.Function_free_mx(self, *args)


    def generate_lifted(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          generate_lifted(self) -> (Function OUTPUT, Function OUTPUT)

        Extract the functions needed for the Lifted  Newton method.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xc

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1038

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1710-L1716




        """
        return _casadi.Function_generate_lifted(self, *args)


    def n_nodes(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          n_nodes(self) -> int

        Number of nodes in the algorithm.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xd

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1044

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1774-L1780




        """
        return _casadi.Function_n_nodes(self, *args)


    def n_instructions(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          n_instructions(self) -> int

        Number of instruction in the algorithm (SXFunction/MXFunction)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xe

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1049

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1718-L1724




        """
        return _casadi.Function_n_instructions(self, *args)


    def instruction_id(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          instruction_id(self, int k) -> int

        Identifier index of the instruction (SXFunction/MXFunction)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xf

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1054

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1742-L1748




        """
        return _casadi.Function_instruction_id(self, *args)


    def instruction_input(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """
          [INTERNAL] 

        ::

          instruction_input(self, int k) -> [int]

        Locations in the work vector for the inputs of the instruction.

        (SXFunction/MXFunction)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xg

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1061

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1750-L1756




        """
        return _casadi.Function_instruction_input(self, *args)


    def instruction_constant(self, *args) -> "double":
        """
          [INTERNAL] 

        ::

          instruction_constant(self, int k) -> float

        Get the floating point output argument of an instruction 
        (SXFunction)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1066

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1758-L1764




        """
        return _casadi.Function_instruction_constant(self, *args)


    def instruction_output(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """
          [INTERNAL] 

        ::

          instruction_output(self, int k) -> [int]

        Location in the work vector for the output of the instruction.

        (SXFunction/MXFunction)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xi

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1073

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1766-L1772




        """
        return _casadi.Function_instruction_output(self, *args)


    def instruction_MX(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          instruction_MX(self, int k) -> MX

        Get the  MX node corresponding to an instruction (MXFunction)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xj

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1078

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1726-L1732




        """
        return _casadi.Function_instruction_MX(self, *args)


    def instructions_sx(self, *args) -> "casadi::SX":
        """
          [INTERNAL] 

        ::

          instructions_sx(self) -> SX

        Get the SX node corresponding to all instructions (SXFunction)

        Note: input and output instructions have no SX representation. This 
        method 
        returns nan for those instructions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xk

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1086

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1734-L1740




        """
        return _casadi.Function_instructions_sx(self, *args)


    def has_spfwd(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_spfwd(self) -> bool

        Is the class able to propagate seeds through the algorithm?

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xl

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1092

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1698-L1700




        """
        return _casadi.Function_has_spfwd(self, *args)


    def has_sprev(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_sprev(self) -> bool

        Is the class able to propagate seeds through the algorithm?

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xl

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1093

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1702-L1704




        """
        return _casadi.Function_has_sprev(self, *args)


    def sz_arg(self, *args) -> "size_t":
        """
          [INTERNAL] 

        ::

          sz_arg(self) -> size_t

        Get required length of arg field.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xm

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1099

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1083-L1083




        """
        return _casadi.Function_sz_arg(self, *args)


    def sz_res(self, *args) -> "size_t":
        """
          [INTERNAL] 

        ::

          sz_res(self) -> size_t

        Get required length of res field.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xn

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1104

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1085-L1085




        """
        return _casadi.Function_sz_res(self, *args)


    def sz_iw(self, *args) -> "size_t":
        """
          [INTERNAL] 

        ::

          sz_iw(self) -> size_t

        Get required length of iw field.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xo

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1109

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1087-L1087




        """
        return _casadi.Function_sz_iw(self, *args)


    def sz_w(self, *args) -> "size_t":
        """
          [INTERNAL] 

        ::

          sz_w(self) -> size_t

        Get required length of w field.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xp

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1114

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1089-L1089




        """
        return _casadi.Function_sz_w(self, *args)


    def name(self, *args) -> "std::string const &":
        """
          [INTERNAL] 

        ::

          name(self) -> str

        Name of the function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xv

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1157

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1316-L1323




        """
        return _casadi.Function_name(self, *args)


    def is_a(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_a(self, str type, bool recursive) -> bool

        Check if the function is of a particular type.

        Optionally check if name matches one of the base classes (default 
        true)

        Extra doc: https://github.com/casadi/casadi/wiki/L_1xw

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1164

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1673-L1675




        """
        return _casadi.Function_is_a(self, *args)


    def check_name(*args) -> "bool":
        """


        ::

          check_name(str name) -> bool



        """
        return _casadi.Function_check_name(*args)

    check_name = staticmethod(check_name)

    def fix_name(*args) -> "std::string":
        """


        ::

          fix_name(str name) -> str



        """
        return _casadi.Function_fix_name(*args)

    fix_name = staticmethod(fix_name)

    def load(*args) -> "casadi::Function":
        """


        ::

          load(str filename) -> Function



        """
        return _casadi.Function_load(*args)

    load = staticmethod(load)

    def deserialize(*args) -> "casadi::Function":
        """


        ::

          deserialize(std::istream & stream) -> Function
          deserialize(casadi::DeserializingStream & s) -> Function
          deserialize(str s) -> Function



        """
        return _casadi.Function_deserialize(*args)

    deserialize = staticmethod(deserialize)

    def assert_size_in(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          assert_size_in(self, int i, int nrow, int ncol)

        Assert that an input dimension is equal so some given value.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1209

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1794-L1800




        """
        return _casadi.Function_assert_size_in(self, *args)


    def assert_size_out(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          assert_size_out(self, int i, int nrow, int ncol)

        Assert that an output dimension is equal so some given value.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1212

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1802-L1807




        """
        return _casadi.Function_assert_size_out(self, *args)


    def assert_sparsity_out(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          assert_sparsity_out(self, int i, Sparsity sp, int n, bool allow_all_zero_sparse)

        Assert that an output sparsity is a multiple of some given 
        sparsity.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1215

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1809-L1818




        """
        return _casadi.Function_assert_sparsity_out(self, *args)


    def checkout(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          checkout(self) -> int

        Checkout a memory object.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1219

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1782-L1784




        """
        return _casadi.Function_checkout(self, *args)


    def release(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          release(self, int mem)

        Release a memory object.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1222

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1786-L1788




        """
        return _casadi.Function_release(self, *args)


    def cache(self, *args) -> "casadi::Dict":
        """
          [INTERNAL] 

        ::

          cache(self) -> dict

        Get all functions in the cache.

        Extra doc: https://github.com/casadi/casadi/wiki/L_26i

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1235

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1844-L1851




        """
        return _casadi.Function_cache(self, *args)


    def get_function(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          get_function(self) -> [str]
          get_function(self, str name) -> Function

        Get a dependency function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1y4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1245

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1862-L1868



        .......

        ::

          get_function(self, str name)



        [INTERNAL] 
        Get a dependency function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1y4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1245

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1862-L1868



        .............


        .......

        ::

          get_function(self)



        [INTERNAL] 
        Get a list of all functions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1y3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1240

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1853-L1860



        .............



        """
        return _casadi.Function_get_function(self, *args)


    def has_function(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_function(self, str fname) -> bool

        Check if a particular dependency exists.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1y5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1250

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1870-L1877




        """
        return _casadi.Function_has_function(self, *args)


    def find_functions(self, *args) -> "std::vector< casadi::Function,std::allocator< casadi::Function > >":
        """
          [INTERNAL] 

        ::

          find_functions(self, int max_depth) -> [Function]

        Get all functions embedded in the expression graphs.

        Parameters:
        -----------

        max_depth: 
        Maximum depth - a negative number indicates no maximum

        Extra doc: https://github.com/casadi/casadi/wiki/L_1y6

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1257

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1879-L1895




        """
        return _casadi.Function_find_functions(self, *args)


    def find_function(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          find_function(self, str name, int max_depth) -> Function

        Get a specific function embedded in the expression graphs.

        Parameters:
        -----------

        name: 
        Name of function needed

        max_depth: 
        Maximum depth - a negative number indicates no maximum

        Extra doc: https://github.com/casadi/casadi/wiki/L_1y7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1265

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1897-L1914




        """
        return _casadi.Function_find_function(self, *args)


    def info(self, *args) -> "casadi::Dict":
        """
          [INTERNAL] 

        ::

          info(self) -> dict

        Obtain information about function

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1268

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1943-L1945




        """
        return _casadi.Function_info(self, *args)


    def __setstate__(self, state):
        self.__init__(Function.deserialize(state["serialization"]))

    def __getstate__(self):
        return {"serialization": self.serialize()}


    def __call__(self, *args, **kwargs):
    # Either named inputs or ordered inputs
      if len(args)>0 and len(kwargs)>0:
        raise SyntaxError('Function evaluation requires all arguments to be named or none')
      if len(args)>0:
    # Ordered inputs -> return tuple
        ret = self.call(args)
        if len(ret)==0:
          return None
        elif len(ret)==1:
          return ret[0]
        else:
          return tuple(ret)
      else:
    # Named inputs -> return dictionary
        return self.call(kwargs)

    def buffer(self):
      """
      Create a FunctionBuffer object for evaluating with minimal overhead

      """
      import functools
      fb = FunctionBuffer(self)
      caller = functools.partial(_casadi._function_buffer_eval, fb._self())
      return (fb, caller)


    def __init__(self, *args):
        """


        ::

          Function()
          Function(str fname)
          Function(Function other)
          Function(str name, [SX] ex_in, [SX] ex_out, dict opts)
          Function(str name, [MX] ex_in, [MX] ex_out, dict opts)
          Function(str name, dict:SX dict, [str] name_in, [str] name_out, dict opts)
          Function(str name, dict:MX dict, [str] name_in, [str] name_out, dict opts)
          Function(str name, [SX] ex_in, [SX] ex_out, [str] name_in, [str] name_out, dict opts)
          Function(str name, [MX] ex_in, [MX] ex_out, [str] name_in, [str] name_out, dict opts)


        .......

        ::

          Function(Function other)



        .............


        .......

        ::

          Function(str name, [MX] ex_in, [MX] ex_out, dict opts)



        [INTERNAL] 
        Construct an  MX function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L101

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L110-L114



        .............


        .......

        ::

          Function(str name, dict:MX dict, [str] name_in, [str] name_out, dict opts)



        [INTERNAL] 
        Construct an  MX function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L111

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L189-L193



        .............


        .......

        ::

          Function(str name, [MX] ex_in, [MX] ex_out, [str] name_in, [str] name_out, dict opts)



        [INTERNAL] 
        Construct an  MX function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L105

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L116-L122



        .............


        .......

        ::

          Function()



        [INTERNAL] 
        Default constructor, null pointer.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1uy

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L70

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L58-L59



        .............


        .......

        ::

          Function(str name, [SX] ex_in, [SX] ex_out, dict opts)



        [INTERNAL] 
        Construct an SX function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v0

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L81

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L96-L100



        .............


        .......

        ::

          Function(str name, dict:SX dict, [str] name_in, [str] name_out, dict opts)



        [INTERNAL] 
        Construct an SX function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v0

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L91

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L183-L187



        .............


        .......

        ::

          Function(str name, [SX] ex_in, [SX] ex_out, [str] name_in, [str] name_out, dict opts)



        [INTERNAL] 
        Construct an SX function.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1v0

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L85

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L102-L108



        .............


        .......

        ::

          Function(str fname)



        [INTERNAL] 
        Construct from a file.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1uz

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L75

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L92-L94



        .............



        """
        this = _casadi.new_Function(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
Function_swigregister = _casadi.Function_swigregister
Function_swigregister(Function)

def Function_type_name(*args) -> "std::string":
    """


    ::

      type_name() -> str



    """
    return _casadi.Function_type_name(*args)

def Function_jit(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      jit(str name, str body, [str] name_in, [str] name_out, dict opts) -> Function
      jit(str name, str body, [str] name_in, [str] name_out, [Sparsity] sparsity_in, [Sparsity] sparsity_out, dict opts) -> Function

    Create a just-in-time compiled function from a C language 
    string.

    The names and sparsity patterns of all the inputs and outputs must be 

    provided. If sparsities are not provided, all inputs and outputs are 

    assumed to be scalar. Only specify the function body, assuming that 
    input 
    and output nonzeros are stored in arrays with the specified 
    naming 
    convension. The data type used is 'casadi_real', which is 
    typically equal 
    to 'double or another data type with the same API as 'double.

    Inputs may be null pointers. This means that the all entries are zero.

    Outputs may be null points. This means that the corresponding result 
    can be
     ignored.

    If an error occurs in the evaluation, issue "return 1;";

    The final generated function will have a structure similar to:

    casadi_int fname(const casadi_real** arg, casadi_real** res, 
    casadi_int* 
    iw, casadi_real* w, void* mem) { const casadi_real *x1, 
    *x2; casadi_real 
    *r1, *r2; x1 = *arg++; x2 = *arg++; r1 = *res++; r2 =
     *res++; 
    <FUNCTION_BODY> return 0; }

    Extra doc: https://github.com/casadi/casadi/wiki/L_1v3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L189

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L294-L306



    .......

    ::

      jit(str name, str body, [str] name_in, [str] name_out, dict opts)



    [INTERNAL] 
    Create a just-in-time compiled function from a C language 
    string.

    The names and sparsity patterns of all the inputs and outputs must be 

    provided. If sparsities are not provided, all inputs and outputs are 

    assumed to be scalar. Only specify the function body, assuming that 
    input 
    and output nonzeros are stored in arrays with the specified 
    naming 
    convension. The data type used is 'casadi_real', which is 
    typically equal 
    to 'double or another data type with the same API as 'double.

    Inputs may be null pointers. This means that the all entries are zero.

    Outputs may be null points. This means that the corresponding result 
    can be
     ignored.

    If an error occurs in the evaluation, issue "return 1;";

    The final generated function will have a structure similar to:

    casadi_int fname(const casadi_real** arg, casadi_real** res, 
    casadi_int* 
    iw, casadi_real* w, void* mem) { const casadi_real *x1, 
    *x2; casadi_real 
    *r1, *r2; x1 = *arg++; x2 = *arg++; r1 = *res++; r2 =
     *res++; 
    <FUNCTION_BODY> return 0; }

    Extra doc: https://github.com/casadi/casadi/wiki/L_1v3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L185

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L285-L292



    .............


    .......

    ::

      jit(str name, str body, [str] name_in, [str] name_out, [Sparsity] sparsity_in, [Sparsity] sparsity_out, dict opts)



    [INTERNAL] 
    Create a just-in-time compiled function from a C language 
    string.

    The names and sparsity patterns of all the inputs and outputs must be 

    provided. If sparsities are not provided, all inputs and outputs are 

    assumed to be scalar. Only specify the function body, assuming that 
    input 
    and output nonzeros are stored in arrays with the specified 
    naming 
    convension. The data type used is 'casadi_real', which is 
    typically equal 
    to 'double or another data type with the same API as 'double.

    Inputs may be null pointers. This means that the all entries are zero.

    Outputs may be null points. This means that the corresponding result 
    can be
     ignored.

    If an error occurs in the evaluation, issue "return 1;";

    The final generated function will have a structure similar to:

    casadi_int fname(const casadi_real** arg, casadi_real** res, 
    casadi_int* 
    iw, casadi_real* w, void* mem) { const casadi_real *x1, 
    *x2; casadi_real 
    *r1, *r2; x1 = *arg++; x2 = *arg++; r1 = *res++; r2 =
     *res++; 
    <FUNCTION_BODY> return 0; }

    Extra doc: https://github.com/casadi/casadi/wiki/L_1v3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L189

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L294-L306



    .............



    """
    return _casadi.Function_jit(*args)

def Function_conditional(*args) -> "casadi::Function":
    """


    ::

      conditional(str name, Function f, dict opts) -> Function
      conditional(str name, [Function] f, Function f_def, dict opts) -> Function



    """
    return _casadi.Function_conditional(*args)

def Function_bspline(*args) -> "casadi::Function":
    """


    ::

      bspline(str name, [[float]] knots, [float] coeffs, [int] degree, int m, dict opts) -> Function



    """
    return _casadi.Function_bspline(*args)

def Function_if_else(*args) -> "casadi::Function":
    """


    ::

      if_else(str name, Function f_true, Function f_false, dict opts) -> Function



    """
    return _casadi.Function_if_else(*args)

def Function_check_name(*args) -> "bool":
    """


    ::

      check_name(str name) -> bool



    """
    return _casadi.Function_check_name(*args)

def Function_fix_name(*args) -> "std::string":
    """


    ::

      fix_name(str name) -> str



    """
    return _casadi.Function_fix_name(*args)

def Function_load(*args) -> "casadi::Function":
    """


    ::

      load(str filename) -> Function



    """
    return _casadi.Function_load(*args)

def Function_deserialize(*args) -> "casadi::Function":
    """


    ::

      deserialize(std::istream & stream) -> Function
      deserialize(casadi::DeserializingStream & s) -> Function
      deserialize(str s) -> Function



    """
    return _casadi.Function_deserialize(*args)

class FunctionBuffer(_object):
    """
      [INTERNAL] 

    ::


    Class to achieve minimal overhead function evaluations.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1y9

    C++ includes: function.hpp



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, FunctionBuffer, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, FunctionBuffer, name)
    __repr__ = _swig_repr

    def set_arg(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_arg(self, int i, memoryview(ro) a, casadi_int size)

        Set input buffer for input i.

        mem.set_arg(0, memoryview(a))

        Note that CasADi uses 'fortran' order: column-by-column

        Extra doc: https://github.com/casadi/casadi/wiki/L_1yb

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1346

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1991-L1996




        """
        return _casadi.FunctionBuffer_set_arg(self, *args)


    def set_res(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_res(self, int i, memoryview(rw) a, casadi_int size)

        Set output buffer for ouput i.

        mem.set_res(0, memoryview(a))

        Note that CasADi uses 'fortran' order: column-by-column

        Extra doc: https://github.com/casadi/casadi/wiki/L_1yc

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1355

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1997-L2002




        """
        return _casadi.FunctionBuffer_set_res(self, *args)


    def ret(self, *args) -> "int":
        """
          [INTERNAL] 

        ::

          ret(self) -> int

        Get last return value.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1357

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L2010-L2012




        """
        return _casadi.FunctionBuffer_ret(self, *args)


    def _eval(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          _eval(self)



        """
        return _casadi.FunctionBuffer__eval(self, *args)


    def _self(self, *args) -> "void *":
        """
          [INTERNAL] 

        ::

          _self(self) -> void*



        """
        return _casadi.FunctionBuffer__self(self, *args)


    def stats(self, *args) -> "casadi::Dict":
        """
          [INTERNAL] 

        ::

          stats(self) -> dict



        """
        return _casadi.FunctionBuffer_stats(self, *args)


    def __init__(self, *args):
        """


        ::

          FunctionBuffer(FunctionBuffer other)
          FunctionBuffer(Function f)


        .......

        ::

          FunctionBuffer(FunctionBuffer other)



        .............


        .......

        ::

          FunctionBuffer(Function f)



        [INTERNAL] 
        Main constructor.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1ya

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.hpp#L1332

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/function.cpp#L1955-L1963



        .............



        """
        this = _casadi.new_FunctionBuffer(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_FunctionBuffer
FunctionBuffer_swigregister = _casadi.FunctionBuffer_swigregister
FunctionBuffer_swigregister(FunctionBuffer)


def _function_buffer_eval(*args) -> "void":
    """


    ::

      _function_buffer_eval(void* raw)



    """
    return _casadi._function_buffer_eval(*args)

def external(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      external(str name, dict opts) -> Function
      external(str name, Importer li, dict opts) -> Function
      external(str name, str bin_name, dict opts) -> Function

    Load a just-in-time compiled external function.

    File name given

    Extra doc: https://github.com/casadi/casadi/wiki/L_i2

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/external.hpp#L42

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/external.cpp#L42-L48



    .......

    ::

      external(str name, dict opts)



    [INTERNAL] 
    Load an external function from a shared library.

    Parameters:
    -----------

    name: 
    Name as in the label assigned to a CasADi  Function object: 
    Function(name,...,...) Will be used to look up 
    symbols/functions named eg. 
    <name>_eval Use  nm (linux/osx) or  depends.exe (win) to check which symbols
     are present in your shared library

    File name is assumed to be ./<name>.so

    Extra doc: https://github.com/casadi/casadi/wiki/L_i0

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/external.hpp#L50

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/external.cpp#L50-L52



    .............


    .......

    ::

      external(str name, str bin_name, dict opts)



    [INTERNAL] 
    Load an external function from a shared library.

    Parameters:
    -----------

    name: 
    Name as in the label assigned to a CasADi  Function object: 
    Function(name,...,...) Will be used to look up 
    symbols/functions named eg. 
    <name>_eval Use  nm (linux/osx) or  depends.exe (win) to check which symbols
     are present in your shared library

    bin_name: 
    File name of the shared library

    Extra doc: https://github.com/casadi/casadi/wiki/L_i1

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/external.hpp#L54

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/external.cpp#L54-L57



    .............


    .......

    ::

      external(str name, Importer li, dict opts)



    [INTERNAL] 
    Load a just-in-time compiled external function.

    File name given

    Extra doc: https://github.com/casadi/casadi/wiki/L_i2

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/external.hpp#L42

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/external.cpp#L42-L48



    .............



    """
    return _casadi.external(*args)

def integrator(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      integrator(str name, str solver, dict:SX dae, dict opts) -> Function
      integrator(str name, str solver, dict:MX dae, dict opts) -> Function
      integrator(str name, str solver, Function dae, dict opts) -> Function
      integrator(str name, str solver, dict:SX dae, float t0, [float] tout, dict opts) -> Function
      integrator(str name, str solver, dict:SX dae, float t0, float tf, dict opts) -> Function
      integrator(str name, str solver, dict:MX dae, float t0, [float] tout, dict opts) -> Function
      integrator(str name, str solver, dict:MX dae, float t0, float tf, dict opts) -> Function
      integrator(str name, str solver, Function dae, float t0, [float] tout, dict opts) -> Function
      integrator(str name, str solver, Function dae, float t0, float tf, dict opts) -> Function


    .......

    ::

      integrator(str name, str solver, dict:SX dae, dict opts)





    Create an ODE/DAE integrator Solves an initial value problem (IVP) 
    coupled 
    to a terminal value problem with differential equation given 
    as an implicit
     ODE coupled to an algebraic equation and a set of 
    quadratures:



    ::

      Initial conditions at t=t0
      x(t0)  = x0
      q(t0)  = 0

      Forward integration from t=t0 to t=tf
      der(x) = function(x, z, p, t)                  Forward ODE
      0 = fz(x, z, p, t)                  Forward algebraic equations
      der(q) = fq(x, z, p, t)                  Forward quadratures

      Terminal conditions at t=tf
      rx(tf)  = rx0
      rq(tf)  = 0

      Backward integration from t=tf to t=t0
      der(rx) = gx(rx, rz, rp, x, z, p, t)        Backward ODE
      0 = gz(rx, rz, rp, x, z, p, t)        Backward algebraic equations
      der(rq) = gq(rx, rz, rp, x, z, p, t)        Backward quadratures

      where we assume that both the forward and backwards integrations are index-1
      (i.e. dfz/dz, dgz/drz are invertible) and furthermore that
      gx, gz and gq have a linear dependency on rx, rz and rp.

    General information

    >List of available options

    +------------------+-----------------+------------------+------------------+
    |        Id        |      Type       |   Description    |     Used in      |
    +==================+=================+==================+==================+
    | ad_weight        | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for derivative   | Internal         |
    |                  |                 | calculation.When |                  |
    |                  |                 | there is an      |                  |
    |                  |                 | option of either |                  |
    |                  |                 | using forward or |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | directional      |                  |
    |                  |                 | derivatives, the |                  |
    |                  |                 | condition ad_wei |                  |
    |                  |                 | ght*nf<=(1-      |                  |
    |                  |                 | ad_weight)*na is |                  |
    |                  |                 | used where nf    |                  |
    |                  |                 | and na are       |                  |
    |                  |                 | estimates of the |                  |
    |                  |                 | number of        |                  |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | mode directional |                  |
    |                  |                 | derivatives      |                  |
    |                  |                 | needed. By       |                  |
    |                  |                 | default,         |                  |
    |                  |                 | ad_weight is     |                  |
    |                  |                 | calculated       |                  |
    |                  |                 | automatically,   |                  |
    |                  |                 | but this can be  |                  |
    |                  |                 | overridden by    |                  |
    |                  |                 | setting this     |                  |
    |                  |                 | option. In       |                  |
    |                  |                 | particular, 0    |                  |
    |                  |                 | means forcing    |                  |
    |                  |                 | forward mode and |                  |
    |                  |                 | 1 forcing        |                  |
    |                  |                 | reverse mode.    |                  |
    |                  |                 | Leave unset for  |                  |
    |                  |                 | (class specific) |                  |
    |                  |                 | heuristics.      |                  |
    +------------------+-----------------+------------------+------------------+
    | ad_weight_sp     | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for sparsity     | Internal         |
    |                  |                 | pattern          |                  |
    |                  |                 | calculation calc |                  |
    |                  |                 | ulation.Override |                  |
    |                  |                 | s default        |                  |
    |                  |                 | behavior. Set to |                  |
    |                  |                 | 0 and 1 to force |                  |
    |                  |                 | forward and      |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | respectively.    |                  |
    |                  |                 | Cf. option       |                  |
    |                  |                 | "ad_weight".     |                  |
    |                  |                 | When set to -1,  |                  |
    |                  |                 | sparsity is      |                  |
    |                  |                 | completely       |                  |
    |                  |                 | ignored and      |                  |
    |                  |                 | dense matrices   |                  |
    |                  |                 | are used.        |                  |
    +------------------+-----------------+------------------+------------------+
    | always_inline    | OT_BOOL         | Force inlining.  | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | augmented_option | OT_DICT         | Options to be    | casadi::Integrat |
    | s                |                 | passed down to   | or               |
    |                  |                 | the augmented    |                  |
    |                  |                 | integrator, if   |                  |
    |                  |                 | one is           |                  |
    |                  |                 | constructed      |                  |
    +------------------+-----------------+------------------+------------------+
    | cache            | OT_DICT         | Prepopulate the  | casadi::Function |
    |                  |                 | function cache.  | Internal         |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | common_options   | OT_DICT         | Options for      | casadi::OracleFu |
    |                  |                 | auto-generated   | nction           |
    |                  |                 | functions        |                  |
    +------------------+-----------------+------------------+------------------+
    | compiler         | OT_STRING       | Just-in-time     | casadi::Function |
    |                  |                 | compiler plugin  | Internal         |
    |                  |                 | to be used.      |                  |
    +------------------+-----------------+------------------+------------------+
    | custom_jacobian  | OT_FUNCTION     | Override         | casadi::Function |
    |                  |                 | CasADi's AD. Use | Internal         |
    |                  |                 | together with    |                  |
    |                  |                 | 'jac_penalty':   |                  |
    |                  |                 | 0. Note: Highly  |                  |
    |                  |                 | experimental.    |                  |
    |                  |                 | Syntax may break |                  |
    |                  |                 | often.           |                  |
    +------------------+-----------------+------------------+------------------+
    | der_options      | OT_DICT         | Default options  | casadi::Function |
    |                  |                 | to be used to    | Internal         |
    |                  |                 | populate         |                  |
    |                  |                 | forward_options, |                  |
    |                  |                 | reverse_options, |                  |
    |                  |                 | and              |                  |
    |                  |                 | jacobian_options |                  |
    |                  |                 | before those     |                  |
    |                  |                 | options are      |                  |
    |                  |                 | merged in.       |                  |
    +------------------+-----------------+------------------+------------------+
    | derivative_of    | OT_FUNCTION     | The function is  | casadi::Function |
    |                  |                 | a derivative of  | Internal         |
    |                  |                 | another          |                  |
    |                  |                 | function. The    |                  |
    |                  |                 | type of          |                  |
    |                  |                 | derivative       |                  |
    |                  |                 | (directional     |                  |
    |                  |                 | derivative,      |                  |
    |                  |                 | Jacobian) is     |                  |
    |                  |                 | inferred from    |                  |
    |                  |                 | the function     |                  |
    |                  |                 | name.            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump             | OT_BOOL         | Dump function to | casadi::Function |
    |                  |                 | file upon first  | Internal         |
    |                  |                 | evaluation.      |                  |
    |                  |                 | [false]          |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_dir         | OT_STRING       | Directory to     | casadi::Function |
    |                  |                 | dump             | Internal         |
    |                  |                 | inputs/outputs   |                  |
    |                  |                 | to. Make sure    |                  |
    |                  |                 | the directory    |                  |
    |                  |                 | exists [.]       |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_format      | OT_STRING       | Choose file      | casadi::Function |
    |                  |                 | format to dump   | Internal         |
    |                  |                 | matrices. See    |                  |
    |                  |                 | DM.from_file     |                  |
    |                  |                 | [mtx]            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_in          | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | to file          |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_out         | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs to file  |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_fd        | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation by   |                  |
    |                  |                 | finite           |                  |
    |                  |                 | differencing.    |                  |
    |                  |                 | [default:        |                  |
    |                  |                 | false]]          |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_forward   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using forward    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_jacobian  | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobians of all |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | outputs with     |                  |
    |                  |                 | respect to all   |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | inputs - if      |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_reverse   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | transposed       |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using reverse    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | error_on_fail    | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when function    | ction            |
    |                  |                 | evaluation fails |                  |
    |                  |                 | (default true).  |                  |
    +------------------+-----------------+------------------+------------------+
    | event_tol        | OT_DOUBLE       | Termination      | casadi::Integrat |
    |                  |                 | tolerance for    | or               |
    |                  |                 | the event        |                  |
    |                  |                 | iteration        |                  |
    +------------------+-----------------+------------------+------------------+
    | expand           | OT_BOOL         | Replace MX with  | casadi::OracleFu |
    |                  |                 | SX expressions   | nction           |
    |                  |                 | in problem       |                  |
    |                  |                 | formulation      |                  |
    |                  |                 | [false] This     |                  |
    |                  |                 | happens before   |                  |
    |                  |                 | creating         |                  |
    |                  |                 | derivatives      |                  |
    |                  |                 | unless indicated |                  |
    |                  |                 | by               |                  |
    |                  |                 | postpone_expand  |                  |
    +------------------+-----------------+------------------+------------------+
    | external_transfo | OT_VECTORVECTOR | List of external | casadi::Function |
    | rm               |                 | _transform       | Internal         |
    |                  |                 | instruction      |                  |
    |                  |                 | arguments.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_method        | OT_STRING       | Method for       | casadi::Function |
    |                  |                 | finite           | Internal         |
    |                  |                 | differencing     |                  |
    |                  |                 | [default         |                  |
    |                  |                 | 'central']       |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_options       | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | finite           |                  |
    |                  |                 | difference       |                  |
    |                  |                 | instance         |                  |
    +------------------+-----------------+------------------+------------------+
    | forward_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | forward mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | gather_stats     | OT_BOOL         | Deprecated       | casadi::Function |
    |                  |                 | option           | Internal         |
    |                  |                 | (ignored):       |                  |
    |                  |                 | Statistics are   |                  |
    |                  |                 | now always       |                  |
    |                  |                 | collected.       |                  |
    +------------------+-----------------+------------------+------------------+
    | grid             | OT_DOUBLEVECTOR | [DEPRECATED]     | casadi::Integrat |
    |                  |                 | Time grid        | or               |
    +------------------+-----------------+------------------+------------------+
    | input_scheme     | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | inputs_check     | OT_BOOL         | Throw exceptions | casadi::Function |
    |                  |                 | when the         | Internal         |
    |                  |                 | numerical values |                  |
    |                  |                 | of the inputs    |                  |
    |                  |                 | don't make sense |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_in       | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each input if it | Internal         |
    |                  |                 | should be        |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_out      | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each output if   | Internal         |
    |                  |                 | it should be     |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | jac_penalty      | OT_DOUBLE       | When requested   | casadi::Function |
    |                  |                 | for a number of  | Internal         |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | directions, it   |                  |
    |                  |                 | may be cheaper   |                  |
    |                  |                 | to compute first |                  |
    |                  |                 | the full         |                  |
    |                  |                 | jacobian and     |                  |
    |                  |                 | then multiply    |                  |
    |                  |                 | with seeds,      |                  |
    |                  |                 | rather than      |                  |
    |                  |                 | obtain the       |                  |
    |                  |                 | requested        |                  |
    |                  |                 | directions in a  |                  |
    |                  |                 | straightforward  |                  |
    |                  |                 | manner. Casadi   |                  |
    |                  |                 | uses a heuristic |                  |
    |                  |                 | to decide which  |                  |
    |                  |                 | is cheaper. A    |                  |
    |                  |                 | high value of    |                  |
    |                  |                 | 'jac_penalty'    |                  |
    |                  |                 | makes it less    |                  |
    |                  |                 | likely for the   |                  |
    |                  |                 | heurstic to      |                  |
    |                  |                 | chose the full   |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy. The    |                  |
    |                  |                 | special value -1 |                  |
    |                  |                 | indicates never  |                  |
    |                  |                 | to use the full  |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy         |                  |
    +------------------+-----------------+------------------+------------------+
    | jacobian_options | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | Jacobian         |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | jit              | OT_BOOL         | Use just-in-time | casadi::Function |
    |                  |                 | compiler to      | Internal         |
    |                  |                 | speed up the     |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_cleanup      | OT_BOOL         | Cleanup up the   | casadi::Function |
    |                  |                 | temporary source | Internal         |
    |                  |                 | file that jit    |                  |
    |                  |                 | creates.         |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_name         | OT_STRING       | The file name    | casadi::Function |
    |                  |                 | used to write    | Internal         |
    |                  |                 | out code. The    |                  |
    |                  |                 | actual file      |                  |
    |                  |                 | names used       |                  |
    |                  |                 | depend on 'jit_t |                  |
    |                  |                 | emp_suffix' and  |                  |
    |                  |                 | include          |                  |
    |                  |                 | extensions.      |                  |
    |                  |                 | Default:         |                  |
    |                  |                 | 'jit_tmp'        |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_options      | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | jit compiler.    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_serialize    | OT_STRING       | Specify          | casadi::Function |
    |                  |                 | behaviour when   | Internal         |
    |                  |                 | serializing a    |                  |
    |                  |                 | jitted function: |                  |
    |                  |                 | SOURCE|link|embe |                  |
    |                  |                 | d.               |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_temp_suffix  | OT_BOOL         | Use a temporary  | casadi::Function |
    |                  |                 | (seemingly       | Internal         |
    |                  |                 | random) filename |                  |
    |                  |                 | suffix for       |                  |
    |                  |                 | generated code   |                  |
    |                  |                 | and libraries.   |                  |
    |                  |                 | This is desired  |                  |
    |                  |                 | for thread-      |                  |
    |                  |                 | safety. This     |                  |
    |                  |                 | behaviour may    |                  |
    |                  |                 | defeat caching   |                  |
    |                  |                 | compiler         |                  |
    |                  |                 | wrappers.        |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | max_event_iter   | OT_INT          | Maximum number   | casadi::Integrat |
    |                  |                 | of iterations to | or               |
    |                  |                 | zero in on a     |                  |
    |                  |                 | single event     |                  |
    +------------------+-----------------+------------------+------------------+
    | max_events       | OT_INT          | Maximum total    | casadi::Integrat |
    |                  |                 | number of events | or               |
    +------------------+-----------------+------------------+------------------+
    | max_io           | OT_INT          | Acceptable       | casadi::Function |
    |                  |                 | number of inputs | Internal         |
    |                  |                 | and outputs.     |                  |
    |                  |                 | Warn if          |                  |
    |                  |                 | exceeded.        |                  |
    +------------------+-----------------+------------------+------------------+
    | max_num_dir      | OT_INT          | Specify the      | casadi::Function |
    |                  |                 | maximum number   | Internal         |
    |                  |                 | of directions    |                  |
    |                  |                 | for derivative   |                  |
    |                  |                 | functions.       |                  |
    |                  |                 | Overrules the    |                  |
    |                  |                 | builtin optimize |                  |
    |                  |                 | d_num_dir.       |                  |
    +------------------+-----------------+------------------+------------------+
    | monitor          | OT_STRINGVECTOR | Set of user      | casadi::OracleFu |
    |                  |                 | problem          | nction           |
    |                  |                 | functions to be  |                  |
    |                  |                 | monitored        |                  |
    +------------------+-----------------+------------------+------------------+
    | nadj             | OT_INT          | Number of        | casadi::Integrat |
    |                  |                 | adjoint          | or               |
    |                  |                 | sensitivities to |                  |
    |                  |                 | be calculated    |                  |
    |                  |                 | [0]              |                  |
    +------------------+-----------------+------------------+------------------+
    | never_inline     | OT_BOOL         | Forbid inlining. | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | nfwd             | OT_INT          | Number of        | casadi::Integrat |
    |                  |                 | forward          | or               |
    |                  |                 | sensitivities to |                  |
    |                  |                 | be calculated    |                  |
    |                  |                 | [0]              |                  |
    +------------------+-----------------+------------------+------------------+
    | number_of_finite | OT_INT          | Target number of | casadi::Integrat |
    | _elements        |                 | finite elements. | or               |
    |                  |                 | The actual       |                  |
    |                  |                 | number may be    |                  |
    |                  |                 | higher to        |                  |
    |                  |                 | accommodate all  |                  |
    |                  |                 | output times     |                  |
    +------------------+-----------------+------------------+------------------+
    | output_scheme    | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | output_t0        | OT_BOOL         | [DEPRECATED]     | casadi::Integrat |
    |                  |                 | Output the state | or               |
    |                  |                 | at the initial   |                  |
    |                  |                 | time             |                  |
    +------------------+-----------------+------------------+------------------+
    | post_expand      | OT_BOOL         | After            | casadi::Function |
    |                  |                 | construction,    | Internal         |
    |                  |                 | expand this      |                  |
    |                  |                 | Function .       |                  |
    |                  |                 | Default: False   |                  |
    +------------------+-----------------+------------------+------------------+
    | post_expand_opti | OT_DICT         | Options to be    | casadi::Function |
    | ons              |                 | passed to post-  | Internal         |
    |                  |                 | construction     |                  |
    |                  |                 | expansion.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | postpone_expand  | OT_BOOL         | When expand is   | casadi::OracleFu |
    |                  |                 | active, postpone | nction           |
    |                  |                 | it until after   |                  |
    |                  |                 | creation of      |                  |
    |                  |                 | derivatives.     |                  |
    |                  |                 | Default: False   |                  |
    +------------------+-----------------+------------------+------------------+
    | print_canonical  | OT_BOOL         | When printing    | casadi::Function |
    |                  |                 | numerical        | Internal         |
    |                  |                 | matrices, use a  |                  |
    |                  |                 | format that is   |                  |
    |                  |                 | exact and        |                  |
    |                  |                 | reproducible in  |                  |
    |                  |                 | generated C      |                  |
    |                  |                 | code.            |                  |
    +------------------+-----------------+------------------+------------------+
    | print_in         | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_out        | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs          |                  |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_stats      | OT_BOOL         | Print out        | casadi::Integrat |
    |                  |                 | statistics after | or               |
    |                  |                 | integration      |                  |
    +------------------+-----------------+------------------+------------------+
    | print_time       | OT_BOOL         | print            | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time. Implies    |                  |
    |                  |                 | record_time.     |                  |
    +------------------+-----------------+------------------+------------------+
    | record_time      | OT_BOOL         | record           | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time, for        |                  |
    |                  |                 | retrieval with   |                  |
    |                  |                 | stats().         |                  |
    +------------------+-----------------+------------------+------------------+
    | regularity_check | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when NaN or Inf  | ction            |
    |                  |                 | appears during   |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | reverse_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | reverse mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | rootfinder       | OT_STRING       | An implicit      | casadi::Integrat |
    |                  |                 | function solver  | or               |
    +------------------+-----------------+------------------+------------------+
    | rootfinder_optio | OT_DICT         | Options to be    | casadi::Integrat |
    | ns               |                 | passed to the    | or               |
    |                  |                 | NLP Solver       |                  |
    +------------------+-----------------+------------------+------------------+
    | show_eval_warnin | OT_BOOL         | Show warnings    | casadi::OracleFu |
    | gs               |                 | generated from   | nction           |
    |                  |                 | function         |                  |
    |                  |                 | evaluations      |                  |
    |                  |                 | [true]           |                  |
    +------------------+-----------------+------------------+------------------+
    | simplify         | OT_BOOL         | Implement as MX  | casadi::Integrat |
    |                  |                 | Function (codege | or               |
    |                  |                 | neratable/serial |                  |
    |                  |                 | izable) default: |                  |
    |                  |                 | false            |                  |
    +------------------+-----------------+------------------+------------------+
    | simplify_options | OT_DICT         | Any options to   | casadi::Integrat |
    |                  |                 | pass to          | or               |
    |                  |                 | simplified form  |                  |
    |                  |                 | Function         |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | specific_options | OT_DICT         | Options for      | casadi::OracleFu |
    |                  |                 | specific auto-   | nction           |
    |                  |                 | generated        |                  |
    |                  |                 | functions,       |                  |
    |                  |                 | overwriting the  |                  |
    |                  |                 | defaults from    |                  |
    |                  |                 | common_options.  |                  |
    |                  |                 | Nested           |                  |
    |                  |                 | dictionary.      |                  |
    +------------------+-----------------+------------------+------------------+
    | t0               | OT_DOUBLE       | [DEPRECATED]     | casadi::Integrat |
    |                  |                 | Beginning of the | or               |
    |                  |                 | time horizon     |                  |
    +------------------+-----------------+------------------+------------------+
    | tf               | OT_DOUBLE       | [DEPRECATED] End | casadi::Integrat |
    |                  |                 | of the time      | or               |
    |                  |                 | horizon          |                  |
    +------------------+-----------------+------------------+------------------+
    | transition       | OT_FUNCTION     | Function to be   | casadi::Integrat |
    |                  |                 | called a zero-   | or               |
    |                  |                 | crossing events  |                  |
    +------------------+-----------------+------------------+------------------+
    | user_data        | OT_VOIDPTR      | A user-defined   | casadi::Function |
    |                  |                 | field that can   | Internal         |
    |                  |                 | be used to       |                  |
    |                  |                 | identify the     |                  |
    |                  |                 | function or pass |                  |
    |                  |                 | additional       |                  |
    |                  |                 | information      |                  |
    +------------------+-----------------+------------------+------------------+
    | verbose          | OT_BOOL         | Verbose          | casadi::ProtoFun |
    |                  |                 | evaluation  for  | ction            |
    |                  |                 | debugging        |                  |
    +------------------+-----------------+------------------+------------------+

    >Input scheme: casadi::IntegratorInput (INTEGRATOR_NUM_IN = 7)

    +-------------------+--------+---------------------------------------------+
    |     Full name     | Short  |                 Description                 |
    +===================+========+=============================================+
    | INTEGRATOR_X0     | x0     | Differential state at the initial time.     |
    +-------------------+--------+---------------------------------------------+
    | INTEGRATOR_Z0     | z0     | Initial guess for the algebraic variable at |
    |                   |        | the initial time.                           |
    +-------------------+--------+---------------------------------------------+
    | INTEGRATOR_P      | p      | Parameters.                                 |
    +-------------------+--------+---------------------------------------------+
    | INTEGRATOR_U      | u      | Piecewise constant control, a new control   |
    |                   |        | interval starts at each output time.        |
    +-------------------+--------+---------------------------------------------+
    | INTEGRATOR_ADJ_XF | adj_xf | Adjoint seeds corresponding to the states   |
    |                   |        | at the output times.                        |
    +-------------------+--------+---------------------------------------------+
    | INTEGRATOR_ADJ_ZF | adj_zf | Adjoint seeds corresponding to the          |
    |                   |        | algebraic variables at the output times.    |
    +-------------------+--------+---------------------------------------------+
    | INTEGRATOR_ADJ_QF | adj_qf | Adjoint seeds corresponding to the          |
    |                   |        | quadratures at the output times.            |
    +-------------------+--------+---------------------------------------------+

    >Output scheme: casadi::IntegratorOutput (INTEGRATOR_NUM_OUT = 7)

    +-------------------+--------+---------------------------------------------+
    |     Full name     | Short  |                 Description                 |
    +===================+========+=============================================+
    | INTEGRATOR_XF     | xf     | Differential state at all output times.     |
    +-------------------+--------+---------------------------------------------+
    | INTEGRATOR_ZF     | zf     | Algebraic variable at all output times.     |
    +-------------------+--------+---------------------------------------------+
    | INTEGRATOR_QF     | qf     | Quadrature state at all output times.       |
    +-------------------+--------+---------------------------------------------+
    | INTEGRATOR_ADJ_X0 | adj_x0 | Adjoint sensitivities corresponding to the  |
    |                   |        | initial state.                              |
    +-------------------+--------+---------------------------------------------+
    | INTEGRATOR_ADJ_Z0 | adj_z0 | Adjoint sensitivities corresponding to the  |
    |                   |        | algebraic variable guess.                   |
    +-------------------+--------+---------------------------------------------+
    | INTEGRATOR_ADJ_P  | adj_p  | Adjoint sensitivities corresponding to the  |
    |                   |        | parameter vector.                           |
    +-------------------+--------+---------------------------------------------+
    | INTEGRATOR_ADJ_U  | adj_u  | Adjoint sensitivities corresponding to the  |
    |                   |        | control vector.                             |
    +-------------------+--------+---------------------------------------------+

    List of plugins
    - cvodes

    - idas

    - collocation

    - rk

    Note: some of the plugins in this list might not be available on your 

    system.  Also, there might be extra plugins available to you that are 
    not 
    listed here. You can obtain their documentation with  
    Integrator.doc("myextraplugin")



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

    cvodes
    ------



    Interface to CVodes from the Sundials suite.

    A call to evaluate will integrate to the end.

    You can retrieve the entire state trajectory as follows, after the 
    evaluate
     call: Call reset. Then call integrate(t_i) and getOuput for a
     series of 
    times t_i.

    Extra doc: https://github.com/casadi/casadi/wiki/L_228

    >List of available options

    +-----------------------------+-----------+--------------------------------+
    |             Id              |   Type    |          Description           |
    +=============================+===========+================================+
    | abstol                      | OT_DOUBLE | Absolute tolerence for the IVP |
    |                             |           | solution                       |
    +-----------------------------+-----------+--------------------------------+
    | always_recalculate_jacobian | OT_BOOL   | Recalculate Jacobian before    |
    |                             |           | factorizations, even if        |
    |                             |           | Jacobian is current [default:  |
    |                             |           | true]                          |
    +-----------------------------+-----------+--------------------------------+
    | disable_internal_warnings   | OT_BOOL   | Disable SUNDIALS internal      |
    |                             |           | warning messages               |
    +-----------------------------+-----------+--------------------------------+
    | fsens_all_at_once           | OT_BOOL   | Calculate all right hand sides |
    |                             |           | of the sensitivity equations   |
    |                             |           | at once                        |
    +-----------------------------+-----------+--------------------------------+
    | fsens_err_con               | OT_BOOL   | include the forward            |
    |                             |           | sensitivities in all error     |
    |                             |           | controls                       |
    +-----------------------------+-----------+--------------------------------+
    | interpolation_type          | OT_STRING | Type of interpolation for the  |
    |                             |           | adjoint sensitivities          |
    +-----------------------------+-----------+--------------------------------+
    | linear_multistep_method     | OT_STRING | Integrator scheme: BDF|adams   |
    +-----------------------------+-----------+--------------------------------+
    | linear_solver               | OT_STRING | A custom linear solver creator |
    |                             |           | function [default: qr]         |
    +-----------------------------+-----------+--------------------------------+
    | linear_solver_options       | OT_DICT   | Options to be passed to the    |
    |                             |           | linear solver                  |
    +-----------------------------+-----------+--------------------------------+
    | max_krylov                  | OT_INT    | Maximum Krylov subspace size   |
    +-----------------------------+-----------+--------------------------------+
    | max_multistep_order         | OT_INT    | Maximum order for the          |
    |                             |           | (variable-order) multistep     |
    |                             |           | method                         |
    +-----------------------------+-----------+--------------------------------+
    | max_num_steps               | OT_INT    | Maximum number of integrator   |
    |                             |           | steps                          |
    +-----------------------------+-----------+--------------------------------+
    | max_order                   | OT_DOUBLE | Maximum order                  |
    +-----------------------------+-----------+--------------------------------+
    | max_step_size               | OT_DOUBLE | Max step size [default: 0/inf] |
    +-----------------------------+-----------+--------------------------------+
    | min_step_size               | OT_DOUBLE | Min step size [default: 0/0.0] |
    +-----------------------------+-----------+--------------------------------+
    | newton_scheme               | OT_STRING | Linear solver scheme in the    |
    |                             |           | Newton method:                 |
    |                             |           | DIRECT|gmres|bcgstab|tfqmr     |
    +-----------------------------+-----------+--------------------------------+
    | nonlin_conv_coeff           | OT_DOUBLE | Coefficient in the nonlinear   |
    |                             |           | convergence test               |
    +-----------------------------+-----------+--------------------------------+
    | nonlinear_solver_iteration  | OT_STRING | Nonlinear solver type:         |
    |                             |           | NEWTON|functional              |
    +-----------------------------+-----------+--------------------------------+
    | quad_err_con                | OT_BOOL   | Should the quadratures affect  |
    |                             |           | the step size control          |
    +-----------------------------+-----------+--------------------------------+
    | reltol                      | OT_DOUBLE | Relative tolerence for the IVP |
    |                             |           | solution                       |
    +-----------------------------+-----------+--------------------------------+
    | scale_abstol                | OT_BOOL   | Scale absolute tolerance by    |
    |                             |           | nominal value                  |
    +-----------------------------+-----------+--------------------------------+
    | second_order_correction     | OT_BOOL   | Second order correction in the |
    |                             |           | augmented system Jacobian      |
    |                             |           | [true]                         |
    +-----------------------------+-----------+--------------------------------+
    | sensitivity_method          | OT_STRING | Sensitivity method:            |
    |                             |           | SIMULTANEOUS|staggered         |
    +-----------------------------+-----------+--------------------------------+
    | step0                       | OT_DOUBLE | initial step size [default:    |
    |                             |           | 0/estimated]                   |
    +-----------------------------+-----------+--------------------------------+
    | steps_per_checkpoint        | OT_INT    | Number of steps between two    |
    |                             |           | consecutive checkpoints        |
    +-----------------------------+-----------+--------------------------------+
    | stop_at_end                 | OT_BOOL   | [DEPRECATED] Stop the          |
    |                             |           | integrator at the end of the   |
    |                             |           | interval                       |
    +-----------------------------+-----------+--------------------------------+
    | use_preconditioner          | OT_BOOL   | Precondition the iterative     |
    |                             |           | solver [default: true]         |
    +-----------------------------+-----------+--------------------------------+



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

    idas
    ----



    Interface to IDAS from the Sundials suite.

    Extra doc: https://github.com/casadi/casadi/wiki/L_225

    >List of available options

    +---------------------------+-----------------+----------------------------+
    |            Id             |      Type       |        Description         |
    +===========================+=================+============================+
    | abstol                    | OT_DOUBLE       | Absolute tolerence for the |
    |                           |                 | IVP solution               |
    +---------------------------+-----------------+----------------------------+
    | abstolv                   | OT_DOUBLEVECTOR | Absolute tolerarance for   |
    |                           |                 | each component             |
    +---------------------------+-----------------+----------------------------+
    | calc_ic                   | OT_BOOL         | Use IDACalcIC to get       |
    |                           |                 | consistent initial         |
    |                           |                 | conditions.                |
    +---------------------------+-----------------+----------------------------+
    | calc_icB                  | OT_BOOL         | Use IDACalcIC to get       |
    |                           |                 | consistent initial         |
    |                           |                 | conditions for backwards   |
    |                           |                 | system [default: equal to  |
    |                           |                 | calc_ic].                  |
    +---------------------------+-----------------+----------------------------+
    | cj_scaling                | OT_BOOL         | IDAS scaling on cj for the |
    |                           |                 | user-defined linear solver |
    |                           |                 | module                     |
    +---------------------------+-----------------+----------------------------+
    | constraints               | OT_INTVECTOR    | Constrain the solution     |
    |                           |                 | y=[x,z]. 0 (default): no   |
    |                           |                 | constraint on yi, 1: yi >= |
    |                           |                 | 0.0, -1: yi <= 0.0, 2: yi  |
    |                           |                 | > 0.0, -2: yi < 0.0.       |
    +---------------------------+-----------------+----------------------------+
    | disable_internal_warnings | OT_BOOL         | Disable SUNDIALS internal  |
    |                           |                 | warning messages           |
    +---------------------------+-----------------+----------------------------+
    | first_time                | OT_DOUBLE       | First requested time as a  |
    |                           |                 | fraction of the time       |
    |                           |                 | interval                   |
    +---------------------------+-----------------+----------------------------+
    | fsens_err_con             | OT_BOOL         | include the forward        |
    |                           |                 | sensitivities in all error |
    |                           |                 | controls                   |
    +---------------------------+-----------------+----------------------------+
    | init_xdot                 | OT_DOUBLEVECTOR | Initial values for the     |
    |                           |                 | state derivatives          |
    +---------------------------+-----------------+----------------------------+
    | interpolation_type        | OT_STRING       | Type of interpolation for  |
    |                           |                 | the adjoint sensitivities  |
    +---------------------------+-----------------+----------------------------+
    | linear_solver             | OT_STRING       | A custom linear solver     |
    |                           |                 | creator function [default: |
    |                           |                 | qr]                        |
    +---------------------------+-----------------+----------------------------+
    | linear_solver_options     | OT_DICT         | Options to be passed to    |
    |                           |                 | the linear solver          |
    +---------------------------+-----------------+----------------------------+
    | max_krylov                | OT_INT          | Maximum Krylov subspace    |
    |                           |                 | size                       |
    +---------------------------+-----------------+----------------------------+
    | max_multistep_order       | OT_INT          | Maximum order for the      |
    |                           |                 | (variable-order) multistep |
    |                           |                 | method                     |
    +---------------------------+-----------------+----------------------------+
    | max_num_steps             | OT_INT          | Maximum number of          |
    |                           |                 | integrator steps           |
    +---------------------------+-----------------+----------------------------+
    | max_order                 | OT_DOUBLE       | Maximum order              |
    +---------------------------+-----------------+----------------------------+
    | max_step_size             | OT_DOUBLE       | Maximim step size          |
    +---------------------------+-----------------+----------------------------+
    | newton_scheme             | OT_STRING       | Linear solver scheme in    |
    |                           |                 | the Newton method:         |
    |                           |                 | DIRECT|gmres|bcgstab|tfqmr |
    +---------------------------+-----------------+----------------------------+
    | nonlin_conv_coeff         | OT_DOUBLE       | Coefficient in the         |
    |                           |                 | nonlinear convergence test |
    +---------------------------+-----------------+----------------------------+
    | quad_err_con              | OT_BOOL         | Should the quadratures     |
    |                           |                 | affect the step size       |
    |                           |                 | control                    |
    +---------------------------+-----------------+----------------------------+
    | reltol                    | OT_DOUBLE       | Relative tolerence for the |
    |                           |                 | IVP solution               |
    +---------------------------+-----------------+----------------------------+
    | scale_abstol              | OT_BOOL         | Scale absolute tolerance   |
    |                           |                 | by nominal value           |
    +---------------------------+-----------------+----------------------------+
    | second_order_correction   | OT_BOOL         | Second order correction in |
    |                           |                 | the augmented system       |
    |                           |                 | Jacobian [true]            |
    +---------------------------+-----------------+----------------------------+
    | sensitivity_method        | OT_STRING       | Sensitivity method:        |
    |                           |                 | SIMULTANEOUS|staggered     |
    +---------------------------+-----------------+----------------------------+
    | step0                     | OT_DOUBLE       | initial step size          |
    |                           |                 | [default: 0/estimated]     |
    +---------------------------+-----------------+----------------------------+
    | steps_per_checkpoint      | OT_INT          | Number of steps between    |
    |                           |                 | two consecutive            |
    |                           |                 | checkpoints                |
    +---------------------------+-----------------+----------------------------+
    | stop_at_end               | OT_BOOL         | [DEPRECATED] Stop the      |
    |                           |                 | integrator at the end of   |
    |                           |                 | the interval               |
    +---------------------------+-----------------+----------------------------+
    | suppress_algebraic        | OT_BOOL         | Suppress algebraic         |
    |                           |                 | variables in the error     |
    |                           |                 | testing                    |
    +---------------------------+-----------------+----------------------------+
    | use_preconditioner        | OT_BOOL         | Precondition the iterative |
    |                           |                 | solver [default: true]     |
    +---------------------------+-----------------+----------------------------+



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

    collocation
    -----------



    Fixed-step implicit Runge-Kutta integrator ODE/DAE integrator based 
    on 
    collocation schemes

    The method is still under development

    Extra doc: https://github.com/casadi/casadi/wiki/L_234

    >List of available options

    +---------------------------+-----------+----------------------------------+
    |            Id             |   Type    |           Description            |
    +===========================+===========+==================================+
    | collocation_scheme        | OT_STRING | Collocation scheme:              |
    |                           |           | radau|legendre                   |
    +---------------------------+-----------+----------------------------------+
    | interpolation_order       | OT_INT    | Order of the interpolating       |
    |                           |           | polynomials                      |
    +---------------------------+-----------+----------------------------------+
    | number_of_finite_elements | OT_INT    | Target number of finite          |
    |                           |           | elements. The actual number may  |
    |                           |           | be higher to accommodate all     |
    |                           |           | output times                     |
    +---------------------------+-----------+----------------------------------+
    | rootfinder                | OT_STRING | An implicit function solver      |
    +---------------------------+-----------+----------------------------------+
    | rootfinder_options        | OT_DICT   | Options to be passed to the NLP  |
    |                           |           | Solver                           |
    +---------------------------+-----------+----------------------------------+
    | simplify                  | OT_BOOL   | Implement as MX  Function        |
    |                           |           | (codegeneratable/serializable)   |
    |                           |           | default: false                   |
    +---------------------------+-----------+----------------------------------+
    | simplify_options          | OT_DICT   | Any options to pass to           |
    |                           |           | simplified form Function         |
    |                           |           | constructor                      |
    +---------------------------+-----------+----------------------------------+



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

    rk
    --



    Fixed-step explicit Runge-Kutta integrator for ODEs Currently 
    implements 
    RK4.

    The method is still under development

    Extra doc: https://github.com/casadi/casadi/wiki/L_23a

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_21k

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L134

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L134-L137



    .............


    .......

    ::

      integrator(str name, str solver, dict:MX dae, dict opts)
      integrator(str name, str solver, Function dae, dict opts)
      integrator(str name, str solver, dict:SX dae, float t0, [float] tout, dict opts)
      integrator(str name, str solver, dict:SX dae, float t0, float tf, dict opts)
      integrator(str name, str solver, dict:MX dae, float t0, [float] tout, dict opts)
      integrator(str name, str solver, dict:MX dae, float t0, float tf, dict opts)
      integrator(str name, str solver, Function dae, float t0, [float] tout, dict opts)
      integrator(str name, str solver, Function dae, float t0, float tf, dict opts)



    [INTERNAL] 

    .............



    """
    return _casadi.integrator(*args)

def has_integrator(*args) -> "bool":
    """
      [INTERNAL] 

    ::

      has_integrator(str name) -> bool

    Check if a particular plugin is available.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L122

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L122-L124




    """
    return _casadi.has_integrator(*args)

def load_integrator(*args) -> "void":
    """
      [INTERNAL] 

    ::

      load_integrator(str name)

    Explicitly load a plugin dynamically.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L126

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L126-L128




    """
    return _casadi.load_integrator(*args)

def doc_integrator(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      doc_integrator(str name) -> str

    Get the documentation string for a plugin.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L130

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L130-L132




    """
    return _casadi.doc_integrator(*args)

def integrator_in(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      integrator_in() -> [str]
      integrator_in(int ind) -> str

    Get integrator input scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_7d

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L196

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L196-L208



    .......

    ::

      integrator_in()



    [INTERNAL] 
    Get input scheme of integrators.

    Extra doc: https://github.com/casadi/casadi/wiki/L_7b

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L184

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L184-L188



    .............


    .......

    ::

      integrator_in(int ind)



    [INTERNAL] 
    Get integrator input scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_7d

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L196

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L196-L208



    .............



    """
    return _casadi.integrator_in(*args)

def integrator_out(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      integrator_out() -> [str]
      integrator_out(int ind) -> str

    Get output scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_7e

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L210

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L210-L222



    .......

    ::

      integrator_out(int ind)



    [INTERNAL] 
    Get output scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_7e

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L210

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L210-L222



    .............


    .......

    ::

      integrator_out()



    [INTERNAL] 
    Get integrator output scheme of integrators.

    Extra doc: https://github.com/casadi/casadi/wiki/L_7c

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L190

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L190-L194



    .............



    """
    return _casadi.integrator_out(*args)

def integrator_n_in(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      integrator_n_in() -> int

    Get the number of integrator inputs.

    Extra doc: https://github.com/casadi/casadi/wiki/L_7f

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L224

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L224-L226




    """
    return _casadi.integrator_n_in(*args)

def integrator_n_out(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      integrator_n_out() -> int

    Get the number of integrator outputs.

    Extra doc: https://github.com/casadi/casadi/wiki/L_7g

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L228

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L228-L230




    """
    return _casadi.integrator_n_out(*args)

def dyn_in(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      dyn_in() -> [str]
      dyn_in(int ind) -> str

    Get input scheme of a DAE function by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_25r

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L240

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L240-L242



    .......

    ::

      dyn_in(int ind)



    [INTERNAL] 
    Get input scheme of a DAE function by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_25r

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L240

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L240-L242



    .............


    .......

    ::

      dyn_in()



    [INTERNAL] 
    Get input scheme of a DAE function.

    Extra doc: https://github.com/casadi/casadi/wiki/L_25p

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L232

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L232-L234



    .............



    """
    return _casadi.dyn_in(*args)

def dyn_out(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      dyn_out() -> [str]
      dyn_out(int ind) -> str

    Get output scheme of a DAE function by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_25s

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L244

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L244-L246



    .......

    ::

      dyn_out()



    [INTERNAL] 
    Get output scheme of a DAE function.

    Extra doc: https://github.com/casadi/casadi/wiki/L_25q

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L236

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L236-L238



    .............


    .......

    ::

      dyn_out(int ind)



    [INTERNAL] 
    Get output scheme of a DAE function by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_25s

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L244

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L244-L246



    .............



    """
    return _casadi.dyn_out(*args)

def dyn_n_in(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      dyn_n_in() -> int

    Get the number of inputs for a DAE function.

    Extra doc: https://github.com/casadi/casadi/wiki/L_25t

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L248

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L248-L250




    """
    return _casadi.dyn_n_in(*args)

def dyn_n_out(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      dyn_n_out() -> int

    Get the number of outputs for a DAE function.

    Extra doc: https://github.com/casadi/casadi/wiki/L_25u

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L252

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L252-L254




    """
    return _casadi.dyn_n_out(*args)

def event_in(*args) -> "std::vector< std::string,std::allocator< std::string > >":
    """
      [INTERNAL] 

    ::

      event_in() -> [str]

    Get input scheme of an event transition function.

    Extra doc: https://github.com/casadi/casadi/wiki/L_2b4

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L256

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L256-L258




    """
    return _casadi.event_in(*args)

def event_out(*args) -> "std::vector< std::string,std::allocator< std::string > >":
    """
      [INTERNAL] 

    ::

      event_out() -> [str]

    Get output scheme of an event transition functions.

    Extra doc: https://github.com/casadi/casadi/wiki/L_2b5

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.hpp#L260

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integrator.cpp#L260-L262




    """
    return _casadi.event_out(*args)

def conic(*args) -> "casadi::Function":
    """
      [INTERNAL]

    ::

      conic(str name, str solver, dict:Sparsity qp, dict opts) -> Function


    Create a QP solver Solves the following strictly convex problem:



    ::

      min          1/2 x' H x + g' x
      x

      subject to
      LBA <= A x <= UBA
      LBX <= x   <= UBX

      resize(Q x, np, np) + P >= 0 (psd)

      with :
      H sparse (n x n) positive definite
      g dense  (n x 1)
      A sparse (nc x n)
      Q sparse symmetric (np^2 x n)
      P sparse symmetric (np x nq)

      n: number of decision variables (x)
      nc: number of constraints (A)
      nq: shape of psd constraint matrix



    If H is not positive-definite, the solver should throw an error.

    Second-order cone constraints can be added as psd constraints through 
    a 
    helper function 'soc':

    x in R^n y in R

    || x ||_2 <= y

    <=>

    soc(x, y) psd

    This can be proven with soc(x, y)=[y*I x; x' y] using the Shur 
    complement.

    General information

    >List of available options

    +------------------+-----------------+------------------+------------------+
    |        Id        |      Type       |   Description    |     Used in      |
    +==================+=================+==================+==================+
    | ad_weight        | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for derivative   | Internal         |
    |                  |                 | calculation.When |                  |
    |                  |                 | there is an      |                  |
    |                  |                 | option of either |                  |
    |                  |                 | using forward or |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | directional      |                  |
    |                  |                 | derivatives, the |                  |
    |                  |                 | condition ad_wei |                  |
    |                  |                 | ght*nf<=(1-      |                  |
    |                  |                 | ad_weight)*na is |                  |
    |                  |                 | used where nf    |                  |
    |                  |                 | and na are       |                  |
    |                  |                 | estimates of the |                  |
    |                  |                 | number of        |                  |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | mode directional |                  |
    |                  |                 | derivatives      |                  |
    |                  |                 | needed. By       |                  |
    |                  |                 | default,         |                  |
    |                  |                 | ad_weight is     |                  |
    |                  |                 | calculated       |                  |
    |                  |                 | automatically,   |                  |
    |                  |                 | but this can be  |                  |
    |                  |                 | overridden by    |                  |
    |                  |                 | setting this     |                  |
    |                  |                 | option. In       |                  |
    |                  |                 | particular, 0    |                  |
    |                  |                 | means forcing    |                  |
    |                  |                 | forward mode and |                  |
    |                  |                 | 1 forcing        |                  |
    |                  |                 | reverse mode.    |                  |
    |                  |                 | Leave unset for  |                  |
    |                  |                 | (class specific) |                  |
    |                  |                 | heuristics.      |                  |
    +------------------+-----------------+------------------+------------------+
    | ad_weight_sp     | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for sparsity     | Internal         |
    |                  |                 | pattern          |                  |
    |                  |                 | calculation calc |                  |
    |                  |                 | ulation.Override |                  |
    |                  |                 | s default        |                  |
    |                  |                 | behavior. Set to |                  |
    |                  |                 | 0 and 1 to force |                  |
    |                  |                 | forward and      |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | respectively.    |                  |
    |                  |                 | Cf. option       |                  |
    |                  |                 | "ad_weight".     |                  |
    |                  |                 | When set to -1,  |                  |
    |                  |                 | sparsity is      |                  |
    |                  |                 | completely       |                  |
    |                  |                 | ignored and      |                  |
    |                  |                 | dense matrices   |                  |
    |                  |                 | are used.        |                  |
    +------------------+-----------------+------------------+------------------+
    | always_inline    | OT_BOOL         | Force inlining.  | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | cache            | OT_DICT         | Prepopulate the  | casadi::Function |
    |                  |                 | function cache.  | Internal         |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | compiler         | OT_STRING       | Just-in-time     | casadi::Function |
    |                  |                 | compiler plugin  | Internal         |
    |                  |                 | to be used.      |                  |
    +------------------+-----------------+------------------+------------------+
    | custom_jacobian  | OT_FUNCTION     | Override         | casadi::Function |
    |                  |                 | CasADi's AD. Use | Internal         |
    |                  |                 | together with    |                  |
    |                  |                 | 'jac_penalty':   |                  |
    |                  |                 | 0. Note: Highly  |                  |
    |                  |                 | experimental.    |                  |
    |                  |                 | Syntax may break |                  |
    |                  |                 | often.           |                  |
    +------------------+-----------------+------------------+------------------+
    | der_options      | OT_DICT         | Default options  | casadi::Function |
    |                  |                 | to be used to    | Internal         |
    |                  |                 | populate         |                  |
    |                  |                 | forward_options, |                  |
    |                  |                 | reverse_options, |                  |
    |                  |                 | and              |                  |
    |                  |                 | jacobian_options |                  |
    |                  |                 | before those     |                  |
    |                  |                 | options are      |                  |
    |                  |                 | merged in.       |                  |
    +------------------+-----------------+------------------+------------------+
    | derivative_of    | OT_FUNCTION     | The function is  | casadi::Function |
    |                  |                 | a derivative of  | Internal         |
    |                  |                 | another          |                  |
    |                  |                 | function. The    |                  |
    |                  |                 | type of          |                  |
    |                  |                 | derivative       |                  |
    |                  |                 | (directional     |                  |
    |                  |                 | derivative,      |                  |
    |                  |                 | Jacobian) is     |                  |
    |                  |                 | inferred from    |                  |
    |                  |                 | the function     |                  |
    |                  |                 | name.            |                  |
    +------------------+-----------------+------------------+------------------+
    | discrete         | OT_BOOLVECTOR   | Indicates which  | casadi::Conic    |
    |                  |                 | of the variables |                  |
    |                  |                 | are discrete,    |                  |
    |                  |                 | i.e. integer-    |                  |
    |                  |                 | valued           |                  |
    +------------------+-----------------+------------------+------------------+
    | dump             | OT_BOOL         | Dump function to | casadi::Function |
    |                  |                 | file upon first  | Internal         |
    |                  |                 | evaluation.      |                  |
    |                  |                 | [false]          |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_dir         | OT_STRING       | Directory to     | casadi::Function |
    |                  |                 | dump             | Internal         |
    |                  |                 | inputs/outputs   |                  |
    |                  |                 | to. Make sure    |                  |
    |                  |                 | the directory    |                  |
    |                  |                 | exists [.]       |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_format      | OT_STRING       | Choose file      | casadi::Function |
    |                  |                 | format to dump   | Internal         |
    |                  |                 | matrices. See    |                  |
    |                  |                 | DM.from_file     |                  |
    |                  |                 | [mtx]            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_in          | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | to file          |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_out         | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs to file  |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_fd        | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation by   |                  |
    |                  |                 | finite           |                  |
    |                  |                 | differencing.    |                  |
    |                  |                 | [default:        |                  |
    |                  |                 | false]]          |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_forward   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using forward    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_jacobian  | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobians of all |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | outputs with     |                  |
    |                  |                 | respect to all   |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | inputs - if      |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_reverse   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | transposed       |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using reverse    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | equality         | OT_BOOLVECTOR   | Indicate an      | casadi::Conic    |
    |                  |                 | upfront hint     |                  |
    |                  |                 | which of the     |                  |
    |                  |                 | constraints are  |                  |
    |                  |                 | equalities. Some |                  |
    |                  |                 | solvers may be   |                  |
    |                  |                 | able to exploit  |                  |
    |                  |                 | this knowledge.  |                  |
    |                  |                 | When true, the   |                  |
    |                  |                 | corresponding    |                  |
    |                  |                 | lower and upper  |                  |
    |                  |                 | bounds are       |                  |
    |                  |                 | assumed equal.   |                  |
    |                  |                 | When false, the  |                  |
    |                  |                 | corresponding    |                  |
    |                  |                 | bounds may be    |                  |
    |                  |                 | equal or         |                  |
    |                  |                 | different.       |                  |
    +------------------+-----------------+------------------+------------------+
    | error_on_fail    | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when function    | ction            |
    |                  |                 | evaluation fails |                  |
    |                  |                 | (default true).  |                  |
    +------------------+-----------------+------------------+------------------+
    | external_transfo | OT_VECTORVECTOR | List of external | casadi::Function |
    | rm               |                 | _transform       | Internal         |
    |                  |                 | instruction      |                  |
    |                  |                 | arguments.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_method        | OT_STRING       | Method for       | casadi::Function |
    |                  |                 | finite           | Internal         |
    |                  |                 | differencing     |                  |
    |                  |                 | [default         |                  |
    |                  |                 | 'central']       |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_options       | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | finite           |                  |
    |                  |                 | difference       |                  |
    |                  |                 | instance         |                  |
    +------------------+-----------------+------------------+------------------+
    | forward_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | forward mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | gather_stats     | OT_BOOL         | Deprecated       | casadi::Function |
    |                  |                 | option           | Internal         |
    |                  |                 | (ignored):       |                  |
    |                  |                 | Statistics are   |                  |
    |                  |                 | now always       |                  |
    |                  |                 | collected.       |                  |
    +------------------+-----------------+------------------+------------------+
    | input_scheme     | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | inputs_check     | OT_BOOL         | Throw exceptions | casadi::Function |
    |                  |                 | when the         | Internal         |
    |                  |                 | numerical values |                  |
    |                  |                 | of the inputs    |                  |
    |                  |                 | don't make sense |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_in       | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each input if it | Internal         |
    |                  |                 | should be        |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_out      | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each output if   | Internal         |
    |                  |                 | it should be     |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | jac_penalty      | OT_DOUBLE       | When requested   | casadi::Function |
    |                  |                 | for a number of  | Internal         |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | directions, it   |                  |
    |                  |                 | may be cheaper   |                  |
    |                  |                 | to compute first |                  |
    |                  |                 | the full         |                  |
    |                  |                 | jacobian and     |                  |
    |                  |                 | then multiply    |                  |
    |                  |                 | with seeds,      |                  |
    |                  |                 | rather than      |                  |
    |                  |                 | obtain the       |                  |
    |                  |                 | requested        |                  |
    |                  |                 | directions in a  |                  |
    |                  |                 | straightforward  |                  |
    |                  |                 | manner. Casadi   |                  |
    |                  |                 | uses a heuristic |                  |
    |                  |                 | to decide which  |                  |
    |                  |                 | is cheaper. A    |                  |
    |                  |                 | high value of    |                  |
    |                  |                 | 'jac_penalty'    |                  |
    |                  |                 | makes it less    |                  |
    |                  |                 | likely for the   |                  |
    |                  |                 | heurstic to      |                  |
    |                  |                 | chose the full   |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy. The    |                  |
    |                  |                 | special value -1 |                  |
    |                  |                 | indicates never  |                  |
    |                  |                 | to use the full  |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy         |                  |
    +------------------+-----------------+------------------+------------------+
    | jacobian_options | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | Jacobian         |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | jit              | OT_BOOL         | Use just-in-time | casadi::Function |
    |                  |                 | compiler to      | Internal         |
    |                  |                 | speed up the     |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_cleanup      | OT_BOOL         | Cleanup up the   | casadi::Function |
    |                  |                 | temporary source | Internal         |
    |                  |                 | file that jit    |                  |
    |                  |                 | creates.         |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_name         | OT_STRING       | The file name    | casadi::Function |
    |                  |                 | used to write    | Internal         |
    |                  |                 | out code. The    |                  |
    |                  |                 | actual file      |                  |
    |                  |                 | names used       |                  |
    |                  |                 | depend on 'jit_t |                  |
    |                  |                 | emp_suffix' and  |                  |
    |                  |                 | include          |                  |
    |                  |                 | extensions.      |                  |
    |                  |                 | Default:         |                  |
    |                  |                 | 'jit_tmp'        |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_options      | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | jit compiler.    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_serialize    | OT_STRING       | Specify          | casadi::Function |
    |                  |                 | behaviour when   | Internal         |
    |                  |                 | serializing a    |                  |
    |                  |                 | jitted function: |                  |
    |                  |                 | SOURCE|link|embe |                  |
    |                  |                 | d.               |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_temp_suffix  | OT_BOOL         | Use a temporary  | casadi::Function |
    |                  |                 | (seemingly       | Internal         |
    |                  |                 | random) filename |                  |
    |                  |                 | suffix for       |                  |
    |                  |                 | generated code   |                  |
    |                  |                 | and libraries.   |                  |
    |                  |                 | This is desired  |                  |
    |                  |                 | for thread-      |                  |
    |                  |                 | safety. This     |                  |
    |                  |                 | behaviour may    |                  |
    |                  |                 | defeat caching   |                  |
    |                  |                 | compiler         |                  |
    |                  |                 | wrappers.        |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | max_io           | OT_INT          | Acceptable       | casadi::Function |
    |                  |                 | number of inputs | Internal         |
    |                  |                 | and outputs.     |                  |
    |                  |                 | Warn if          |                  |
    |                  |                 | exceeded.        |                  |
    +------------------+-----------------+------------------+------------------+
    | max_num_dir      | OT_INT          | Specify the      | casadi::Function |
    |                  |                 | maximum number   | Internal         |
    |                  |                 | of directions    |                  |
    |                  |                 | for derivative   |                  |
    |                  |                 | functions.       |                  |
    |                  |                 | Overrules the    |                  |
    |                  |                 | builtin optimize |                  |
    |                  |                 | d_num_dir.       |                  |
    +------------------+-----------------+------------------+------------------+
    | never_inline     | OT_BOOL         | Forbid inlining. | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | output_scheme    | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | post_expand      | OT_BOOL         | After            | casadi::Function |
    |                  |                 | construction,    | Internal         |
    |                  |                 | expand this      |                  |
    |                  |                 | Function .       |                  |
    |                  |                 | Default: False   |                  |
    +------------------+-----------------+------------------+------------------+
    | post_expand_opti | OT_DICT         | Options to be    | casadi::Function |
    | ons              |                 | passed to post-  | Internal         |
    |                  |                 | construction     |                  |
    |                  |                 | expansion.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | print_canonical  | OT_BOOL         | When printing    | casadi::Function |
    |                  |                 | numerical        | Internal         |
    |                  |                 | matrices, use a  |                  |
    |                  |                 | format that is   |                  |
    |                  |                 | exact and        |                  |
    |                  |                 | reproducible in  |                  |
    |                  |                 | generated C      |                  |
    |                  |                 | code.            |                  |
    +------------------+-----------------+------------------+------------------+
    | print_in         | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_out        | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs          |                  |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_problem    | OT_BOOL         | Print a numeric  | casadi::Conic    |
    |                  |                 | description of   |                  |
    |                  |                 | the problem      |                  |
    +------------------+-----------------+------------------+------------------+
    | print_time       | OT_BOOL         | print            | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time. Implies    |                  |
    |                  |                 | record_time.     |                  |
    +------------------+-----------------+------------------+------------------+
    | record_time      | OT_BOOL         | record           | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time, for        |                  |
    |                  |                 | retrieval with   |                  |
    |                  |                 | stats().         |                  |
    +------------------+-----------------+------------------+------------------+
    | regularity_check | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when NaN or Inf  | ction            |
    |                  |                 | appears during   |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | reverse_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | reverse mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | user_data        | OT_VOIDPTR      | A user-defined   | casadi::Function |
    |                  |                 | field that can   | Internal         |
    |                  |                 | be used to       |                  |
    |                  |                 | identify the     |                  |
    |                  |                 | function or pass |                  |
    |                  |                 | additional       |                  |
    |                  |                 | information      |                  |
    +------------------+-----------------+------------------+------------------+
    | verbose          | OT_BOOL         | Verbose          | casadi::ProtoFun |
    |                  |                 | evaluation  for  | ction            |
    |                  |                 | debugging        |                  |
    +------------------+-----------------+------------------+------------------+

    >Input scheme: casadi::ConicInput (CONIC_NUM_IN = 12)

    +--------------+--------+--------------------------------------------------+
    |  Full name   | Short  |                   Description                    |
    +==============+========+==================================================+
    | CONIC_H      | h      | The square matrix H: sparse, (n x n). Only the   |
    |              |        | lower triangular part is actually used. The      |
    |              |        | matrix is assumed to be symmetrical.             |
    +--------------+--------+--------------------------------------------------+
    | CONIC_G      | g      | The vector g: dense, (n x 1)                     |
    +--------------+--------+--------------------------------------------------+
    | CONIC_A      | a      | The matrix A: sparse, (nc x n) - product with x  |
    |              |        | must be dense.                                   |
    +--------------+--------+--------------------------------------------------+
    | CONIC_LBA    | lba    | dense, (nc x 1)                                  |
    +--------------+--------+--------------------------------------------------+
    | CONIC_UBA    | uba    | dense, (nc x 1)                                  |
    +--------------+--------+--------------------------------------------------+
    | CONIC_LBX    | lbx    | dense, (n x 1)                                   |
    +--------------+--------+--------------------------------------------------+
    | CONIC_UBX    | ubx    | dense, (n x 1)                                   |
    +--------------+--------+--------------------------------------------------+
    | CONIC_X0     | x0     | dense, (n x 1)                                   |
    +--------------+--------+--------------------------------------------------+
    | CONIC_LAM_X0 | lam_x0 | dense                                            |
    +--------------+--------+--------------------------------------------------+
    | CONIC_LAM_A0 | lam_a0 | dense                                            |
    +--------------+--------+--------------------------------------------------+
    | CONIC_Q      | q      | The matrix Q: sparse symmetric, (np^2 x n)       |
    +--------------+--------+--------------------------------------------------+
    | CONIC_P      | p      | The matrix P: sparse symmetric, (np x np)        |
    +--------------+--------+--------------------------------------------------+

    >Output scheme: casadi::ConicOutput (CONIC_NUM_OUT = 4)

    +-------------+-------+---------------------------------------------------+
    |  Full name  | Short |                    Description                    |
    +=============+=======+===================================================+
    | CONIC_X     | x     | The primal solution.                              |
    +-------------+-------+---------------------------------------------------+
    | CONIC_COST  | cost  | The optimal cost.                                 |
    +-------------+-------+---------------------------------------------------+
    | CONIC_LAM_A | lam_a | The dual solution corresponding to linear bounds. |
    +-------------+-------+---------------------------------------------------+
    | CONIC_LAM_X | lam_x | The dual solution corresponding to simple bounds. |
    +-------------+-------+---------------------------------------------------+

    List of plugins
    - cbc

    - clarabel

    - clp

    - cplex

    - daqp

    - fatrop

    - gurobi

    - highs

    - hpipm

    - hpmpc

    - ooqp

    - osqp

    - proxqp

    - qpoases

    - sqic

    - superscs

    - ipqp

    - nlpsol

    - qrqp

    Note: some of the plugins in this list might not be available on your 

    system.  Also, there might be extra plugins available to you that are 
    not 
    listed here. You can obtain their documentation with  
    Conic.doc("myextraplugin")



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

    cbc
    ---



    Interface to Cbc solver for sparse Quadratic Programs

    Extra doc: https://github.com/casadi/casadi/wiki/L_221

    >List of available options

    +-------------+-----------------------+------------------------------------+
    |     Id      |         Type          |            Description             |
    +=============+=======================+====================================+
    | cbc         | OT_DICT               | Options to be passed to CBC.Three  |
    |             |                       | sets of options are supported. The |
    |             |                       | first can be found in              |
    |             |                       | OsiSolverParameters.hpp. The       |
    |             |                       | second can be found in             |
    |             |                       | CbcModel.hpp. The third are        |
    |             |                       | options that can be passed to      |
    |             |                       | CbcMain1.                          |
    +-------------+-----------------------+------------------------------------+
    | hot_start   | OT_BOOL               | Hot start with x0 [Default false]. |
    +-------------+-----------------------+------------------------------------+
    | sos_groups  | OT_INTVECTORVECTOR    | Definition of SOS groups by        |
    |             |                       | indices.                           |
    +-------------+-----------------------+------------------------------------+
    | sos_types   | OT_INTVECTOR          | Specify 1 or 2 for each SOS group. |
    +-------------+-----------------------+------------------------------------+
    | sos_weights | OT_DOUBLEVECTORVECTOR | Weights corresponding to SOS       |
    |             |                       | entries.                           |
    +-------------+-----------------------+------------------------------------+



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

    clarabel
    --------



    Interface to the Clarabel solver for sparse Quadratic Programs. See 
    the 
    Clarabel documentation (e.g. clarabel.dev) for more details.

    Extra doc: https://github.com/casadi/casadi/wiki/L_2bu

    >List of available options

    +----------+---------+-----------------------------------+
    |    Id    |  Type   |            Description            |
    +==========+=========+===================================+
    | clarabel | OT_DICT | Options to be passed to Clarabel. |
    +----------+---------+-----------------------------------+



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

    clp
    ---



    Interface to Clp solver for sparse Quadratic Programs

    Extra doc: https://github.com/casadi/casadi/wiki/L_22d

    >List of available options

    +-----+---------+----------------------------------------------------------+
    | Id  |  Type   |                       Description                        |
    +=====+=========+==========================================================+
    | clp | OT_DICT | Options to be passed to CLP. A first set of options can  |
    |     |         | be found in ClpParameters.hpp. eg. 'PrimalTolerance'.    |
    |     |         | There are other options in additions. 'AutomaticScaling' |
    |     |         | (bool) is recognised. 'initial_solve' (default off)      |
    |     |         | activates the use of Clp's initialSolve.                 |
    |     |         | 'initial_solve_options' takes a dictionary with          |
    |     |         | following keys (see ClpSolve.hpp): SolveType (string),   |
    |     |         | PresolveType (string), NumberPasses, SpecialOptions      |
    |     |         | (intvectorvector), IndependentOptions (intvectorvector). |
    +-----+---------+----------------------------------------------------------+



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

    cplex
    -----



    Interface to Cplex solver for sparse Quadratic Programs

    Extra doc: https://github.com/casadi/casadi/wiki/L_22a

    >List of available options

    +----------------+-----------------------+---------------------------------+
    |       Id       |         Type          |           Description           |
    +================+=======================+=================================+
    | cplex          | OT_DICT               | Options to be passed to CPLEX   |
    +----------------+-----------------------+---------------------------------+
    | dep_check      | OT_INT                | Detect redundant constraints.   |
    +----------------+-----------------------+---------------------------------+
    | dump_filename  | OT_STRING             | The filename to dump to.        |
    +----------------+-----------------------+---------------------------------+
    | dump_to_file   | OT_BOOL               | Dumps QP to file in CPLEX       |
    |                |                       | format.                         |
    +----------------+-----------------------+---------------------------------+
    | mip_start      | OT_BOOL               | Hot start integers with x0      |
    |                |                       | [Default false].                |
    +----------------+-----------------------+---------------------------------+
    | qp_method      | OT_INT                | Determines which CPLEX          |
    |                |                       | algorithm to use.               |
    +----------------+-----------------------+---------------------------------+
    | sos_groups     | OT_INTVECTORVECTOR    | Definition of SOS groups by     |
    |                |                       | indices.                        |
    +----------------+-----------------------+---------------------------------+
    | sos_types      | OT_INTVECTOR          | Specify 1 or 2 for each SOS     |
    |                |                       | group.                          |
    +----------------+-----------------------+---------------------------------+
    | sos_weights    | OT_DOUBLEVECTORVECTOR | Weights corresponding to SOS    |
    |                |                       | entries.                        |
    +----------------+-----------------------+---------------------------------+
    | tol            | OT_DOUBLE             | Tolerance of solver             |
    +----------------+-----------------------+---------------------------------+
    | version_suffix | OT_STRING             | Specify version of cplex to     |
    |                |                       | load. We will attempt to load l |
    |                |                       | ibcplex<version_suffix>.[so|dll |
    |                |                       | |dylib]. Default value is taken |
    |                |                       | from CPLEX_VERSION env          |
    |                |                       | variable.                       |
    +----------------+-----------------------+---------------------------------+
    | warm_start     | OT_BOOL               | Use warm start with simplex     |
    |                |                       | methods (affects only the       |
    |                |                       | simplex methods).               |
    +----------------+-----------------------+---------------------------------+



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

    daqp
    ----



    Interface to Daqp solver for sparse Quadratic Programs, see daqp.dev 
    for 
    more information and https://www.maths.ed.ac.uk/hall/Daqp/DaqpOptions.html  
    for a list of options.

    Extra doc: https://github.com/casadi/casadi/wiki/L_29l

    >List of available options

    +------+---------+-------------------------------+
    |  Id  |  Type   |          Description          |
    +======+=========+===============================+
    | daqp | OT_DICT | Options to be passed to Daqp. |
    +------+---------+-------------------------------+



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

    fatrop
    ------



    Interface to Fatrop Solver

    In order to use this interface, you must:

    Decision variables must only by state and control, and the variable 

    ordering must be [x0 u0 x1 u1 ...]

    The constraints must be in order: [ gap0 lincon0 gap1 lincon1 ]

    gap: Ak+1 = Ak xk + Bk uk lincon: yk= Ck xk + Dk uk



    ::

             A0 B0 -I
             C0 D0
                    A1 B1 -I
                    C1 D1



    where I must be a diagonal sparse matrix
    Either supply all of N, nx, ng, nu 
    options or rely on automatic 
    detection

    Extra doc: https://github.com/casadi/casadi/wiki/L_27g

    >List of available options

    +---------------------+--------------+-------------------------------------+
    |         Id          |     Type     |             Description             |
    +=====================+==============+=====================================+
    | N                   | OT_INT       | OCP horizon                         |
    +---------------------+--------------+-------------------------------------+
    | fatrop              | OT_DICT      | Options to be passed to fatrop      |
    +---------------------+--------------+-------------------------------------+
    | ng                  | OT_INTVECTOR | Number of non-dynamic constraints,  |
    |                     |              | length N+1                          |
    +---------------------+--------------+-------------------------------------+
    | nu                  | OT_INTVECTOR | Number of controls, length N        |
    +---------------------+--------------+-------------------------------------+
    | nx                  | OT_INTVECTOR | Number of states, length N+1        |
    +---------------------+--------------+-------------------------------------+
    | structure_detection | OT_STRING    | NONE | auto | manual                |
    +---------------------+--------------+-------------------------------------+



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

    gurobi
    ------



    Interface to the GUROBI Solver for quadratic programming

    Extra doc: https://github.com/casadi/casadi/wiki/L_22q

    >List of available options

    +-------------+-----------------------+------------------------------------+
    |     Id      |         Type          |            Description             |
    +=============+=======================+====================================+
    | gurobi      | OT_DICT               | Options to be passed to gurobi.    |
    +-------------+-----------------------+------------------------------------+
    | sos_groups  | OT_INTVECTORVECTOR    | Definition of SOS groups by        |
    |             |                       | indices.                           |
    +-------------+-----------------------+------------------------------------+
    | sos_types   | OT_INTVECTOR          | Specify 1 or 2 for each SOS group. |
    +-------------+-----------------------+------------------------------------+
    | sos_weights | OT_DOUBLEVECTORVECTOR | Weights corresponding to SOS       |
    |             |                       | entries.                           |
    +-------------+-----------------------+------------------------------------+
    | vtype       | OT_STRINGVECTOR       | Type of variables: [CONTINUOUS|bin |
    |             |                       | ary|integer|semicont|semiint]      |
    +-------------+-----------------------+------------------------------------+



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

    highs
    -----



    Interface to HiGHS solver for sparse Quadratic Programs, see 
    highs.dev for 
    more information and https://www.maths.ed.ac.uk/hall/HiGHS/HighsOptions.html
      for a list of options.

    Extra doc: https://github.com/casadi/casadi/wiki/L_29k

    >List of available options

    +-------+---------+--------------------------------+
    |  Id   |  Type   |          Description           |
    +=======+=========+================================+
    | highs | OT_DICT | Options to be passed to HiGHS. |
    +-------+---------+--------------------------------+



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

    hpipm
    -----



    Interface to HPIPM Solver

    In order to use this interface, you must:

    Decision variables must only by state and control, and the variable 

    ordering must be [x0 u0 x1 u1 ...]

    The constraints must be in order: [ gap0 lincon0 gap1 lincon1 ]

    gap: Ak+1 = Ak xk + Bk uk lincon: yk= Ck xk + Dk uk



    ::

             A0 B0 -I
             C0 D0
                    A1 B1 -I
                    C1 D1



    where I must be a diagonal sparse matrix
    Either supply all of N, nx, ng, nu 
    options or rely on automatic 
    detection

    Extra doc: https://github.com/casadi/casadi/wiki/L_242

    >List of available options

    +-------+--------------+--------------------------------------------------+
    |  Id   |     Type     |                   Description                    |
    +=======+==============+==================================================+
    | N     | OT_INT       | OCP horizon                                      |
    +-------+--------------+--------------------------------------------------+
    | hpipm | OT_DICT      | Options to be passed to hpipm                    |
    +-------+--------------+--------------------------------------------------+
    | inf   | OT_DOUBLE    | Replace infinities by this amount [default: 1e8] |
    +-------+--------------+--------------------------------------------------+
    | ng    | OT_INTVECTOR | Number of non-dynamic constraints, length N+1    |
    +-------+--------------+--------------------------------------------------+
    | nu    | OT_INTVECTOR | Number of controls, length N                     |
    +-------+--------------+--------------------------------------------------+
    | nx    | OT_INTVECTOR | Number of states, length N+1                     |
    +-------+--------------+--------------------------------------------------+



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

    hpmpc
    -----



    Interface to HMPC Solver

    In order to use this interface, you must:

    Decision variables must only by state and control, and the variable 

    ordering must be [x0 u0 x1 u1 ...]

    The constraints must be in order: [ gap0 lincon0 gap1 lincon1 ]

    gap: Ak+1 = Ak xk + Bk uk lincon: yk= Ck xk + Dk uk



    ::

             A0 B0 -I
             C0 D0
                    A1 B1 -I
                    C1 D1



    where I must be a diagonal sparse matrix
    Either supply all of N, nx, ng, nu 
    options or rely on automatic 
    detection

    Extra doc: https://github.com/casadi/casadi/wiki/L_22p

    >List of available options

    +----------------+--------------+------------------------------------------+
    |       Id       |     Type     |               Description                |
    +================+==============+==========================================+
    | N              | OT_INT       | OCP horizon                              |
    +----------------+--------------+------------------------------------------+
    | blasfeo_target | OT_STRING    | hpmpc target                             |
    +----------------+--------------+------------------------------------------+
    | inf            | OT_DOUBLE    | HPMPC cannot handle infinities.          |
    |                |              | Infinities will be replaced by this      |
    |                |              | option's value.                          |
    +----------------+--------------+------------------------------------------+
    | max_iter       | OT_INT       | Max number of iterations                 |
    +----------------+--------------+------------------------------------------+
    | mu0            | OT_DOUBLE    | Max element in cost function as estimate |
    |                |              | of max multiplier                        |
    +----------------+--------------+------------------------------------------+
    | ng             | OT_INTVECTOR | Number of non-dynamic constraints,       |
    |                |              | length N+1                               |
    +----------------+--------------+------------------------------------------+
    | nu             | OT_INTVECTOR | Number of controls, length N             |
    +----------------+--------------+------------------------------------------+
    | nx             | OT_INTVECTOR | Number of states, length N+1             |
    +----------------+--------------+------------------------------------------+
    | print_level    | OT_INT       | Amount of diagnostic printing [Default:  |
    |                |              | 1].                                      |
    +----------------+--------------+------------------------------------------+
    | target         | OT_STRING    | hpmpc target                             |
    +----------------+--------------+------------------------------------------+
    | tol            | OT_DOUBLE    | Tolerance in the duality measure         |
    +----------------+--------------+------------------------------------------+
    | warm_start     | OT_BOOL      | Use warm-starting                        |
    +----------------+--------------+------------------------------------------+



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

    ooqp
    ----



    Interface to the OOQP Solver for quadratic programming The current 

    implementation assumes that OOQP is configured with the MA27 sparse 
    linear 
    solver.

    NOTE: when doing multiple calls to evaluate(), check if you need to 

    reInit();

    Extra doc: https://github.com/casadi/casadi/wiki/L_222

    >List of available options

    +-------------+-----------+------------------------------------------------+
    |     Id      |   Type    |                  Description                   |
    +=============+===========+================================================+
    | artol       | OT_DOUBLE | tolerance as provided with setArTol to OOQP    |
    +-------------+-----------+------------------------------------------------+
    | mutol       | OT_DOUBLE | tolerance as provided with setMuTol to OOQP    |
    +-------------+-----------+------------------------------------------------+
    | print_level | OT_INT    | Print level. OOQP listens to print_level 0, 10 |
    |             |           | and 100                                        |
    +-------------+-----------+------------------------------------------------+



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

    osqp
    ----



    Interface to the OSQP Solver for quadratic programming

    Extra doc: https://github.com/casadi/casadi/wiki/L_220

    Interface to the PROXQP Solver for quadratic programming

    Extra doc: https://github.com/casadi/casadi/wiki/L_243

    >List of available options

    +-------------------+---------+--------------------------------------------+
    |        Id         |  Type   |                Description                 |
    +===================+=========+============================================+
    | osqp              | OT_DICT | const Options to be passed to osqp.        |
    +-------------------+---------+--------------------------------------------+
    | warm_start_dual   | OT_BOOL | Use lam_a0 and lam_x0 input to warmstart   |
    |                   |         | [Default: truw].                           |
    +-------------------+---------+--------------------------------------------+
    | warm_start_primal | OT_BOOL | Use x0 input to warmstart [Default: true]. |
    +-------------------+---------+--------------------------------------------+



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

    proxqp
    ------



    >List of available options

    +-------------------+---------+--------------------------------------------+
    |        Id         |  Type   |                Description                 |
    +===================+=========+============================================+
    | proxqp            | OT_DICT | const proxqp options.                      |
    +-------------------+---------+--------------------------------------------+
    | warm_start_dual   | OT_BOOL | Use y and z input to warmstart [Default:   |
    |                   |         | true].                                     |
    +-------------------+---------+--------------------------------------------+
    | warm_start_primal | OT_BOOL | Use x input to warmstart [Default: true].  |
    +-------------------+---------+--------------------------------------------+



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

    qpoases
    -------



    Interface to QPOases Solver for quadratic programming

    ::

      Extra doc: https://github.com/casadi/casadi/wiki/L_22o 




    >List of available options

    +-------------------------------+-----------+------------------------------+
    |              Id               |   Type    |         Description          |
    +===============================+===========+==============================+
    | CPUtime                       | OT_DOUBLE | The maximum allowed CPU time |
    |                               |           | in seconds for the whole     |
    |                               |           | initialisation (and the      |
    |                               |           | actually required one on     |
    |                               |           | output). Disabled if unset.  |
    +-------------------------------+-----------+------------------------------+
    | boundRelaxation               | OT_DOUBLE | Initial relaxation of bounds |
    |                               |           | to start homotopy and        |
    |                               |           | initial value for far        |
    |                               |           | bounds.                      |
    +-------------------------------+-----------+------------------------------+
    | boundTolerance                | OT_DOUBLE | If upper and lower bounds    |
    |                               |           | differ less than this        |
    |                               |           | tolerance, they are regarded |
    |                               |           | equal, i.e. as equality      |
    |                               |           | constraint.                  |
    +-------------------------------+-----------+------------------------------+
    | enableCholeskyRefactorisation | OT_INT    | Specifies the frequency of a |
    |                               |           | full re-factorisation of     |
    |                               |           | projected Hessian matrix: 0: |
    |                               |           | turns them off, 1: uses them |
    |                               |           | at each iteration etc.       |
    +-------------------------------+-----------+------------------------------+
    | enableDriftCorrection         | OT_INT    | Specifies the frequency of   |
    |                               |           | drift corrections: 0: turns  |
    |                               |           | them off.                    |
    +-------------------------------+-----------+------------------------------+
    | enableEqualities              | OT_BOOL   | Specifies whether equalities |
    |                               |           | should be treated as always  |
    |                               |           | active (True) or not (False) |
    +-------------------------------+-----------+------------------------------+
    | enableFarBounds               | OT_BOOL   | Enables the use of far       |
    |                               |           | bounds.                      |
    +-------------------------------+-----------+------------------------------+
    | enableFlippingBounds          | OT_BOOL   | Enables the use of flipping  |
    |                               |           | bounds.                      |
    +-------------------------------+-----------+------------------------------+
    | enableFullLITests             | OT_BOOL   | Enables condition-hardened   |
    |                               |           | (but more expensive) LI      |
    |                               |           | test.                        |
    +-------------------------------+-----------+------------------------------+
    | enableInertiaCorrection       | OT_BOOL   | Should working set be        |
    |                               |           | repaired when negative       |
    |                               |           | curvature is discovered      |
    |                               |           | during hotstart.             |
    +-------------------------------+-----------+------------------------------+
    | enableNZCTests                | OT_BOOL   | Enables nonzero curvature    |
    |                               |           | tests.                       |
    +-------------------------------+-----------+------------------------------+
    | enableRamping                 | OT_BOOL   | Enables ramping.             |
    +-------------------------------+-----------+------------------------------+
    | enableRegularisation          | OT_BOOL   | Enables automatic Hessian    |
    |                               |           | regularisation.              |
    +-------------------------------+-----------+------------------------------+
    | epsDen                        | OT_DOUBLE | Denominator tolerance for    |
    |                               |           | ratio tests.                 |
    +-------------------------------+-----------+------------------------------+
    | epsFlipping                   | OT_DOUBLE | Tolerance of squared         |
    |                               |           | Cholesky diagonal factor     |
    |                               |           | which triggers flipping      |
    |                               |           | bound.                       |
    +-------------------------------+-----------+------------------------------+
    | epsIterRef                    | OT_DOUBLE | Early termination tolerance  |
    |                               |           | for iterative refinement.    |
    +-------------------------------+-----------+------------------------------+
    | epsLITests                    | OT_DOUBLE | Tolerance for linear         |
    |                               |           | independence tests.          |
    +-------------------------------+-----------+------------------------------+
    | epsNZCTests                   | OT_DOUBLE | Tolerance for nonzero        |
    |                               |           | curvature tests.             |
    +-------------------------------+-----------+------------------------------+
    | epsNum                        | OT_DOUBLE | Numerator tolerance for      |
    |                               |           | ratio tests.                 |
    +-------------------------------+-----------+------------------------------+
    | epsRegularisation             | OT_DOUBLE | Scaling factor of identity   |
    |                               |           | matrix used for Hessian      |
    |                               |           | regularisation.              |
    +-------------------------------+-----------+------------------------------+
    | finalRamping                  | OT_DOUBLE | Final value for ramping      |
    |                               |           | strategy.                    |
    +-------------------------------+-----------+------------------------------+
    | growFarBounds                 | OT_DOUBLE | Factor to grow far bounds.   |
    +-------------------------------+-----------+------------------------------+
    | hessian_type                  | OT_STRING | Type of Hessian - see        |
    |                               |           | qpOASES documentation [UNKNO |
    |                               |           | WN|posdef|semidef|indef|zero |
    |                               |           | |identity]]                  |
    +-------------------------------+-----------+------------------------------+
    | initialFarBounds              | OT_DOUBLE | Initial size for far bounds. |
    +-------------------------------+-----------+------------------------------+
    | initialRamping                | OT_DOUBLE | Start value for ramping      |
    |                               |           | strategy.                    |
    +-------------------------------+-----------+------------------------------+
    | initialStatusBounds           | OT_STRING | Initial status of bounds at  |
    |                               |           | first iteration.             |
    +-------------------------------+-----------+------------------------------+
    | linsol_plugin                 | OT_STRING | Linear solver plugin         |
    +-------------------------------+-----------+------------------------------+
    | maxDualJump                   | OT_DOUBLE | Maximum allowed jump in dual |
    |                               |           | variables in linear          |
    |                               |           | independence tests.          |
    +-------------------------------+-----------+------------------------------+
    | maxPrimalJump                 | OT_DOUBLE | Maximum allowed jump in      |
    |                               |           | primal variables in nonzero  |
    |                               |           | curvature tests.             |
    +-------------------------------+-----------+------------------------------+
    | max_schur                     | OT_INT    | Maximal number of Schur      |
    |                               |           | updates [75]                 |
    +-------------------------------+-----------+------------------------------+
    | nWSR                          | OT_INT    | The maximum number of        |
    |                               |           | working set recalculations   |
    |                               |           | to be performed during the   |
    |                               |           | initial homotopy. Default is |
    |                               |           | 5(nx + nc)                   |
    +-------------------------------+-----------+------------------------------+
    | numRefinementSteps            | OT_INT    | Maximum number of iterative  |
    |                               |           | refinement steps.            |
    +-------------------------------+-----------+------------------------------+
    | numRegularisationSteps        | OT_INT    | Maximum number of successive |
    |                               |           | regularisation steps.        |
    +-------------------------------+-----------+------------------------------+
    | printLevel                    | OT_STRING | Defines the amount of text   |
    |                               |           | output during QP solution,   |
    |                               |           | see Section 5.7              |
    +-------------------------------+-----------+------------------------------+
    | schur                         | OT_BOOL   | Use Schur Complement         |
    |                               |           | Approach [false]             |
    +-------------------------------+-----------+------------------------------+
    | sparse                        | OT_BOOL   | Formulate the QP using       |
    |                               |           | sparse matrices. [false]     |
    +-------------------------------+-----------+------------------------------+
    | terminationTolerance          | OT_DOUBLE | Relative termination         |
    |                               |           | tolerance to stop homotopy.  |
    +-------------------------------+-----------+------------------------------+



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

    sqic
    ----



    Interface to the SQIC solver for quadratic programming

    Extra doc: https://github.com/casadi/casadi/wiki/L_21s



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

    superscs
    --------



    Interface to the SuperSCS solver for conic programming

    Joris Gillis, 2019

    Extra doc: https://github.com/casadi/casadi/wiki/L_21z

    >List of available options

    +----------+---------+-----------------------------------+
    |    Id    |  Type   |            Description            |
    +==========+=========+===================================+
    | superscs | OT_DICT | Options to be passed to superscs. |
    +----------+---------+-----------------------------------+



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

    ipqp
    ----



    Solves QPs using a Mehrotra predictor-corrector interior point method

    Extra doc: https://github.com/casadi/casadi/wiki/L_23c

    >List of available options

    +-----------------------+-----------+--------------------------------------+
    |          Id           |   Type    |             Description              |
    +=======================+===========+======================================+
    | constr_viol_tol       | OT_DOUBLE | Constraint violation tolerance       |
    |                       |           | [1e-8].                              |
    +-----------------------+-----------+--------------------------------------+
    | dual_inf_tol          | OT_DOUBLE | Dual feasibility violation tolerance |
    |                       |           | [1e-8]                               |
    +-----------------------+-----------+--------------------------------------+
    | linear_solver         | OT_STRING | A custom linear solver creator       |
    |                       |           | function [default: ldl]              |
    +-----------------------+-----------+--------------------------------------+
    | linear_solver_options | OT_DICT   | Options to be passed to the linear   |
    |                       |           | solver                               |
    +-----------------------+-----------+--------------------------------------+
    | max_iter              | OT_INT    | Maximum number of iterations [1000]. |
    +-----------------------+-----------+--------------------------------------+
    | min_lam               | OT_DOUBLE | Smallest multiplier treated as       |
    |                       |           | inactive for the initial active set  |
    |                       |           | [0].                                 |
    +-----------------------+-----------+--------------------------------------+
    | print_header          | OT_BOOL   | Print header [true].                 |
    +-----------------------+-----------+--------------------------------------+
    | print_info            | OT_BOOL   | Print info [true].                   |
    +-----------------------+-----------+--------------------------------------+
    | print_iter            | OT_BOOL   | Print iterations [true].             |
    +-----------------------+-----------+--------------------------------------+



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

    nlpsol
    ------



    Solve QPs using an  Nlpsol Use the 'nlpsol' option to specify the NLP solver
     to use.

    Extra doc: https://github.com/casadi/casadi/wiki/L_235

    >List of available options

    +----------------+-----------+---------------------------------+
    |       Id       |   Type    |           Description           |
    +================+===========+=================================+
    | nlpsol         | OT_STRING | Name of solver.                 |
    +----------------+-----------+---------------------------------+
    | nlpsol_options | OT_DICT   | Options to be passed to solver. |
    +----------------+-----------+---------------------------------+



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

    qrqp
    ----



    Solve QPs using an active-set method

    Extra doc: https://github.com/casadi/casadi/wiki/L_22y

    >List of available options

    +-----------------+-----------+--------------------------------------------+
    |       Id        |   Type    |                Description                 |
    +=================+===========+============================================+
    | constr_viol_tol | OT_DOUBLE | Constraint violation tolerance [1e-8].     |
    +-----------------+-----------+--------------------------------------------+
    | dual_inf_tol    | OT_DOUBLE | Dual feasibility violation tolerance       |
    |                 |           | [1e-8]                                     |
    +-----------------+-----------+--------------------------------------------+
    | max_iter        | OT_INT    | Maximum number of iterations [1000].       |
    +-----------------+-----------+--------------------------------------------+
    | min_lam         | OT_DOUBLE | Smallest multiplier treated as inactive    |
    |                 |           | for the initial active set [0].            |
    +-----------------+-----------+--------------------------------------------+
    | print_header    | OT_BOOL   | Print header [true].                       |
    +-----------------+-----------+--------------------------------------------+
    | print_info      | OT_BOOL   | Print info [true].                         |
    +-----------------+-----------+--------------------------------------------+
    | print_iter      | OT_BOOL   | Print iterations [true].                   |
    +-----------------+-----------+--------------------------------------------+
    | print_lincomb   | OT_BOOL   | Print dependant linear combinations of     |
    |                 |           | constraints [false]. Printed numbers are   |
    |                 |           | 0-based indices into the vector of [simple |
    |                 |           | bounds;linear bounds]                      |
    +-----------------+-----------+--------------------------------------------+

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_21n

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L44

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L44-L47



    """
    return _casadi.conic(*args)

def qpsol(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      qpsol(str name, str solver, dict:SX qp, dict opts) -> Function
      qpsol(str name, str solver, dict:MX qp, dict opts) -> Function



    """
    return _casadi.qpsol(*args)

def conic_in(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      conic_in() -> [str]
      conic_in(int ind) -> str

    Get QP solver input scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1eg

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L73

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L73-L90


    .......

    ::

      conic_in()



    [INTERNAL] 
    Get input scheme of QP solvers.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ee

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L61

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L61-L65


    .............


    .......

    ::

      conic_in(int ind)



    [INTERNAL] 
    Get QP solver input scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1eg

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L73

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L73-L90


    .............



    """
    return _casadi.conic_in(*args)

def conic_out(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      conic_out() -> [str]
      conic_out(int ind) -> str

    Get output scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1eh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L92

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L92-L101


    .......

    ::

      conic_out(int ind)



    [INTERNAL] 
    Get output scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1eh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L92

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L92-L101


    .............


    .......

    ::

      conic_out()



    [INTERNAL] 
    Get QP solver output scheme of QP solvers.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ef

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L67

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L67-L71


    .............



    """
    return _casadi.conic_out(*args)

def conic_n_in(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      conic_n_in() -> int

    Get the number of QP solver inputs.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ei

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L103

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L103-L105




    """
    return _casadi.conic_n_in(*args)

def conic_n_out(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      conic_n_out() -> int

    Get the number of QP solver outputs.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ej

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L107

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L107-L109




    """
    return _casadi.conic_n_out(*args)

def conic_options(*args) -> "std::vector< std::string,std::allocator< std::string > >":
    """
      [INTERNAL] 

    ::

      conic_options(str name) -> [str]

    Get all options for a plugin.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ek

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L564

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L564-L566




    """
    return _casadi.conic_options(*args)

def conic_option_type(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      conic_option_type(str name, str op) -> str

    Get type info for a particular option.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1el

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L568

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L568-L570




    """
    return _casadi.conic_option_type(*args)

def conic_option_info(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      conic_option_info(str name, str op) -> str

    Get documentation for a particular option.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1em

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L572

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L572-L574




    """
    return _casadi.conic_option_info(*args)

def has_conic(*args) -> "bool":
    """
      [INTERNAL] 

    ::

      has_conic(str name) -> bool

    Check if a particular plugin is available.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L32

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L32-L34



    """
    return _casadi.has_conic(*args)

def load_conic(*args) -> "void":
    """
      [INTERNAL] 

    ::

      load_conic(str name)

    Explicitly load a plugin dynamically.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L36

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L36-L38



    """
    return _casadi.load_conic(*args)

def doc_conic(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      doc_conic(str name) -> str

    Get the documentation string for a plugin.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L40

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L40-L42



    """
    return _casadi.doc_conic(*args)

def conic_debug(*args) -> "void":
    """
      [INTERNAL] 

    ::

      conic_debug(Function f, std::ostream & file)
      conic_debug(Function f, str filename)

    Generate native code in the interfaced language for debugging

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L55

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L55-L59


    .......

    ::

      conic_debug(Function f, std::ostream & file)



    [INTERNAL] 
    Generate native code in the interfaced language for debugging

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L55

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L55-L59


    .............


    .......

    ::

      conic_debug(Function f, str filename)



    [INTERNAL] 
    Generate native code in the interfaced language for debugging

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.hpp#L49

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/conic.cpp#L49-L53


    .............



    """
    return _casadi.conic_debug(*args)

def nlpsol(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      nlpsol(str name, str solver, Importer compiler, dict opts) -> Function
      nlpsol(str name, str solver, NlpBuilder nl, dict opts) -> Function
      nlpsol(str name, str solver, dict:SX nlp, dict opts) -> Function
      nlpsol(str name, str solver, dict:MX nlp, dict opts) -> Function
      nlpsol(str name, str solver, str fname, dict opts) -> Function
      nlpsol(str name, str solver, Function nlp, dict opts) -> Function


    .......

    ::

      nlpsol(str name, str solver, dict:SX nlp, dict opts)



    [INTERNAL]

    Create an NLP solver Creates a solver for the following parametric 

    nonlinear program (NLP):

    ::

      min          F(x, p)
      x

      subject to
      LBX <=   x    <= UBX
      LBG <= G(x, p) <= UBG
      p  == P

      nx: number of decision variables
      ng: number of constraints
      np: number of parameters

    General information

    >List of available options

    +------------------+-----------------+------------------+------------------+
    |        Id        |      Type       |   Description    |     Used in      |
    +==================+=================+==================+==================+
    | ad_weight        | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for derivative   | Internal         |
    |                  |                 | calculation.When |                  |
    |                  |                 | there is an      |                  |
    |                  |                 | option of either |                  |
    |                  |                 | using forward or |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | directional      |                  |
    |                  |                 | derivatives, the |                  |
    |                  |                 | condition ad_wei |                  |
    |                  |                 | ght*nf<=(1-      |                  |
    |                  |                 | ad_weight)*na is |                  |
    |                  |                 | used where nf    |                  |
    |                  |                 | and na are       |                  |
    |                  |                 | estimates of the |                  |
    |                  |                 | number of        |                  |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | mode directional |                  |
    |                  |                 | derivatives      |                  |
    |                  |                 | needed. By       |                  |
    |                  |                 | default,         |                  |
    |                  |                 | ad_weight is     |                  |
    |                  |                 | calculated       |                  |
    |                  |                 | automatically,   |                  |
    |                  |                 | but this can be  |                  |
    |                  |                 | overridden by    |                  |
    |                  |                 | setting this     |                  |
    |                  |                 | option. In       |                  |
    |                  |                 | particular, 0    |                  |
    |                  |                 | means forcing    |                  |
    |                  |                 | forward mode and |                  |
    |                  |                 | 1 forcing        |                  |
    |                  |                 | reverse mode.    |                  |
    |                  |                 | Leave unset for  |                  |
    |                  |                 | (class specific) |                  |
    |                  |                 | heuristics.      |                  |
    +------------------+-----------------+------------------+------------------+
    | ad_weight_sp     | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for sparsity     | Internal         |
    |                  |                 | pattern          |                  |
    |                  |                 | calculation calc |                  |
    |                  |                 | ulation.Override |                  |
    |                  |                 | s default        |                  |
    |                  |                 | behavior. Set to |                  |
    |                  |                 | 0 and 1 to force |                  |
    |                  |                 | forward and      |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | respectively.    |                  |
    |                  |                 | Cf. option       |                  |
    |                  |                 | "ad_weight".     |                  |
    |                  |                 | When set to -1,  |                  |
    |                  |                 | sparsity is      |                  |
    |                  |                 | completely       |                  |
    |                  |                 | ignored and      |                  |
    |                  |                 | dense matrices   |                  |
    |                  |                 | are used.        |                  |
    +------------------+-----------------+------------------+------------------+
    | always_inline    | OT_BOOL         | Force inlining.  | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | bound_consistenc | OT_BOOL         | Ensure that      | casadi::Nlpsol   |
    | y                |                 | primal-dual      |                  |
    |                  |                 | solution is      |                  |
    |                  |                 | consistent with  |                  |
    |                  |                 | the bounds       |                  |
    +------------------+-----------------+------------------+------------------+
    | cache            | OT_DICT         | Prepopulate the  | casadi::Function |
    |                  |                 | function cache.  | Internal         |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | calc_f           | OT_BOOL         | Calculate 'f' in | casadi::Nlpsol   |
    |                  |                 | the Nlpsol base  |                  |
    |                  |                 | class            |                  |
    +------------------+-----------------+------------------+------------------+
    | calc_g           | OT_BOOL         | Calculate 'g' in | casadi::Nlpsol   |
    |                  |                 | the Nlpsol base  |                  |
    |                  |                 | class            |                  |
    +------------------+-----------------+------------------+------------------+
    | calc_lam_p       | OT_BOOL         | Calculate        | casadi::Nlpsol   |
    |                  |                 | 'lam_p' in the   |                  |
    |                  |                 | Nlpsol base      |                  |
    |                  |                 | class            |                  |
    +------------------+-----------------+------------------+------------------+
    | calc_lam_x       | OT_BOOL         | Calculate        | casadi::Nlpsol   |
    |                  |                 | 'lam_x' in the   |                  |
    |                  |                 | Nlpsol base      |                  |
    |                  |                 | class            |                  |
    +------------------+-----------------+------------------+------------------+
    | calc_multipliers | OT_BOOL         | Calculate        | casadi::Nlpsol   |
    |                  |                 | Lagrange         |                  |
    |                  |                 | multipliers in   |                  |
    |                  |                 | the Nlpsol base  |                  |
    |                  |                 | class            |                  |
    +------------------+-----------------+------------------+------------------+
    | common_options   | OT_DICT         | Options for      | casadi::OracleFu |
    |                  |                 | auto-generated   | nction           |
    |                  |                 | functions        |                  |
    +------------------+-----------------+------------------+------------------+
    | compiler         | OT_STRING       | Just-in-time     | casadi::Function |
    |                  |                 | compiler plugin  | Internal         |
    |                  |                 | to be used.      |                  |
    +------------------+-----------------+------------------+------------------+
    | custom_jacobian  | OT_FUNCTION     | Override         | casadi::Function |
    |                  |                 | CasADi's AD. Use | Internal         |
    |                  |                 | together with    |                  |
    |                  |                 | 'jac_penalty':   |                  |
    |                  |                 | 0. Note: Highly  |                  |
    |                  |                 | experimental.    |                  |
    |                  |                 | Syntax may break |                  |
    |                  |                 | often.           |                  |
    +------------------+-----------------+------------------+------------------+
    | der_options      | OT_DICT         | Default options  | casadi::Function |
    |                  |                 | to be used to    | Internal         |
    |                  |                 | populate         |                  |
    |                  |                 | forward_options, |                  |
    |                  |                 | reverse_options, |                  |
    |                  |                 | and              |                  |
    |                  |                 | jacobian_options |                  |
    |                  |                 | before those     |                  |
    |                  |                 | options are      |                  |
    |                  |                 | merged in.       |                  |
    +------------------+-----------------+------------------+------------------+
    | derivative_of    | OT_FUNCTION     | The function is  | casadi::Function |
    |                  |                 | a derivative of  | Internal         |
    |                  |                 | another          |                  |
    |                  |                 | function. The    |                  |
    |                  |                 | type of          |                  |
    |                  |                 | derivative       |                  |
    |                  |                 | (directional     |                  |
    |                  |                 | derivative,      |                  |
    |                  |                 | Jacobian) is     |                  |
    |                  |                 | inferred from    |                  |
    |                  |                 | the function     |                  |
    |                  |                 | name.            |                  |
    +------------------+-----------------+------------------+------------------+
    | detect_simple_bo | OT_BOOL         | Automatically    | casadi::Nlpsol   |
    | unds             |                 | detect simple    |                  |
    |                  |                 | bounds (lbx/ubx) |                  |
    |                  |                 | (default false). |                  |
    |                  |                 | This is          |                  |
    |                  |                 | hopefully        |                  |
    |                  |                 | beneficial to    |                  |
    |                  |                 | speed and        |                  |
    |                  |                 | robustness but   |                  |
    |                  |                 | may also have    |                  |
    |                  |                 | adverse affects: |                  |
    |                  |                 | 1) Subtleties in |                  |
    |                  |                 | heuristics and   |                  |
    |                  |                 | stopping         |                  |
    |                  |                 | criteria may     |                  |
    |                  |                 | change the       |                  |
    |                  |                 | solution, 2)     |                  |
    |                  |                 | IPOPT may lie    |                  |
    |                  |                 | about            |                  |
    |                  |                 | multipliers of   |                  |
    |                  |                 | simple equality  |                  |
    |                  |                 | bounds unless 'f |                  |
    |                  |                 | ixed_variable_tr |                  |
    |                  |                 | eatment' is set  |                  |
    |                  |                 | to               |                  |
    |                  |                 | 'relax_bounds'.  |                  |
    +------------------+-----------------+------------------+------------------+
    | detect_simple_bo | OT_BOOLVECTOR   | For internal use | casadi::Nlpsol   |
    | unds_is_simple   |                 | only.            |                  |
    +------------------+-----------------+------------------+------------------+
    | detect_simple_bo | OT_FUNCTION     | For internal use | casadi::Nlpsol   |
    | unds_parts       |                 | only.            |                  |
    +------------------+-----------------+------------------+------------------+
    | detect_simple_bo | OT_INTVECTOR    | For internal use | casadi::Nlpsol   |
    | unds_target_x    |                 | only.            |                  |
    +------------------+-----------------+------------------+------------------+
    | discrete         | OT_BOOLVECTOR   | Indicates which  | casadi::Nlpsol   |
    |                  |                 | of the variables |                  |
    |                  |                 | are discrete,    |                  |
    |                  |                 | i.e. integer-    |                  |
    |                  |                 | valued           |                  |
    +------------------+-----------------+------------------+------------------+
    | dump             | OT_BOOL         | Dump function to | casadi::Function |
    |                  |                 | file upon first  | Internal         |
    |                  |                 | evaluation.      |                  |
    |                  |                 | [false]          |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_dir         | OT_STRING       | Directory to     | casadi::Function |
    |                  |                 | dump             | Internal         |
    |                  |                 | inputs/outputs   |                  |
    |                  |                 | to. Make sure    |                  |
    |                  |                 | the directory    |                  |
    |                  |                 | exists [.]       |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_format      | OT_STRING       | Choose file      | casadi::Function |
    |                  |                 | format to dump   | Internal         |
    |                  |                 | matrices. See    |                  |
    |                  |                 | DM.from_file     |                  |
    |                  |                 | [mtx]            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_in          | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | to file          |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_out         | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs to file  |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_fd        | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation by   |                  |
    |                  |                 | finite           |                  |
    |                  |                 | differencing.    |                  |
    |                  |                 | [default:        |                  |
    |                  |                 | false]]          |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_forward   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using forward    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_jacobian  | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobians of all |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | outputs with     |                  |
    |                  |                 | respect to all   |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | inputs - if      |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_reverse   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | transposed       |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using reverse    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | equality         | OT_BOOLVECTOR   | Indicate an      | casadi::Nlpsol   |
    |                  |                 | upfront hint     |                  |
    |                  |                 | which of the     |                  |
    |                  |                 | constraints are  |                  |
    |                  |                 | equalities. Some |                  |
    |                  |                 | solvers may be   |                  |
    |                  |                 | able to exploit  |                  |
    |                  |                 | this knowledge.  |                  |
    |                  |                 | When true, the   |                  |
    |                  |                 | corresponding    |                  |
    |                  |                 | lower and upper  |                  |
    |                  |                 | bounds are       |                  |
    |                  |                 | assumed equal.   |                  |
    |                  |                 | When false, the  |                  |
    |                  |                 | corresponding    |                  |
    |                  |                 | bounds may be    |                  |
    |                  |                 | equal or         |                  |
    |                  |                 | different.       |                  |
    +------------------+-----------------+------------------+------------------+
    | error_on_fail    | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when function    | ction            |
    |                  |                 | evaluation fails |                  |
    |                  |                 | (default true).  |                  |
    +------------------+-----------------+------------------+------------------+
    | eval_errors_fata | OT_BOOL         | When errors      | casadi::Nlpsol   |
    | l                |                 | occur during     |                  |
    |                  |                 | evaluation of    |                  |
    |                  |                 | f,g,...,stop the |                  |
    |                  |                 | iterations       |                  |
    +------------------+-----------------+------------------+------------------+
    | expand           | OT_BOOL         | Replace MX with  | casadi::OracleFu |
    |                  |                 | SX expressions   | nction           |
    |                  |                 | in problem       |                  |
    |                  |                 | formulation      |                  |
    |                  |                 | [false] This     |                  |
    |                  |                 | happens before   |                  |
    |                  |                 | creating         |                  |
    |                  |                 | derivatives      |                  |
    |                  |                 | unless indicated |                  |
    |                  |                 | by               |                  |
    |                  |                 | postpone_expand  |                  |
    +------------------+-----------------+------------------+------------------+
    | external_transfo | OT_VECTORVECTOR | List of external | casadi::Function |
    | rm               |                 | _transform       | Internal         |
    |                  |                 | instruction      |                  |
    |                  |                 | arguments.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_method        | OT_STRING       | Method for       | casadi::Function |
    |                  |                 | finite           | Internal         |
    |                  |                 | differencing     |                  |
    |                  |                 | [default         |                  |
    |                  |                 | 'central']       |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_options       | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | finite           |                  |
    |                  |                 | difference       |                  |
    |                  |                 | instance         |                  |
    +------------------+-----------------+------------------+------------------+
    | forward_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | forward mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | gather_stats     | OT_BOOL         | Deprecated       | casadi::Function |
    |                  |                 | option           | Internal         |
    |                  |                 | (ignored):       |                  |
    |                  |                 | Statistics are   |                  |
    |                  |                 | now always       |                  |
    |                  |                 | collected.       |                  |
    +------------------+-----------------+------------------+------------------+
    | ignore_check_vec | OT_BOOL         | If set to true,  | casadi::Nlpsol   |
    |                  |                 | the input shape  |                  |
    |                  |                 | of F will not be |                  |
    |                  |                 | checked.         |                  |
    +------------------+-----------------+------------------+------------------+
    | input_scheme     | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | inputs_check     | OT_BOOL         | Throw exceptions | casadi::Function |
    |                  |                 | when the         | Internal         |
    |                  |                 | numerical values |                  |
    |                  |                 | of the inputs    |                  |
    |                  |                 | don't make sense |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_in       | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each input if it | Internal         |
    |                  |                 | should be        |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_out      | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each output if   | Internal         |
    |                  |                 | it should be     |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | iteration_callba | OT_FUNCTION     | A function that  | casadi::Nlpsol   |
    | ck               |                 | will be called   |                  |
    |                  |                 | at each          |                  |
    |                  |                 | iteration with   |                  |
    |                  |                 | the solver as    |                  |
    |                  |                 | input. Check     |                  |
    |                  |                 | documentation of |                  |
    |                  |                 | Callback .       |                  |
    +------------------+-----------------+------------------+------------------+
    | iteration_callba | OT_BOOL         | If set to true,  | casadi::Nlpsol   |
    | ck_ignore_errors |                 | errors thrown by |                  |
    |                  |                 | iteration_callba |                  |
    |                  |                 | ck will be       |                  |
    |                  |                 | ignored.         |                  |
    +------------------+-----------------+------------------+------------------+
    | iteration_callba | OT_INT          | Only call the    | casadi::Nlpsol   |
    | ck_step          |                 | callback         |                  |
    |                  |                 | function every   |                  |
    |                  |                 | few iterations.  |                  |
    +------------------+-----------------+------------------+------------------+
    | jac_penalty      | OT_DOUBLE       | When requested   | casadi::Function |
    |                  |                 | for a number of  | Internal         |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | directions, it   |                  |
    |                  |                 | may be cheaper   |                  |
    |                  |                 | to compute first |                  |
    |                  |                 | the full         |                  |
    |                  |                 | jacobian and     |                  |
    |                  |                 | then multiply    |                  |
    |                  |                 | with seeds,      |                  |
    |                  |                 | rather than      |                  |
    |                  |                 | obtain the       |                  |
    |                  |                 | requested        |                  |
    |                  |                 | directions in a  |                  |
    |                  |                 | straightforward  |                  |
    |                  |                 | manner. Casadi   |                  |
    |                  |                 | uses a heuristic |                  |
    |                  |                 | to decide which  |                  |
    |                  |                 | is cheaper. A    |                  |
    |                  |                 | high value of    |                  |
    |                  |                 | 'jac_penalty'    |                  |
    |                  |                 | makes it less    |                  |
    |                  |                 | likely for the   |                  |
    |                  |                 | heurstic to      |                  |
    |                  |                 | chose the full   |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy. The    |                  |
    |                  |                 | special value -1 |                  |
    |                  |                 | indicates never  |                  |
    |                  |                 | to use the full  |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy         |                  |
    +------------------+-----------------+------------------+------------------+
    | jacobian_options | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | Jacobian         |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | jit              | OT_BOOL         | Use just-in-time | casadi::Function |
    |                  |                 | compiler to      | Internal         |
    |                  |                 | speed up the     |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_cleanup      | OT_BOOL         | Cleanup up the   | casadi::Function |
    |                  |                 | temporary source | Internal         |
    |                  |                 | file that jit    |                  |
    |                  |                 | creates.         |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_name         | OT_STRING       | The file name    | casadi::Function |
    |                  |                 | used to write    | Internal         |
    |                  |                 | out code. The    |                  |
    |                  |                 | actual file      |                  |
    |                  |                 | names used       |                  |
    |                  |                 | depend on 'jit_t |                  |
    |                  |                 | emp_suffix' and  |                  |
    |                  |                 | include          |                  |
    |                  |                 | extensions.      |                  |
    |                  |                 | Default:         |                  |
    |                  |                 | 'jit_tmp'        |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_options      | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | jit compiler.    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_serialize    | OT_STRING       | Specify          | casadi::Function |
    |                  |                 | behaviour when   | Internal         |
    |                  |                 | serializing a    |                  |
    |                  |                 | jitted function: |                  |
    |                  |                 | SOURCE|link|embe |                  |
    |                  |                 | d.               |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_temp_suffix  | OT_BOOL         | Use a temporary  | casadi::Function |
    |                  |                 | (seemingly       | Internal         |
    |                  |                 | random) filename |                  |
    |                  |                 | suffix for       |                  |
    |                  |                 | generated code   |                  |
    |                  |                 | and libraries.   |                  |
    |                  |                 | This is desired  |                  |
    |                  |                 | for thread-      |                  |
    |                  |                 | safety. This     |                  |
    |                  |                 | behaviour may    |                  |
    |                  |                 | defeat caching   |                  |
    |                  |                 | compiler         |                  |
    |                  |                 | wrappers.        |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | max_io           | OT_INT          | Acceptable       | casadi::Function |
    |                  |                 | number of inputs | Internal         |
    |                  |                 | and outputs.     |                  |
    |                  |                 | Warn if          |                  |
    |                  |                 | exceeded.        |                  |
    +------------------+-----------------+------------------+------------------+
    | max_num_dir      | OT_INT          | Specify the      | casadi::Function |
    |                  |                 | maximum number   | Internal         |
    |                  |                 | of directions    |                  |
    |                  |                 | for derivative   |                  |
    |                  |                 | functions.       |                  |
    |                  |                 | Overrules the    |                  |
    |                  |                 | builtin optimize |                  |
    |                  |                 | d_num_dir.       |                  |
    +------------------+-----------------+------------------+------------------+
    | min_lam          | OT_DOUBLE       | Minimum allowed  | casadi::Nlpsol   |
    |                  |                 | multiplier value |                  |
    +------------------+-----------------+------------------+------------------+
    | monitor          | OT_STRINGVECTOR | Set of user      | casadi::OracleFu |
    |                  |                 | problem          | nction           |
    |                  |                 | functions to be  |                  |
    |                  |                 | monitored        |                  |
    +------------------+-----------------+------------------+------------------+
    | never_inline     | OT_BOOL         | Forbid inlining. | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | no_nlp_grad      | OT_BOOL         | Prevent the      | casadi::Nlpsol   |
    |                  |                 | creation of the  |                  |
    |                  |                 | 'nlp_grad'       |                  |
    |                  |                 | function         |                  |
    +------------------+-----------------+------------------+------------------+
    | oracle_options   | OT_DICT         | Options to be    | casadi::Nlpsol   |
    |                  |                 | passed to the    |                  |
    |                  |                 | oracle function  |                  |
    +------------------+-----------------+------------------+------------------+
    | output_scheme    | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | post_expand      | OT_BOOL         | After            | casadi::Function |
    |                  |                 | construction,    | Internal         |
    |                  |                 | expand this      |                  |
    |                  |                 | Function .       |                  |
    |                  |                 | Default: False   |                  |
    +------------------+-----------------+------------------+------------------+
    | post_expand_opti | OT_DICT         | Options to be    | casadi::Function |
    | ons              |                 | passed to post-  | Internal         |
    |                  |                 | construction     |                  |
    |                  |                 | expansion.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | postpone_expand  | OT_BOOL         | When expand is   | casadi::OracleFu |
    |                  |                 | active, postpone | nction           |
    |                  |                 | it until after   |                  |
    |                  |                 | creation of      |                  |
    |                  |                 | derivatives.     |                  |
    |                  |                 | Default: False   |                  |
    +------------------+-----------------+------------------+------------------+
    | print_canonical  | OT_BOOL         | When printing    | casadi::Function |
    |                  |                 | numerical        | Internal         |
    |                  |                 | matrices, use a  |                  |
    |                  |                 | format that is   |                  |
    |                  |                 | exact and        |                  |
    |                  |                 | reproducible in  |                  |
    |                  |                 | generated C      |                  |
    |                  |                 | code.            |                  |
    +------------------+-----------------+------------------+------------------+
    | print_in         | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_out        | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs          |                  |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_time       | OT_BOOL         | print            | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time. Implies    |                  |
    |                  |                 | record_time.     |                  |
    +------------------+-----------------+------------------+------------------+
    | record_time      | OT_BOOL         | record           | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time, for        |                  |
    |                  |                 | retrieval with   |                  |
    |                  |                 | stats().         |                  |
    +------------------+-----------------+------------------+------------------+
    | regularity_check | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when NaN or Inf  | ction            |
    |                  |                 | appears during   |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | reverse_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | reverse mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | sens_linsol      | OT_STRING       | Linear solver    | casadi::Nlpsol   |
    |                  |                 | used for         |                  |
    |                  |                 | parametric       |                  |
    |                  |                 | sensitivities    |                  |
    |                  |                 | (default 'qr').  |                  |
    +------------------+-----------------+------------------+------------------+
    | sens_linsol_opti | OT_DICT         | Linear solver    | casadi::Nlpsol   |
    | ons              |                 | options used for |                  |
    |                  |                 | parametric       |                  |
    |                  |                 | sensitivities.   |                  |
    +------------------+-----------------+------------------+------------------+
    | show_eval_warnin | OT_BOOL         | Show warnings    | casadi::OracleFu |
    | gs               |                 | generated from   | nction           |
    |                  |                 | function         |                  |
    |                  |                 | evaluations      |                  |
    |                  |                 | [true]           |                  |
    +------------------+-----------------+------------------+------------------+
    | specific_options | OT_DICT         | Options for      | casadi::OracleFu |
    |                  |                 | specific auto-   | nction           |
    |                  |                 | generated        |                  |
    |                  |                 | functions,       |                  |
    |                  |                 | overwriting the  |                  |
    |                  |                 | defaults from    |                  |
    |                  |                 | common_options.  |                  |
    |                  |                 | Nested           |                  |
    |                  |                 | dictionary.      |                  |
    +------------------+-----------------+------------------+------------------+
    | user_data        | OT_VOIDPTR      | A user-defined   | casadi::Function |
    |                  |                 | field that can   | Internal         |
    |                  |                 | be used to       |                  |
    |                  |                 | identify the     |                  |
    |                  |                 | function or pass |                  |
    |                  |                 | additional       |                  |
    |                  |                 | information      |                  |
    +------------------+-----------------+------------------+------------------+
    | verbose          | OT_BOOL         | Verbose          | casadi::ProtoFun |
    |                  |                 | evaluation  for  | ction            |
    |                  |                 | debugging        |                  |
    +------------------+-----------------+------------------+------------------+
    | verbose_init     | OT_BOOL         | Print out timing | casadi::Nlpsol   |
    |                  |                 | information      |                  |
    |                  |                 | about the        |                  |
    |                  |                 | different stages |                  |
    |                  |                 | of               |                  |
    |                  |                 | initialization   |                  |
    +------------------+-----------------+------------------+------------------+
    | warn_initial_bou | OT_BOOL         | Warn if the      | casadi::Nlpsol   |
    | nds              |                 | initial guess    |                  |
    |                  |                 | does not satisfy |                  |
    |                  |                 | LBX and UBX      |                  |
    +------------------+-----------------+------------------+------------------+

    >Input scheme: casadi::NlpsolInput (NLPSOL_NUM_IN = 8)

    +---------------+--------+-------------------------------------------------+
    |   Full name   | Short  |                   Description                   |
    +===============+========+=================================================+
    | NLPSOL_X0     | x0     | Decision variables, initial guess (nx x 1)      |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_P      | p      | Value of fixed parameters (np x 1)              |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LBX    | lbx    | Decision variables lower bound (nx x 1),        |
    |               |        | default -inf.                                   |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_UBX    | ubx    | Decision variables upper bound (nx x 1),        |
    |               |        | default +inf.                                   |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LBG    | lbg    | Constraints lower bound (ng x 1), default -inf. |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_UBG    | ubg    | Constraints upper bound (ng x 1), default +inf. |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LAM_X0 | lam_x0 | Lagrange multipliers for bounds on X, initial   |
    |               |        | guess (nx x 1)                                  |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LAM_G0 | lam_g0 | Lagrange multipliers for bounds on G, initial   |
    |               |        | guess (ng x 1)                                  |
    +---------------+--------+-------------------------------------------------+

    >Output scheme: casadi::NlpsolOutput (NLPSOL_NUM_OUT = 6)

    +--------------+-------+---------------------------------------------------+
    |  Full name   | Short |                    Description                    |
    +==============+=======+===================================================+
    | NLPSOL_X     | x     | Decision variables at the optimal solution (nx x  |
    |              |       | 1)                                                |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_F     | f     | Cost function value at the optimal solution (1 x  |
    |              |       | 1)                                                |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_G     | g     | Constraints function at the optimal solution (ng  |
    |              |       | x 1)                                              |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_LAM_X | lam_x | Lagrange multipliers for bounds on X at the       |
    |              |       | solution (nx x 1)                                 |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_LAM_G | lam_g | Lagrange multipliers for bounds on G at the       |
    |              |       | solution (ng x 1)                                 |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_LAM_P | lam_p | Lagrange multipliers for bounds on P at the       |
    |              |       | solution (np x 1)                                 |
    +--------------+-------+---------------------------------------------------+

    List of plugins
    - ampl

    - blocksqp

    - bonmin

    - fatrop

    - ipopt

    - knitro

    - madnlp

    - snopt

    - worhp

    - feasiblesqpmethod

    - qrsqp

    - scpgen

    - sqpmethod

    Note: some of the plugins in this list might not be available on your 

    system.  Also, there might be extra plugins available to you that are 
    not 
    listed here. You can obtain their documentation with  
    Nlpsol.doc("myextraplugin")



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

    ampl
    ----



    Interface to AMPL

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_22b

    >List of available options

    +--------+-----------+--------------------+
    |   Id   |   Type    |    Description     |
    +========+===========+====================+
    | solver | OT_STRING | AMPL solver binary |
    +--------+-----------+--------------------+



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

    blocksqp
    --------



    This is a modified version of blockSQP by Janka et al.

    Dennis Janka, Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_224

    >List of available options

    +----------------------------+-----------+---------------------------------+
    |             Id             |   Type    |           Description           |
    +============================+===========+=================================+
    | block_hess                 | OT_INT    | Blockwise Hessian               |
    |                            |           | approximation?                  |
    +----------------------------+-----------+---------------------------------+
    | col_eps                    | OT_DOUBLE | Epsilon for COL scaling         |
    |                            |           | strategy                        |
    +----------------------------+-----------+---------------------------------+
    | col_tau1                   | OT_DOUBLE | tau1 for COL scaling strategy   |
    +----------------------------+-----------+---------------------------------+
    | col_tau2                   | OT_DOUBLE | tau2 for COL scaling strategy   |
    +----------------------------+-----------+---------------------------------+
    | conv_strategy              | OT_INT    | Convexification strategy        |
    +----------------------------+-----------+---------------------------------+
    | delta                      | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | delta_h0                   | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | eps                        | OT_DOUBLE | Values smaller than this are    |
    |                            |           | regarded as numerically zero    |
    +----------------------------+-----------+---------------------------------+
    | eta                        | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | fallback_scaling           | OT_INT    | If indefinite update is used,   |
    |                            |           | the type of fallback strategy   |
    +----------------------------+-----------+---------------------------------+
    | fallback_update            | OT_INT    | If indefinite update is used,   |
    |                            |           | the type of fallback strategy   |
    +----------------------------+-----------+---------------------------------+
    | gamma_f                    | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | gamma_theta                | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | globalization              | OT_BOOL   | Enable globalization            |
    +----------------------------+-----------+---------------------------------+
    | hess_damp                  | OT_INT    | Activate Powell damping for     |
    |                            |           | BFGS                            |
    +----------------------------+-----------+---------------------------------+
    | hess_damp_fac              | OT_DOUBLE | Damping factor for BFGS Powell  |
    |                            |           | modification                    |
    +----------------------------+-----------+---------------------------------+
    | hess_lim_mem               | OT_INT    | Full or limited memory          |
    +----------------------------+-----------+---------------------------------+
    | hess_memsize               | OT_INT    | Memory size for L-BFGS updates  |
    +----------------------------+-----------+---------------------------------+
    | hess_scaling               | OT_INT    | Scaling strategy for Hessian    |
    |                            |           | approximation                   |
    +----------------------------+-----------+---------------------------------+
    | hess_update                | OT_INT    | Type of Hessian approximation   |
    +----------------------------+-----------+---------------------------------+
    | ini_hess_diag              | OT_DOUBLE | Initial Hessian guess: diagonal |
    |                            |           | matrix diag(iniHessDiag)        |
    +----------------------------+-----------+---------------------------------+
    | kappa_f                    | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | kappa_minus                | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | kappa_plus                 | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | kappa_plus_max             | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | kappa_soc                  | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | linsol                     | OT_STRING | The linear solver to be used by |
    |                            |           | the QP method                   |
    +----------------------------+-----------+---------------------------------+
    | max_consec_reduced_steps   | OT_INT    | Maximum number of consecutive   |
    |                            |           | reduced steps                   |
    +----------------------------+-----------+---------------------------------+
    | max_consec_skipped_updates | OT_INT    | Maximum number of consecutive   |
    |                            |           | skipped updates                 |
    +----------------------------+-----------+---------------------------------+
    | max_conv_qp                | OT_INT    | How many additional QPs may be  |
    |                            |           | solved for convexification per  |
    |                            |           | iteration?                      |
    +----------------------------+-----------+---------------------------------+
    | max_it_qp                  | OT_INT    | Maximum number of QP iterations |
    |                            |           | per SQP iteration               |
    +----------------------------+-----------+---------------------------------+
    | max_iter                   | OT_INT    | Maximum number of SQP           |
    |                            |           | iterations                      |
    +----------------------------+-----------+---------------------------------+
    | max_line_search            | OT_INT    | Maximum number of steps in line |
    |                            |           | search                          |
    +----------------------------+-----------+---------------------------------+
    | max_soc_iter               | OT_INT    | Maximum number of SOC line      |
    |                            |           | search iterations               |
    +----------------------------+-----------+---------------------------------+
    | max_time_qp                | OT_DOUBLE | Maximum number of time in       |
    |                            |           | seconds per QP solve per SQP    |
    |                            |           | iteration                       |
    +----------------------------+-----------+---------------------------------+
    | nlinfeastol                | OT_DOUBLE | Nonlinear feasibility tolerance |
    +----------------------------+-----------+---------------------------------+
    | obj_lo                     | OT_DOUBLE | Lower bound on objective        |
    |                            |           | function [-inf]                 |
    +----------------------------+-----------+---------------------------------+
    | obj_up                     | OT_DOUBLE | Upper bound on objective        |
    |                            |           | function [inf]                  |
    +----------------------------+-----------+---------------------------------+
    | opttol                     | OT_DOUBLE | Optimality tolerance            |
    +----------------------------+-----------+---------------------------------+
    | print_header               | OT_BOOL   | Print solver header at startup  |
    +----------------------------+-----------+---------------------------------+
    | print_iteration            | OT_BOOL   | Print SQP iterations            |
    +----------------------------+-----------+---------------------------------+
    | print_maxit_reached        | OT_BOOL   | Print error when maximum number |
    |                            |           | of SQP iterations reached       |
    +----------------------------+-----------+---------------------------------+
    | qp_init                    | OT_BOOL   | Use warmstarting                |
    +----------------------------+-----------+---------------------------------+
    | qpsol                      | OT_STRING | The QP solver to be used by the |
    |                            |           | SQP method                      |
    +----------------------------+-----------+---------------------------------+
    | qpsol_options              | OT_DICT   | Options to be passed to the QP  |
    |                            |           | solver                          |
    +----------------------------+-----------+---------------------------------+
    | restore_feas               | OT_BOOL   | Use feasibility restoration     |
    |                            |           | phase                           |
    +----------------------------+-----------+---------------------------------+
    | rho                        | OT_DOUBLE | Feasibility restoration phase   |
    |                            |           | parameter                       |
    +----------------------------+-----------+---------------------------------+
    | s_f                        | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | s_theta                    | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | schur                      | OT_BOOL   | Use qpOASES Schur compliment    |
    |                            |           | approach                        |
    +----------------------------+-----------+---------------------------------+
    | skip_first_globalization   | OT_BOOL   | No globalization strategy in    |
    |                            |           | first iteration                 |
    +----------------------------+-----------+---------------------------------+
    | theta_max                  | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | theta_min                  | OT_DOUBLE | Filter line search parameter,   |
    |                            |           | cf. IPOPT paper                 |
    +----------------------------+-----------+---------------------------------+
    | warmstart                  | OT_BOOL   | Use warmstarting                |
    +----------------------------+-----------+---------------------------------+
    | which_second_derv          | OT_INT    | For which block should second   |
    |                            |           | derivatives be provided by the  |
    |                            |           | user                            |
    +----------------------------+-----------+---------------------------------+
    | zeta                       | OT_DOUBLE | Feasibility restoration phase   |
    |                            |           | parameter                       |
    +----------------------------+-----------+---------------------------------+



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

    bonmin
    ------



    When in warmstart mode, output NLPSOL_LAM_X may be used as input

    NOTE: Even when max_iter == 0, it is not guaranteed that 
    input(NLPSOL_X0) 
    == output(NLPSOL_X). Indeed if bounds on X or 
    constraints are unmet, they 
    will differ.

    For a good tutorial on BONMIN, see 
    https://drops.dagstuhl.de/storage/16dagstuhl-seminar-proceedings/dsp-

    vol09061/DagSemProc.09061.16/DagSemProc.09061.16.pdf

    A good resource about the algorithms in BONMIN is: Wachter and L. T. 

    Biegler, On the Implementation of an Interior-Point Filter Line-Search

    Algorithm for Large-Scale Nonlinear Programming, Mathematical 
    Programming 
    106(1), pp. 25-57, 2006 (As Research Report RC 23149, IBM 
    T. J. Watson 
    Research Center, Yorktown, USA

    Caveats:
    with default options, multipliers for the decision variables are 
    wrong
     for equality constraints. Change the 'fixed_variable_treatment' to 

    'make_constraint' or 'relax_bounds' to obtain correct results.

    Extra doc: https://github.com/casadi/casadi/wiki/L_223

    >List of available options

    +-------------------------+-----------------------+------------------------+
    |           Id            |         Type          |      Description       |
    +=========================+=======================+========================+
    | bonmin                  | OT_DICT               | Options to be passed   |
    |                         |                       | to BONMIN              |
    +-------------------------+-----------------------+------------------------+
    | con_integer_md          | OT_DICT               | Integer metadata (a    |
    |                         |                       | dictionary with lists  |
    |                         |                       | of integers) about     |
    |                         |                       | constraints to be      |
    |                         |                       | passed to BONMIN       |
    +-------------------------+-----------------------+------------------------+
    | con_numeric_md          | OT_DICT               | Numeric metadata (a    |
    |                         |                       | dictionary with lists  |
    |                         |                       | of reals) about        |
    |                         |                       | constraints to be      |
    |                         |                       | passed to BONMIN       |
    +-------------------------+-----------------------+------------------------+
    | con_string_md           | OT_DICT               | String metadata (a     |
    |                         |                       | dictionary with lists  |
    |                         |                       | of strings) about      |
    |                         |                       | constraints to be      |
    |                         |                       | passed to BONMIN       |
    +-------------------------+-----------------------+------------------------+
    | grad_f                  | OT_FUNCTION           | Function for           |
    |                         |                       | calculating the        |
    |                         |                       | gradient of the        |
    |                         |                       | objective (column,     |
    |                         |                       | autogenerated by       |
    |                         |                       | default)               |
    +-------------------------+-----------------------+------------------------+
    | grad_f_options          | OT_DICT               | Options for the        |
    |                         |                       | autogenerated gradient |
    |                         |                       | of the objective.      |
    +-------------------------+-----------------------+------------------------+
    | hess_lag                | OT_FUNCTION           | Function for           |
    |                         |                       | calculating the        |
    |                         |                       | Hessian of the         |
    |                         |                       | Lagrangian             |
    |                         |                       | (autogenerated by      |
    |                         |                       | default)               |
    +-------------------------+-----------------------+------------------------+
    | hess_lag_options        | OT_DICT               | Options for the        |
    |                         |                       | autogenerated Hessian  |
    |                         |                       | of the Lagrangian.     |
    +-------------------------+-----------------------+------------------------+
    | jac_g                   | OT_FUNCTION           | Function for           |
    |                         |                       | calculating the        |
    |                         |                       | Jacobian of the        |
    |                         |                       | constraints            |
    |                         |                       | (autogenerated by      |
    |                         |                       | default)               |
    +-------------------------+-----------------------+------------------------+
    | jac_g_options           | OT_DICT               | Options for the        |
    |                         |                       | autogenerated Jacobian |
    |                         |                       | of the constraints.    |
    +-------------------------+-----------------------+------------------------+
    | pass_nonlinear_constrai | OT_BOOL               | Pass list of           |
    | nts                     |                       | constraints entering   |
    |                         |                       | nonlinearly to BONMIN  |
    +-------------------------+-----------------------+------------------------+
    | pass_nonlinear_variable | OT_BOOL               | Pass list of variables |
    | s                       |                       | entering nonlinearly   |
    |                         |                       | to BONMIN              |
    +-------------------------+-----------------------+------------------------+
    | sos1_groups             | OT_INTVECTORVECTOR    | Options for the        |
    |                         |                       | autogenerated gradient |
    |                         |                       | of the objective.      |
    +-------------------------+-----------------------+------------------------+
    | sos1_priorities         | OT_INTVECTOR          | Options for the        |
    |                         |                       | autogenerated gradient |
    |                         |                       | of the objective.      |
    +-------------------------+-----------------------+------------------------+
    | sos1_weights            | OT_DOUBLEVECTORVECTOR | Options for the        |
    |                         |                       | autogenerated gradient |
    |                         |                       | of the objective.      |
    +-------------------------+-----------------------+------------------------+
    | var_integer_md          | OT_DICT               | Integer metadata (a    |
    |                         |                       | dictionary with lists  |
    |                         |                       | of integers) about     |
    |                         |                       | variables to be passed |
    |                         |                       | to BONMIN              |
    +-------------------------+-----------------------+------------------------+
    | var_numeric_md          | OT_DICT               | Numeric metadata (a    |
    |                         |                       | dictionary with lists  |
    |                         |                       | of reals) about        |
    |                         |                       | variables to be passed |
    |                         |                       | to BONMIN              |
    +-------------------------+-----------------------+------------------------+
    | var_string_md           | OT_DICT               | String metadata (a     |
    |                         |                       | dictionary with lists  |
    |                         |                       | of strings) about      |
    |                         |                       | variables to be passed |
    |                         |                       | to BONMIN              |
    +-------------------------+-----------------------+------------------------+



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

    fatrop
    ------



    >List of available options

    +---------------------+--------------+-------------------------------------+
    |         Id          |     Type     |             Description             |
    +=====================+==============+=====================================+
    | N                   | OT_INT       | OCP horizon                         |
    +---------------------+--------------+-------------------------------------+
    | convexify_margin    | OT_DOUBLE    | When using a convexification        |
    |                     |              | strategy, make sure that the        |
    |                     |              | smallest eigenvalue is at least     |
    |                     |              | this (default: 1e-7).               |
    +---------------------+--------------+-------------------------------------+
    | convexify_strategy  | OT_STRING    | NONE|regularize|eigen-              |
    |                     |              | reflect|eigen-clip. Strategy to     |
    |                     |              | convexify the Lagrange Hessian      |
    |                     |              | before passing it to the solver.    |
    +---------------------+--------------+-------------------------------------+
    | debug               | OT_BOOL      | Produce debug information (default: |
    |                     |              | false)                              |
    +---------------------+--------------+-------------------------------------+
    | fatrop              | OT_DICT      | Options to be passed to fatrop      |
    +---------------------+--------------+-------------------------------------+
    | ng                  | OT_INTVECTOR | Number of non-dynamic constraints,  |
    |                     |              | length N+1                          |
    +---------------------+--------------+-------------------------------------+
    | nu                  | OT_INTVECTOR | Number of controls, length N+1      |
    +---------------------+--------------+-------------------------------------+
    | nx                  | OT_INTVECTOR | Number of states, length N+1        |
    +---------------------+--------------+-------------------------------------+
    | structure_detection | OT_STRING    | NONE | auto | manual                |
    +---------------------+--------------+-------------------------------------+

    Fatrop is a solver developed at KU Leuven by Lander Vanroye and Wilm 
    Decre.
     The algorithm is based on IPOPT, but the linear algebra is much
     more 
    efficient.

    With structure_detection = 'none' (default), it will behave as a 
    general-
    purpose dense nonlinear program solver.

    With structure_detection = 'manual', you can specify a block 
    structure.

    Let's say you perform multiply shooting with a system

    x_k+1 = A_k x_k + B_k u_k

    Suppose your constraint Jacobian looks like:

    ::

       nx0  nu0  nx1  nu1  nx2  nu2
       -----------------------------


    nx1 |A0 B0 I0 
     ng1 |C0 D0 
     nx2 | A1 B1 I1 
     ng2 | C1 D1 
     ng3 | C2 D2

    with n* capturing the number of states, inputs, and constraints in 
    each 
    block.

    You can then specify this structure with:

    N = 2 nx = [nx0 ,nx1, nx2] nu = [nu0, nu1, nu2] ng = [ng1, ng2, ng3]

    With structure_detection = 'auto', the block-defining parameters nx, 
    nu, 
    ng, and N are automatically detected from the sparsity pattern.



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

    ipopt
    -----



    When in warmstart mode, output NLPSOL_LAM_X may be used as input

    NOTE: Even when max_iter == 0, it is not guaranteed that 
    input(NLPSOL_X0) 
    == output(NLPSOL_X). Indeed if bounds on X or 
    constraints are unmet, they 
    will differ.

    For a good tutorial on IPOPT, see 
    https://drops.dagstuhl.de/storage/16dagstuhl-seminar-proceedings/dsp-

    vol09061/DagSemProc.09061.16/DagSemProc.09061.16.pdf

    A good resource about the algorithms in IPOPT is: Wachter and L. T. 

    Biegler, On the Implementation of an Interior-Point Filter Line-Search

    Algorithm for Large-Scale Nonlinear Programming, Mathematical 
    Programming 
    106(1), pp. 25-57, 2006 (As Research Report RC 23149, IBM 
    T. J. Watson 
    Research Center, Yorktown, USA

    Caveats:
    with default options, multipliers for the decision variables are 
    wrong
     for equality constraints. Change the 'fixed_variable_treatment' to 

    'make_constraint' or 'relax_bounds' to obtain correct results.

    Extra doc: https://github.com/casadi/casadi/wiki/L_21y

    >List of available options

    +--------------------------+-------------+---------------------------------+
    |            Id            |    Type     |           Description           |
    +==========================+=============+=================================+
    | clip_inactive_lam        | OT_BOOL     | Explicitly set Lagrange         |
    |                          |             | multipliers to 0 when bound is  |
    |                          |             | deemed inactive (default:       |
    |                          |             | false).                         |
    +--------------------------+-------------+---------------------------------+
    | con_integer_md           | OT_DICT     | Integer metadata (a dictionary  |
    |                          |             | with lists of integers) about   |
    |                          |             | constraints to be passed to     |
    |                          |             | IPOPT                           |
    +--------------------------+-------------+---------------------------------+
    | con_numeric_md           | OT_DICT     | Numeric metadata (a dictionary  |
    |                          |             | with lists of reals) about      |
    |                          |             | constraints to be passed to     |
    |                          |             | IPOPT                           |
    +--------------------------+-------------+---------------------------------+
    | con_string_md            | OT_DICT     | String metadata (a dictionary   |
    |                          |             | with lists of strings) about    |
    |                          |             | constraints to be passed to     |
    |                          |             | IPOPT                           |
    +--------------------------+-------------+---------------------------------+
    | convexify_margin         | OT_DOUBLE   | When using a convexification    |
    |                          |             | strategy, make sure that the    |
    |                          |             | smallest eigenvalue is at least |
    |                          |             | this (default: 1e-7).           |
    +--------------------------+-------------+---------------------------------+
    | convexify_strategy       | OT_STRING   | NONE|regularize|eigen-          |
    |                          |             | reflect|eigen-clip. Strategy to |
    |                          |             | convexify the Lagrange Hessian  |
    |                          |             | before passing it to the        |
    |                          |             | solver.                         |
    +--------------------------+-------------+---------------------------------+
    | grad_f                   | OT_FUNCTION | Function for calculating the    |
    |                          |             | gradient of the objective       |
    |                          |             | (column, autogenerated by       |
    |                          |             | default)                        |
    +--------------------------+-------------+---------------------------------+
    | hess_lag                 | OT_FUNCTION | Function for calculating the    |
    |                          |             | Hessian of the Lagrangian       |
    |                          |             | (autogenerated by default)      |
    +--------------------------+-------------+---------------------------------+
    | inactive_lam_strategy    | OT_STRING   | Strategy to detect if a bound   |
    |                          |             | is inactive. RELTOL: use        |
    |                          |             | solver-defined constraint       |
    |                          |             | tolerance *                     |
    |                          |             | inactive_lam_value|abstol: use  |
    |                          |             | inactive_lam_value              |
    +--------------------------+-------------+---------------------------------+
    | inactive_lam_value       | OT_DOUBLE   | Value used in                   |
    |                          |             | inactive_lam_strategy (default: |
    |                          |             | 10).                            |
    +--------------------------+-------------+---------------------------------+
    | ipopt                    | OT_DICT     | Options to be passed to IPOPT   |
    +--------------------------+-------------+---------------------------------+
    | jac_g                    | OT_FUNCTION | Function for calculating the    |
    |                          |             | Jacobian of the constraints     |
    |                          |             | (autogenerated by default)      |
    +--------------------------+-------------+---------------------------------+
    | max_iter_eig             | OT_DOUBLE   | Maximum number of iterations to |
    |                          |             | compute an eigenvalue           |
    |                          |             | decomposition (default: 50).    |
    +--------------------------+-------------+---------------------------------+
    | pass_nonlinear_variables | OT_BOOL     | Pass list of variables entering |
    |                          |             | nonlinearly to IPOPT            |
    +--------------------------+-------------+---------------------------------+
    | var_integer_md           | OT_DICT     | Integer metadata (a dictionary  |
    |                          |             | with lists of integers) about   |
    |                          |             | variables to be passed to IPOPT |
    +--------------------------+-------------+---------------------------------+
    | var_numeric_md           | OT_DICT     | Numeric metadata (a dictionary  |
    |                          |             | with lists of reals) about      |
    |                          |             | variables to be passed to IPOPT |
    +--------------------------+-------------+---------------------------------+
    | var_string_md            | OT_DICT     | String metadata (a dictionary   |
    |                          |             | with lists of strings) about    |
    |                          |             | variables to be passed to IPOPT |
    +--------------------------+-------------+---------------------------------+



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

    knitro
    ------



    KNITRO interface

    Extra doc: https://github.com/casadi/casadi/wiki/L_22c

    >List of available options

    +--------------------------+--------------------+--------------------------+
    |            Id            |        Type        |       Description        |
    +==========================+====================+==========================+
    | complem_variables        | OT_INTVECTORVECTOR | List of complementary    |
    |                          |                    | constraints on simple    |
    |                          |                    | bounds. Pair (i, j)      |
    |                          |                    | encodes complementarity  |
    |                          |                    | between the bounds on    |
    |                          |                    | variable i and variable  |
    |                          |                    | j.                       |
    +--------------------------+--------------------+--------------------------+
    | contype                  | OT_INTVECTOR       | Type of constraint       |
    +--------------------------+--------------------+--------------------------+
    | detect_linear_constraint | OT_BOOL            | Detect type of           |
    | s                        |                    | constraints              |
    +--------------------------+--------------------+--------------------------+
    | knitro                   | OT_DICT            | Options to be passed to  |
    |                          |                    | KNITRO                   |
    +--------------------------+--------------------+--------------------------+
    | options_file             | OT_STRING          | Read options from file   |
    |                          |                    | (solver specific)        |
    +--------------------------+--------------------+--------------------------+



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

    madnlp
    ------



    >List of available options

    +--------------------+--------------+--------------------------------------+
    |         Id         |     Type     |             Description              |
    +====================+==============+======================================+
    | convexify_margin   | OT_DOUBLE    | When using a convexification         |
    |                    |              | strategy, make sure that the         |
    |                    |              | smallest eigenvalue is at least this |
    |                    |              | (default: 1e-7).                     |
    +--------------------+--------------+--------------------------------------+
    | convexify_strategy | OT_STRING    | NONE|regularize|eigen-reflect|eigen- |
    |                    |              | clip. Strategy to convexify the      |
    |                    |              | Lagrange Hessian before passing it   |
    |                    |              | to the solver.                       |
    +--------------------+--------------+--------------------------------------+
    | madnlp             | OT_DICT      | Options to be passed to madnlp       |
    +--------------------+--------------+--------------------------------------+
    | ng                 | OT_INTVECTOR | Number of constraints                |
    +--------------------+--------------+--------------------------------------+
    | nw                 | OT_INTVECTOR | Number of variables                  |
    +--------------------+--------------+--------------------------------------+



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

    snopt
    -----



    SNOPT interface

    Extra doc: https://github.com/casadi/casadi/wiki/L_22m

    >List of available options

    +-------+-----------+---------------------------------------------+
    |  Id   |   Type    |                 Description                 |
    +=======+===========+=============================================+
    | snopt | OT_DICT   | Options to be passed to SNOPT               |
    +-------+-----------+---------------------------------------------+
    | start | OT_STRING | Warm-start options for Worhp: cold|warm|hot |
    +-------+-----------+---------------------------------------------+



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

    worhp
    -----



    WORHP interface

    Designed for Worhp 1.12

    >List of available options

    +-------+---------+-------------------------------+
    |  Id   |  Type   |          Description          |
    +=======+=========+===============================+
    | worhp | OT_DICT | Options to be passed to WORHP |
    +-------+---------+-------------------------------+



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

    feasiblesqpmethod
    -----------------



    A textbook FeasibleSQPMethod

    Extra doc: https://github.com/casadi/casadi/wiki/L_241

    >List of available options

    +----------------------------+-----------------+---------------------------+
    |             Id             |      Type       |        Description        |
    +============================+=================+===========================+
    | anderson_memory            | OT_INT          | Anderson memory. If       |
    |                            |                 | Anderson is used default  |
    |                            |                 | is 1, else default is 0.  |
    +----------------------------+-----------------+---------------------------+
    | contraction_acceptance_val | OT_DOUBLE       | If the empirical          |
    | ue                         |                 | contraction rate in the   |
    |                            |                 | feasibility iterations is |
    |                            |                 | above this value in the   |
    |                            |                 | heuristics the iterations |
    |                            |                 | are aborted.              |
    +----------------------------+-----------------+---------------------------+
    | convexify_margin           | OT_DOUBLE       | When using a              |
    |                            |                 | convexification strategy, |
    |                            |                 | make sure that the        |
    |                            |                 | smallest eigenvalue4 is   |
    |                            |                 | at least this (default:   |
    |                            |                 | 1e-7).                    |
    +----------------------------+-----------------+---------------------------+
    | convexify_strategy         | OT_STRING       | NONE|regularize|eigen-    |
    |                            |                 | reflect|eigen-clip.       |
    |                            |                 | Strategy to convexify the |
    |                            |                 | Lagrange Hessian before   |
    |                            |                 | passing it to the solver. |
    +----------------------------+-----------------+---------------------------+
    | f                          | OT_FUNCTION     | Function for calculating  |
    |                            |                 | the objective function    |
    |                            |                 | (autogenerated by         |
    |                            |                 | default)                  |
    +----------------------------+-----------------+---------------------------+
    | feas_tol                   | OT_DOUBLE       | Feasibility tolerance.    |
    |                            |                 | Below this tolerance an   |
    |                            |                 | iterate is considered to  |
    |                            |                 | be feasible.              |
    +----------------------------+-----------------+---------------------------+
    | g                          | OT_FUNCTION     | Function for calculating  |
    |                            |                 | the constraints           |
    |                            |                 | (autogenerated by         |
    |                            |                 | default)                  |
    +----------------------------+-----------------+---------------------------+
    | grad_f                     | OT_FUNCTION     | Function for calculating  |
    |                            |                 | the gradient of the       |
    |                            |                 | objective (autogenerated  |
    |                            |                 | by default)               |
    +----------------------------+-----------------+---------------------------+
    | hess_lag                   | OT_FUNCTION     | Function for calculating  |
    |                            |                 | the Hessian of the        |
    |                            |                 | Lagrangian (autogenerated |
    |                            |                 | by default)               |
    +----------------------------+-----------------+---------------------------+
    | hessian_approximation      | OT_STRING       | limited-memory|exact      |
    +----------------------------+-----------------+---------------------------+
    | init_feasible              | OT_BOOL         | Initialize the QP         |
    |                            |                 | subproblems with a        |
    |                            |                 | feasible initial value    |
    |                            |                 | (default: false).         |
    +----------------------------+-----------------+---------------------------+
    | jac_g                      | OT_FUNCTION     | Function for calculating  |
    |                            |                 | the Jacobian of the       |
    |                            |                 | constraints               |
    |                            |                 | (autogenerated by         |
    |                            |                 | default)                  |
    +----------------------------+-----------------+---------------------------+
    | lbfgs_memory               | OT_INT          | Size of L-BFGS memory.    |
    +----------------------------+-----------------+---------------------------+
    | max_inner_iter             | OT_DOUBLE       | Maximum number of inner   |
    |                            |                 | iterations.               |
    +----------------------------+-----------------+---------------------------+
    | max_iter                   | OT_INT          | Maximum number of SQP     |
    |                            |                 | iterations                |
    +----------------------------+-----------------+---------------------------+
    | max_iter_eig               | OT_DOUBLE       | Maximum number of         |
    |                            |                 | iterations to compute an  |
    |                            |                 | eigenvalue decomposition  |
    |                            |                 | (default: 50).            |
    +----------------------------+-----------------+---------------------------+
    | merit_memory               | OT_INT          | Size of memory to store   |
    |                            |                 | history of merit function |
    |                            |                 | values                    |
    +----------------------------+-----------------+---------------------------+
    | min_iter                   | OT_INT          | Minimum number of SQP     |
    |                            |                 | iterations                |
    +----------------------------+-----------------+---------------------------+
    | optim_tol                  | OT_DOUBLE       | Optimality tolerance.     |
    |                            |                 | Below this value an       |
    |                            |                 | iterate is considered to  |
    |                            |                 | be optimal.               |
    +----------------------------+-----------------+---------------------------+
    | print_header               | OT_BOOL         | Print the header with     |
    |                            |                 | problem statistics        |
    +----------------------------+-----------------+---------------------------+
    | print_iteration            | OT_BOOL         | Print the iterations      |
    +----------------------------+-----------------+---------------------------+
    | print_status               | OT_BOOL         | Print a status message    |
    |                            |                 | after solving             |
    +----------------------------+-----------------+---------------------------+
    | qpsol                      | OT_STRING       | The QP solver to be used  |
    |                            |                 | by the SQP method         |
    |                            |                 | [qpoases]                 |
    +----------------------------+-----------------+---------------------------+
    | qpsol_options              | OT_DICT         | Options to be passed to   |
    |                            |                 | the QP solver             |
    +----------------------------+-----------------+---------------------------+
    | solve_type                 | OT_STRING       | The solver type: Either   |
    |                            |                 | SQP or SLP. Defaults to   |
    |                            |                 | SQP                       |
    +----------------------------+-----------------+---------------------------+
    | tol_du                     | OT_DOUBLE       | Stopping criterion for    |
    |                            |                 | dual infeasability        |
    +----------------------------+-----------------+---------------------------+
    | tol_pr                     | OT_DOUBLE       | Stopping criterion for    |
    |                            |                 | primal infeasibility      |
    +----------------------------+-----------------+---------------------------+
    | tr_acceptance              | OT_DOUBLE       | Is the trust-region ratio |
    |                            |                 | above this value, the     |
    |                            |                 | step is accepted.         |
    +----------------------------+-----------------+---------------------------+
    | tr_alpha1                  | OT_DOUBLE       | Lower alpha in trust-     |
    |                            |                 | region size criterion.    |
    +----------------------------+-----------------+---------------------------+
    | tr_alpha2                  | OT_DOUBLE       | Upper alpha in trust-     |
    |                            |                 | region size criterion.    |
    +----------------------------+-----------------+---------------------------+
    | tr_eta1                    | OT_DOUBLE       | Lower eta in trust-region |
    |                            |                 | acceptance criterion.     |
    +----------------------------+-----------------+---------------------------+
    | tr_eta2                    | OT_DOUBLE       | Upper eta in trust-region |
    |                            |                 | acceptance criterion.     |
    +----------------------------+-----------------+---------------------------+
    | tr_rad0                    | OT_DOUBLE       | Initial trust-region      |
    |                            |                 | radius.                   |
    +----------------------------+-----------------+---------------------------+
    | tr_rad_max                 | OT_DOUBLE       | Maximum trust-region      |
    |                            |                 | radius.                   |
    +----------------------------+-----------------+---------------------------+
    | tr_rad_min                 | OT_DOUBLE       | Minimum trust-region      |
    |                            |                 | radius.                   |
    +----------------------------+-----------------+---------------------------+
    | tr_scale_vector            | OT_DOUBLEVECTOR | Vector that tells where   |
    |                            |                 | trust-region is applied.  |
    +----------------------------+-----------------+---------------------------+
    | tr_tol                     | OT_DOUBLE       | Trust-region tolerance.   |
    |                            |                 | Below this value another  |
    |                            |                 | scalar is equal to the    |
    |                            |                 | trust region radius.      |
    +----------------------------+-----------------+---------------------------+
    | use_anderson               | OT_BOOL         | Use Anderson              |
    |                            |                 | Acceleration. (default    |
    |                            |                 | false)                    |
    +----------------------------+-----------------+---------------------------+
    | watchdog                   | OT_INT          | Number of watchdog        |
    |                            |                 | iterations in feasibility |
    |                            |                 | iterations. After this    |
    |                            |                 | amount of iterations, it  |
    |                            |                 | is checked with the       |
    |                            |                 | contraction acceptance    |
    |                            |                 | value, if iterations are  |
    |                            |                 | converging.               |
    +----------------------------+-----------------+---------------------------+



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

    qrsqp
    -----



    A textbook SQPMethod

    Extra doc: https://github.com/casadi/casadi/wiki/L_22u

    >List of available options

    +-----------------------+-----------+--------------------------------------+
    |          Id           |   Type    |             Description              |
    +=======================+===========+======================================+
    | beta                  | OT_DOUBLE | Line-search parameter, restoration   |
    |                       |           | factor of stepsize                   |
    +-----------------------+-----------+--------------------------------------+
    | c1                    | OT_DOUBLE | Armijo condition, coefficient of     |
    |                       |           | decrease in merit                    |
    +-----------------------+-----------+--------------------------------------+
    | hessian_approximation | OT_STRING | limited-memory|exact                 |
    +-----------------------+-----------+--------------------------------------+
    | lbfgs_memory          | OT_INT    | Size of L-BFGS memory.               |
    +-----------------------+-----------+--------------------------------------+
    | max_iter              | OT_INT    | Maximum number of SQP iterations     |
    +-----------------------+-----------+--------------------------------------+
    | max_iter_ls           | OT_INT    | Maximum number of linesearch         |
    |                       |           | iterations                           |
    +-----------------------+-----------+--------------------------------------+
    | merit_memory          | OT_INT    | Size of memory to store history of   |
    |                       |           | merit function values                |
    +-----------------------+-----------+--------------------------------------+
    | min_iter              | OT_INT    | Minimum number of SQP iterations     |
    +-----------------------+-----------+--------------------------------------+
    | min_step_size         | OT_DOUBLE | The size (inf-norm) of the step size |
    |                       |           | should not become smaller than this. |
    +-----------------------+-----------+--------------------------------------+
    | print_header          | OT_BOOL   | Print the header with problem        |
    |                       |           | statistics                           |
    +-----------------------+-----------+--------------------------------------+
    | print_iteration       | OT_BOOL   | Print the iterations                 |
    +-----------------------+-----------+--------------------------------------+
    | qpsol                 | OT_STRING | The QP solver to be used by the SQP  |
    |                       |           | method [qrqp]                        |
    +-----------------------+-----------+--------------------------------------+
    | qpsol_options         | OT_DICT   | Options to be passed to the QP       |
    |                       |           | solver                               |
    +-----------------------+-----------+--------------------------------------+
    | regularize            | OT_BOOL   | Automatic regularization of Lagrange |
    |                       |           | Hessian.                             |
    +-----------------------+-----------+--------------------------------------+
    | tol_du                | OT_DOUBLE | Stopping criterion for dual          |
    |                       |           | infeasability                        |
    +-----------------------+-----------+--------------------------------------+
    | tol_pr                | OT_DOUBLE | Stopping criterion for primal        |
    |                       |           | infeasibility                        |
    +-----------------------+-----------+--------------------------------------+



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

    scpgen
    ------



    A structure-exploiting sequential quadratic programming (to be come 

    sequential convex programming) method for nonlinear programming.

    Extra doc: https://github.com/casadi/casadi/wiki/L_232

    >List of available options

    +-----------------------+-----------------+--------------------------------+
    |          Id           |      Type       |          Description           |
    +=======================+=================+================================+
    | beta                  | OT_DOUBLE       | Line-search parameter,         |
    |                       |                 | restoration factor of stepsize |
    +-----------------------+-----------------+--------------------------------+
    | c1                    | OT_DOUBLE       | Armijo condition, coefficient  |
    |                       |                 | of decrease in merit           |
    +-----------------------+-----------------+--------------------------------+
    | codegen               | OT_BOOL         | C-code generation              |
    +-----------------------+-----------------+--------------------------------+
    | hessian_approximation | OT_STRING       | gauss-newton|exact             |
    +-----------------------+-----------------+--------------------------------+
    | lbfgs_memory          | OT_INT          | Size of L-BFGS memory.         |
    +-----------------------+-----------------+--------------------------------+
    | max_iter              | OT_INT          | Maximum number of SQP          |
    |                       |                 | iterations                     |
    +-----------------------+-----------------+--------------------------------+
    | max_iter_ls           | OT_INT          | Maximum number of linesearch   |
    |                       |                 | iterations                     |
    +-----------------------+-----------------+--------------------------------+
    | merit_memsize         | OT_INT          | Size of memory to store        |
    |                       |                 | history of merit function      |
    |                       |                 | values                         |
    +-----------------------+-----------------+--------------------------------+
    | merit_start           | OT_DOUBLE       | Lower bound for the merit      |
    |                       |                 | function parameter             |
    +-----------------------+-----------------+--------------------------------+
    | name_x                | OT_STRINGVECTOR | Names of the variables.        |
    +-----------------------+-----------------+--------------------------------+
    | print_header          | OT_BOOL         | Print the header with problem  |
    |                       |                 | statistics                     |
    +-----------------------+-----------------+--------------------------------+
    | print_x               | OT_INTVECTOR    | Which variables to print.      |
    +-----------------------+-----------------+--------------------------------+
    | qpsol                 | OT_STRING       | The QP solver to be used by    |
    |                       |                 | the SQP method                 |
    +-----------------------+-----------------+--------------------------------+
    | qpsol_options         | OT_DICT         | Options to be passed to the QP |
    |                       |                 | solver                         |
    +-----------------------+-----------------+--------------------------------+
    | reg_threshold         | OT_DOUBLE       | Threshold for the              |
    |                       |                 | regularization.                |
    +-----------------------+-----------------+--------------------------------+
    | regularize            | OT_BOOL         | Automatic regularization of    |
    |                       |                 | Lagrange Hessian.              |
    +-----------------------+-----------------+--------------------------------+
    | tol_du                | OT_DOUBLE       | Stopping criterion for dual    |
    |                       |                 | infeasability                  |
    +-----------------------+-----------------+--------------------------------+
    | tol_pr                | OT_DOUBLE       | Stopping criterion for primal  |
    |                       |                 | infeasibility                  |
    +-----------------------+-----------------+--------------------------------+
    | tol_pr_step           | OT_DOUBLE       | Stopping criterion for the     |
    |                       |                 | step size                      |
    +-----------------------+-----------------+--------------------------------+
    | tol_reg               | OT_DOUBLE       | Stopping criterion for         |
    |                       |                 | regularization                 |
    +-----------------------+-----------------+--------------------------------+



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

    sqpmethod
    ---------



    A textbook SQPMethod

    Extra doc: https://github.com/casadi/casadi/wiki/L_22x

    >List of available options

    +--------------------------+-------------+---------------------------------+
    |            Id            |    Type     |           Description           |
    +==========================+=============+=================================+
    | beta                     | OT_DOUBLE   | Line-search parameter,          |
    |                          |             | restoration factor of stepsize  |
    +--------------------------+-------------+---------------------------------+
    | c1                       | OT_DOUBLE   | Armijo condition, coefficient   |
    |                          |             | of decrease in merit            |
    +--------------------------+-------------+---------------------------------+
    | convexify_margin         | OT_DOUBLE   | When using a convexification    |
    |                          |             | strategy, make sure that the    |
    |                          |             | smallest eigenvalue is at least |
    |                          |             | this (default: 1e-7).           |
    +--------------------------+-------------+---------------------------------+
    | convexify_strategy       | OT_STRING   | NONE|regularize|eigen-          |
    |                          |             | reflect|eigen-clip. Strategy to |
    |                          |             | convexify the Lagrange Hessian  |
    |                          |             | before passing it to the        |
    |                          |             | solver.                         |
    +--------------------------+-------------+---------------------------------+
    | elastic_mode             | OT_BOOL     | Enable the elastic mode which   |
    |                          |             | is used when the QP is          |
    |                          |             | infeasible (default: false).    |
    +--------------------------+-------------+---------------------------------+
    | gamma_0                  | OT_DOUBLE   | Starting value for the penalty  |
    |                          |             | parameter of elastic mode       |
    |                          |             | (default: 1).                   |
    +--------------------------+-------------+---------------------------------+
    | gamma_1_min              | OT_DOUBLE   | Minimum value for gamma_1       |
    |                          |             | (default: 1e-5).                |
    +--------------------------+-------------+---------------------------------+
    | gamma_max                | OT_DOUBLE   | Maximum value for the penalty   |
    |                          |             | parameter of elastic mode       |
    |                          |             | (default: 1e20).                |
    +--------------------------+-------------+---------------------------------+
    | hess_lag                 | OT_FUNCTION | Function for calculating the    |
    |                          |             | Hessian of the Lagrangian       |
    |                          |             | (autogenerated by default)      |
    +--------------------------+-------------+---------------------------------+
    | hessian_approximation    | OT_STRING   | limited-memory|exact            |
    +--------------------------+-------------+---------------------------------+
    | init_feasible            | OT_BOOL     | Initialize the QP subproblems   |
    |                          |             | with a feasible initial value   |
    |                          |             | (default: false).               |
    +--------------------------+-------------+---------------------------------+
    | jac_fg                   | OT_FUNCTION | Function for calculating the    |
    |                          |             | gradient of the objective and   |
    |                          |             | Jacobian of the constraints     |
    |                          |             | (autogenerated by default)      |
    +--------------------------+-------------+---------------------------------+
    | lbfgs_memory             | OT_INT      | Size of L-BFGS memory.          |
    +--------------------------+-------------+---------------------------------+
    | max_iter                 | OT_INT      | Maximum number of SQP           |
    |                          |             | iterations                      |
    +--------------------------+-------------+---------------------------------+
    | max_iter_eig             | OT_DOUBLE   | Maximum number of iterations to |
    |                          |             | compute an eigenvalue           |
    |                          |             | decomposition (default: 50).    |
    +--------------------------+-------------+---------------------------------+
    | max_iter_ls              | OT_INT      | Maximum number of linesearch    |
    |                          |             | iterations                      |
    +--------------------------+-------------+---------------------------------+
    | merit_memory             | OT_INT      | Size of memory to store history |
    |                          |             | of merit function values        |
    +--------------------------+-------------+---------------------------------+
    | min_iter                 | OT_INT      | Minimum number of SQP           |
    |                          |             | iterations                      |
    +--------------------------+-------------+---------------------------------+
    | min_step_size            | OT_DOUBLE   | The size (inf-norm) of the step |
    |                          |             | size should not become smaller  |
    |                          |             | than this.                      |
    +--------------------------+-------------+---------------------------------+
    | print_header             | OT_BOOL     | Print the header with problem   |
    |                          |             | statistics                      |
    +--------------------------+-------------+---------------------------------+
    | print_iteration          | OT_BOOL     | Print the iterations            |
    +--------------------------+-------------+---------------------------------+
    | print_status             | OT_BOOL     | Print a status message after    |
    |                          |             | solving                         |
    +--------------------------+-------------+---------------------------------+
    | qpsol                    | OT_STRING   | The QP solver to be used by the |
    |                          |             | SQP method [qpoases]            |
    +--------------------------+-------------+---------------------------------+
    | qpsol_options            | OT_DICT     | Options to be passed to the QP  |
    |                          |             | solver                          |
    +--------------------------+-------------+---------------------------------+
    | second_order_corrections | OT_BOOL     | Enable second order             |
    |                          |             | corrections. These are used     |
    |                          |             | when a step is considered bad   |
    |                          |             | by the merit function and       |
    |                          |             | constraint norm (default:       |
    |                          |             | false).                         |
    +--------------------------+-------------+---------------------------------+
    | tol_du                   | OT_DOUBLE   | Stopping criterion for dual     |
    |                          |             | infeasability                   |
    +--------------------------+-------------+---------------------------------+
    | tol_pr                   | OT_DOUBLE   | Stopping criterion for primal   |
    |                          |             | infeasibility                   |
    +--------------------------+-------------+---------------------------------+

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_21q

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L118

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L118-L121



    .............


    .......

    ::

      nlpsol(str name, str solver, Importer compiler, dict opts)
      nlpsol(str name, str solver, NlpBuilder nl, dict opts)
      nlpsol(str name, str solver, dict:MX nlp, dict opts)
      nlpsol(str name, str solver, str fname, dict opts)
      nlpsol(str name, str solver, Function nlp, dict opts)



    [INTERNAL] 

    .............



    """
    return _casadi.nlpsol(*args)

def nlpsol_in(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      nlpsol_in() -> [str]
      nlpsol_in(int ind) -> str

    Get NLP solver input scheme name by index.

    >Input scheme: casadi::NlpsolInput (NLPSOL_NUM_IN = 8)

    +---------------+--------+-------------------------------------------------+
    |   Full name   | Short  |                   Description                   |
    +===============+========+=================================================+
    | NLPSOL_X0     | x0     | Decision variables, initial guess (nx x 1)      |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_P      | p      | Value of fixed parameters (np x 1)              |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LBX    | lbx    | Decision variables lower bound (nx x 1),        |
    |               |        | default -inf.                                   |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_UBX    | ubx    | Decision variables upper bound (nx x 1),        |
    |               |        | default +inf.                                   |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LBG    | lbg    | Constraints lower bound (ng x 1), default -inf. |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_UBG    | ubg    | Constraints upper bound (ng x 1), default +inf. |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LAM_X0 | lam_x0 | Lagrange multipliers for bounds on X, initial   |
    |               |        | guess (nx x 1)                                  |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LAM_G0 | lam_g0 | Lagrange multipliers for bounds on G, initial   |
    |               |        | guess (ng x 1)                                  |
    +---------------+--------+-------------------------------------------------+

    Extra doc: https://github.com/casadi/casadi/wiki/L_1t0

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L231

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L231-L244



    .......

    ::

      nlpsol_in()



    [INTERNAL] 
    Get input scheme of NLP solvers.

    >Input scheme: casadi::NlpsolInput (NLPSOL_NUM_IN = 8)

    +---------------+--------+-------------------------------------------------+
    |   Full name   | Short  |                   Description                   |
    +===============+========+=================================================+
    | NLPSOL_X0     | x0     | Decision variables, initial guess (nx x 1)      |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_P      | p      | Value of fixed parameters (np x 1)              |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LBX    | lbx    | Decision variables lower bound (nx x 1),        |
    |               |        | default -inf.                                   |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_UBX    | ubx    | Decision variables upper bound (nx x 1),        |
    |               |        | default +inf.                                   |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LBG    | lbg    | Constraints lower bound (ng x 1), default -inf. |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_UBG    | ubg    | Constraints upper bound (ng x 1), default +inf. |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LAM_X0 | lam_x0 | Lagrange multipliers for bounds on X, initial   |
    |               |        | guess (nx x 1)                                  |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LAM_G0 | lam_g0 | Lagrange multipliers for bounds on G, initial   |
    |               |        | guess (ng x 1)                                  |
    +---------------+--------+-------------------------------------------------+

    Extra doc: https://github.com/casadi/casadi/wiki/L_1sy

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L200

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L200-L204



    .............


    .......

    ::

      nlpsol_in(int ind)



    [INTERNAL] 
    Get NLP solver input scheme name by index.

    >Input scheme: casadi::NlpsolInput (NLPSOL_NUM_IN = 8)

    +---------------+--------+-------------------------------------------------+
    |   Full name   | Short  |                   Description                   |
    +===============+========+=================================================+
    | NLPSOL_X0     | x0     | Decision variables, initial guess (nx x 1)      |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_P      | p      | Value of fixed parameters (np x 1)              |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LBX    | lbx    | Decision variables lower bound (nx x 1),        |
    |               |        | default -inf.                                   |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_UBX    | ubx    | Decision variables upper bound (nx x 1),        |
    |               |        | default +inf.                                   |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LBG    | lbg    | Constraints lower bound (ng x 1), default -inf. |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_UBG    | ubg    | Constraints upper bound (ng x 1), default +inf. |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LAM_X0 | lam_x0 | Lagrange multipliers for bounds on X, initial   |
    |               |        | guess (nx x 1)                                  |
    +---------------+--------+-------------------------------------------------+
    | NLPSOL_LAM_G0 | lam_g0 | Lagrange multipliers for bounds on G, initial   |
    |               |        | guess (ng x 1)                                  |
    +---------------+--------+-------------------------------------------------+

    Extra doc: https://github.com/casadi/casadi/wiki/L_1t0

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L231

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L231-L244



    .............



    """
    return _casadi.nlpsol_in(*args)

def nlpsol_out(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      nlpsol_out() -> [str]
      nlpsol_out(int ind) -> str

    Get output scheme name by index.

    >Output scheme: casadi::NlpsolOutput (NLPSOL_NUM_OUT = 6)

    +--------------+-------+---------------------------------------------------+
    |  Full name   | Short |                    Description                    |
    +==============+=======+===================================================+
    | NLPSOL_X     | x     | Decision variables at the optimal solution (nx x  |
    |              |       | 1)                                                |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_F     | f     | Cost function value at the optimal solution (1 x  |
    |              |       | 1)                                                |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_G     | g     | Constraints function at the optimal solution (ng  |
    |              |       | x 1)                                              |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_LAM_X | lam_x | Lagrange multipliers for bounds on X at the       |
    |              |       | solution (nx x 1)                                 |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_LAM_G | lam_g | Lagrange multipliers for bounds on G at the       |
    |              |       | solution (ng x 1)                                 |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_LAM_P | lam_p | Lagrange multipliers for bounds on P at the       |
    |              |       | solution (np x 1)                                 |
    +--------------+-------+---------------------------------------------------+

    Extra doc: https://github.com/casadi/casadi/wiki/L_1t1

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L246

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L246-L257



    .......

    ::

      nlpsol_out()



    [INTERNAL] 
    Get NLP solver output scheme of NLP solvers.

    >Output scheme: casadi::NlpsolOutput (NLPSOL_NUM_OUT = 6)

    +--------------+-------+---------------------------------------------------+
    |  Full name   | Short |                    Description                    |
    +==============+=======+===================================================+
    | NLPSOL_X     | x     | Decision variables at the optimal solution (nx x  |
    |              |       | 1)                                                |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_F     | f     | Cost function value at the optimal solution (1 x  |
    |              |       | 1)                                                |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_G     | g     | Constraints function at the optimal solution (ng  |
    |              |       | x 1)                                              |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_LAM_X | lam_x | Lagrange multipliers for bounds on X at the       |
    |              |       | solution (nx x 1)                                 |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_LAM_G | lam_g | Lagrange multipliers for bounds on G at the       |
    |              |       | solution (ng x 1)                                 |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_LAM_P | lam_p | Lagrange multipliers for bounds on P at the       |
    |              |       | solution (np x 1)                                 |
    +--------------+-------+---------------------------------------------------+

    Extra doc: https://github.com/casadi/casadi/wiki/L_1sz

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L206

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L206-L210



    .............


    .......

    ::

      nlpsol_out(int ind)



    [INTERNAL] 
    Get output scheme name by index.

    >Output scheme: casadi::NlpsolOutput (NLPSOL_NUM_OUT = 6)

    +--------------+-------+---------------------------------------------------+
    |  Full name   | Short |                    Description                    |
    +==============+=======+===================================================+
    | NLPSOL_X     | x     | Decision variables at the optimal solution (nx x  |
    |              |       | 1)                                                |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_F     | f     | Cost function value at the optimal solution (1 x  |
    |              |       | 1)                                                |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_G     | g     | Constraints function at the optimal solution (ng  |
    |              |       | x 1)                                              |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_LAM_X | lam_x | Lagrange multipliers for bounds on X at the       |
    |              |       | solution (nx x 1)                                 |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_LAM_G | lam_g | Lagrange multipliers for bounds on G at the       |
    |              |       | solution (ng x 1)                                 |
    +--------------+-------+---------------------------------------------------+
    | NLPSOL_LAM_P | lam_p | Lagrange multipliers for bounds on P at the       |
    |              |       | solution (np x 1)                                 |
    +--------------+-------+---------------------------------------------------+

    Extra doc: https://github.com/casadi/casadi/wiki/L_1t1

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L246

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L246-L257



    .............



    """
    return _casadi.nlpsol_out(*args)

def nlpsol_n_in(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      nlpsol_n_in() -> int

    Number of NLP solver inputs.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1t2

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L259

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L259-L261




    """
    return _casadi.nlpsol_n_in(*args)

def nlpsol_n_out(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      nlpsol_n_out() -> int

    Number of NLP solver outputs.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1t3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L263

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L263-L265




    """
    return _casadi.nlpsol_n_out(*args)

def nlpsol_default_in(*args) -> "std::vector< double,std::allocator< double > >":
    """
      [INTERNAL] 

    ::

      nlpsol_default_in() -> [float]
      nlpsol_default_in(int ind) -> float

    Default input for an NLP solver.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1t4

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L225

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L225-L229



    .......

    ::

      nlpsol_default_in()



    [INTERNAL] 
    Default input for an NLP solver.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1t4

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L225

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L225-L229



    .............


    .......

    ::

      nlpsol_default_in(int ind)



    [INTERNAL] 
    Default input for an NLP solver.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1t4

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L212

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L212-L223



    .............



    """
    return _casadi.nlpsol_default_in(*args)

def nlpsol_options(*args) -> "std::vector< std::string,std::allocator< std::string > >":
    """
      [INTERNAL] 

    ::

      nlpsol_options(str name) -> [str]

    Get all options for a plugin.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1t5

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L830

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L830-L832




    """
    return _casadi.nlpsol_options(*args)

def nlpsol_option_type(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      nlpsol_option_type(str name, str op) -> str

    Get type info for a particular option.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1t6

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L834

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L834-L836




    """
    return _casadi.nlpsol_option_type(*args)

def nlpsol_option_info(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      nlpsol_option_info(str name, str op) -> str

    Get documentation for a particular option.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1t7

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L838

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L838-L840




    """
    return _casadi.nlpsol_option_info(*args)

def has_nlpsol(*args) -> "bool":
    """
      [INTERNAL] 

    ::

      has_nlpsol(str name) -> bool

    Check if a particular plugin is available.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L34

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L34-L36



    """
    return _casadi.has_nlpsol(*args)

def load_nlpsol(*args) -> "void":
    """
      [INTERNAL] 

    ::

      load_nlpsol(str name)

    Explicitly load a plugin dynamically.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L38

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L38-L40



    """
    return _casadi.load_nlpsol(*args)

def doc_nlpsol(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      doc_nlpsol(str name) -> str

    Get the documentation string for a plugin.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.hpp#L42

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlpsol.cpp#L42-L44



    """
    return _casadi.doc_nlpsol(*args)

def rootfinder(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      rootfinder(str name, str solver, dict:SX rfp, dict opts) -> Function
      rootfinder(str name, str solver, dict:MX rfp, dict opts) -> Function
      rootfinder(str name, str solver, Function f, dict opts) -> Function


    .......

    ::

      rootfinder(str name, str solver, dict:SX rfp, dict opts)



    [INTERNAL]

    Create a solver for rootfinding problems Takes a function where one 
    of the 
    inputs is unknown and one of the outputs is a residual function
     that is 
    always zero, defines a new function where the the unknown 
    input has been 
    replaced by a  guess for the unknown and the residual output has been 
    replaced by the 
    calculated value for the input.

    For a function [y0, y1, ...,yi, .., yn] = F(x0, x1, ..., xj, ..., xm),

    where xj is unknown and yi=0, defines a new function [y0, y1, ...,xj,
     .., 
    yn] = G(x0, x1, ..., xj_guess, ..., xm),

    xj and yi must have the same dimension and d(yi)/d(xj) must be 
    invertable.

    By default, the first input is unknown and the first output is the 

    residual.
    General information

    >List of available options

    +------------------+-----------------+------------------+------------------+
    |        Id        |      Type       |   Description    |     Used in      |
    +==================+=================+==================+==================+
    | ad_weight        | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for derivative   | Internal         |
    |                  |                 | calculation.When |                  |
    |                  |                 | there is an      |                  |
    |                  |                 | option of either |                  |
    |                  |                 | using forward or |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | directional      |                  |
    |                  |                 | derivatives, the |                  |
    |                  |                 | condition ad_wei |                  |
    |                  |                 | ght*nf<=(1-      |                  |
    |                  |                 | ad_weight)*na is |                  |
    |                  |                 | used where nf    |                  |
    |                  |                 | and na are       |                  |
    |                  |                 | estimates of the |                  |
    |                  |                 | number of        |                  |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | mode directional |                  |
    |                  |                 | derivatives      |                  |
    |                  |                 | needed. By       |                  |
    |                  |                 | default,         |                  |
    |                  |                 | ad_weight is     |                  |
    |                  |                 | calculated       |                  |
    |                  |                 | automatically,   |                  |
    |                  |                 | but this can be  |                  |
    |                  |                 | overridden by    |                  |
    |                  |                 | setting this     |                  |
    |                  |                 | option. In       |                  |
    |                  |                 | particular, 0    |                  |
    |                  |                 | means forcing    |                  |
    |                  |                 | forward mode and |                  |
    |                  |                 | 1 forcing        |                  |
    |                  |                 | reverse mode.    |                  |
    |                  |                 | Leave unset for  |                  |
    |                  |                 | (class specific) |                  |
    |                  |                 | heuristics.      |                  |
    +------------------+-----------------+------------------+------------------+
    | ad_weight_sp     | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for sparsity     | Internal         |
    |                  |                 | pattern          |                  |
    |                  |                 | calculation calc |                  |
    |                  |                 | ulation.Override |                  |
    |                  |                 | s default        |                  |
    |                  |                 | behavior. Set to |                  |
    |                  |                 | 0 and 1 to force |                  |
    |                  |                 | forward and      |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | respectively.    |                  |
    |                  |                 | Cf. option       |                  |
    |                  |                 | "ad_weight".     |                  |
    |                  |                 | When set to -1,  |                  |
    |                  |                 | sparsity is      |                  |
    |                  |                 | completely       |                  |
    |                  |                 | ignored and      |                  |
    |                  |                 | dense matrices   |                  |
    |                  |                 | are used.        |                  |
    +------------------+-----------------+------------------+------------------+
    | always_inline    | OT_BOOL         | Force inlining.  | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | cache            | OT_DICT         | Prepopulate the  | casadi::Function |
    |                  |                 | function cache.  | Internal         |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | common_options   | OT_DICT         | Options for      | casadi::OracleFu |
    |                  |                 | auto-generated   | nction           |
    |                  |                 | functions        |                  |
    +------------------+-----------------+------------------+------------------+
    | compiler         | OT_STRING       | Just-in-time     | casadi::Function |
    |                  |                 | compiler plugin  | Internal         |
    |                  |                 | to be used.      |                  |
    +------------------+-----------------+------------------+------------------+
    | constraints      | OT_INTVECTOR    | Constrain the    | casadi::Rootfind |
    |                  |                 | unknowns. 0      | er               |
    |                  |                 | (default): no    |                  |
    |                  |                 | constraint on    |                  |
    |                  |                 | ui, 1: ui >=     |                  |
    |                  |                 | 0.0, -1: ui <=   |                  |
    |                  |                 | 0.0, 2: ui >     |                  |
    |                  |                 | 0.0, -2: ui <    |                  |
    |                  |                 | 0.0.             |                  |
    +------------------+-----------------+------------------+------------------+
    | custom_jacobian  | OT_FUNCTION     | Override         | casadi::Function |
    |                  |                 | CasADi's AD. Use | Internal         |
    |                  |                 | together with    |                  |
    |                  |                 | 'jac_penalty':   |                  |
    |                  |                 | 0. Note: Highly  |                  |
    |                  |                 | experimental.    |                  |
    |                  |                 | Syntax may break |                  |
    |                  |                 | often.           |                  |
    +------------------+-----------------+------------------+------------------+
    | der_options      | OT_DICT         | Default options  | casadi::Function |
    |                  |                 | to be used to    | Internal         |
    |                  |                 | populate         |                  |
    |                  |                 | forward_options, |                  |
    |                  |                 | reverse_options, |                  |
    |                  |                 | and              |                  |
    |                  |                 | jacobian_options |                  |
    |                  |                 | before those     |                  |
    |                  |                 | options are      |                  |
    |                  |                 | merged in.       |                  |
    +------------------+-----------------+------------------+------------------+
    | derivative_of    | OT_FUNCTION     | The function is  | casadi::Function |
    |                  |                 | a derivative of  | Internal         |
    |                  |                 | another          |                  |
    |                  |                 | function. The    |                  |
    |                  |                 | type of          |                  |
    |                  |                 | derivative       |                  |
    |                  |                 | (directional     |                  |
    |                  |                 | derivative,      |                  |
    |                  |                 | Jacobian) is     |                  |
    |                  |                 | inferred from    |                  |
    |                  |                 | the function     |                  |
    |                  |                 | name.            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump             | OT_BOOL         | Dump function to | casadi::Function |
    |                  |                 | file upon first  | Internal         |
    |                  |                 | evaluation.      |                  |
    |                  |                 | [false]          |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_dir         | OT_STRING       | Directory to     | casadi::Function |
    |                  |                 | dump             | Internal         |
    |                  |                 | inputs/outputs   |                  |
    |                  |                 | to. Make sure    |                  |
    |                  |                 | the directory    |                  |
    |                  |                 | exists [.]       |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_format      | OT_STRING       | Choose file      | casadi::Function |
    |                  |                 | format to dump   | Internal         |
    |                  |                 | matrices. See    |                  |
    |                  |                 | DM.from_file     |                  |
    |                  |                 | [mtx]            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_in          | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | to file          |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_out         | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs to file  |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_fd        | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation by   |                  |
    |                  |                 | finite           |                  |
    |                  |                 | differencing.    |                  |
    |                  |                 | [default:        |                  |
    |                  |                 | false]]          |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_forward   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using forward    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_jacobian  | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobians of all |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | outputs with     |                  |
    |                  |                 | respect to all   |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | inputs - if      |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_reverse   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | transposed       |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using reverse    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | error_on_fail    | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when function    | ction            |
    |                  |                 | evaluation fails |                  |
    |                  |                 | (default true).  |                  |
    +------------------+-----------------+------------------+------------------+
    | expand           | OT_BOOL         | Replace MX with  | casadi::OracleFu |
    |                  |                 | SX expressions   | nction           |
    |                  |                 | in problem       |                  |
    |                  |                 | formulation      |                  |
    |                  |                 | [false] This     |                  |
    |                  |                 | happens before   |                  |
    |                  |                 | creating         |                  |
    |                  |                 | derivatives      |                  |
    |                  |                 | unless indicated |                  |
    |                  |                 | by               |                  |
    |                  |                 | postpone_expand  |                  |
    +------------------+-----------------+------------------+------------------+
    | external_transfo | OT_VECTORVECTOR | List of external | casadi::Function |
    | rm               |                 | _transform       | Internal         |
    |                  |                 | instruction      |                  |
    |                  |                 | arguments.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_method        | OT_STRING       | Method for       | casadi::Function |
    |                  |                 | finite           | Internal         |
    |                  |                 | differencing     |                  |
    |                  |                 | [default         |                  |
    |                  |                 | 'central']       |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_options       | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | finite           |                  |
    |                  |                 | difference       |                  |
    |                  |                 | instance         |                  |
    +------------------+-----------------+------------------+------------------+
    | forward_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | forward mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | gather_stats     | OT_BOOL         | Deprecated       | casadi::Function |
    |                  |                 | option           | Internal         |
    |                  |                 | (ignored):       |                  |
    |                  |                 | Statistics are   |                  |
    |                  |                 | now always       |                  |
    |                  |                 | collected.       |                  |
    +------------------+-----------------+------------------+------------------+
    | implicit_input   | OT_INT          | Index of the     | casadi::Rootfind |
    |                  |                 | input that       | er               |
    |                  |                 | corresponds to   |                  |
    |                  |                 | the actual root- |                  |
    |                  |                 | finding          |                  |
    +------------------+-----------------+------------------+------------------+
    | implicit_output  | OT_INT          | Index of the     | casadi::Rootfind |
    |                  |                 | output that      | er               |
    |                  |                 | corresponds to   |                  |
    |                  |                 | the actual root- |                  |
    |                  |                 | finding          |                  |
    +------------------+-----------------+------------------+------------------+
    | input_scheme     | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | inputs_check     | OT_BOOL         | Throw exceptions | casadi::Function |
    |                  |                 | when the         | Internal         |
    |                  |                 | numerical values |                  |
    |                  |                 | of the inputs    |                  |
    |                  |                 | don't make sense |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_in       | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each input if it | Internal         |
    |                  |                 | should be        |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_out      | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each output if   | Internal         |
    |                  |                 | it should be     |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | jac_penalty      | OT_DOUBLE       | When requested   | casadi::Function |
    |                  |                 | for a number of  | Internal         |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | directions, it   |                  |
    |                  |                 | may be cheaper   |                  |
    |                  |                 | to compute first |                  |
    |                  |                 | the full         |                  |
    |                  |                 | jacobian and     |                  |
    |                  |                 | then multiply    |                  |
    |                  |                 | with seeds,      |                  |
    |                  |                 | rather than      |                  |
    |                  |                 | obtain the       |                  |
    |                  |                 | requested        |                  |
    |                  |                 | directions in a  |                  |
    |                  |                 | straightforward  |                  |
    |                  |                 | manner. Casadi   |                  |
    |                  |                 | uses a heuristic |                  |
    |                  |                 | to decide which  |                  |
    |                  |                 | is cheaper. A    |                  |
    |                  |                 | high value of    |                  |
    |                  |                 | 'jac_penalty'    |                  |
    |                  |                 | makes it less    |                  |
    |                  |                 | likely for the   |                  |
    |                  |                 | heurstic to      |                  |
    |                  |                 | chose the full   |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy. The    |                  |
    |                  |                 | special value -1 |                  |
    |                  |                 | indicates never  |                  |
    |                  |                 | to use the full  |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy         |                  |
    +------------------+-----------------+------------------+------------------+
    | jacobian_functio | OT_FUNCTION     | Function object  | casadi::Rootfind |
    | n                |                 | for calculating  | er               |
    |                  |                 | the Jacobian     |                  |
    |                  |                 | (autogenerated   |                  |
    |                  |                 | by default)      |                  |
    +------------------+-----------------+------------------+------------------+
    | jacobian_options | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | Jacobian         |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | jit              | OT_BOOL         | Use just-in-time | casadi::Function |
    |                  |                 | compiler to      | Internal         |
    |                  |                 | speed up the     |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_cleanup      | OT_BOOL         | Cleanup up the   | casadi::Function |
    |                  |                 | temporary source | Internal         |
    |                  |                 | file that jit    |                  |
    |                  |                 | creates.         |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_name         | OT_STRING       | The file name    | casadi::Function |
    |                  |                 | used to write    | Internal         |
    |                  |                 | out code. The    |                  |
    |                  |                 | actual file      |                  |
    |                  |                 | names used       |                  |
    |                  |                 | depend on 'jit_t |                  |
    |                  |                 | emp_suffix' and  |                  |
    |                  |                 | include          |                  |
    |                  |                 | extensions.      |                  |
    |                  |                 | Default:         |                  |
    |                  |                 | 'jit_tmp'        |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_options      | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | jit compiler.    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_serialize    | OT_STRING       | Specify          | casadi::Function |
    |                  |                 | behaviour when   | Internal         |
    |                  |                 | serializing a    |                  |
    |                  |                 | jitted function: |                  |
    |                  |                 | SOURCE|link|embe |                  |
    |                  |                 | d.               |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_temp_suffix  | OT_BOOL         | Use a temporary  | casadi::Function |
    |                  |                 | (seemingly       | Internal         |
    |                  |                 | random) filename |                  |
    |                  |                 | suffix for       |                  |
    |                  |                 | generated code   |                  |
    |                  |                 | and libraries.   |                  |
    |                  |                 | This is desired  |                  |
    |                  |                 | for thread-      |                  |
    |                  |                 | safety. This     |                  |
    |                  |                 | behaviour may    |                  |
    |                  |                 | defeat caching   |                  |
    |                  |                 | compiler         |                  |
    |                  |                 | wrappers.        |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | linear_solver    | OT_STRING       | User-defined     | casadi::Rootfind |
    |                  |                 | linear solver    | er               |
    |                  |                 | class. Needed    |                  |
    |                  |                 | for              |                  |
    |                  |                 | sensitivities.   |                  |
    +------------------+-----------------+------------------+------------------+
    | linear_solver_op | OT_DICT         | Options to be    | casadi::Rootfind |
    | tions            |                 | passed to the    | er               |
    |                  |                 | linear solver.   |                  |
    +------------------+-----------------+------------------+------------------+
    | max_io           | OT_INT          | Acceptable       | casadi::Function |
    |                  |                 | number of inputs | Internal         |
    |                  |                 | and outputs.     |                  |
    |                  |                 | Warn if          |                  |
    |                  |                 | exceeded.        |                  |
    +------------------+-----------------+------------------+------------------+
    | max_num_dir      | OT_INT          | Specify the      | casadi::Function |
    |                  |                 | maximum number   | Internal         |
    |                  |                 | of directions    |                  |
    |                  |                 | for derivative   |                  |
    |                  |                 | functions.       |                  |
    |                  |                 | Overrules the    |                  |
    |                  |                 | builtin optimize |                  |
    |                  |                 | d_num_dir.       |                  |
    +------------------+-----------------+------------------+------------------+
    | monitor          | OT_STRINGVECTOR | Set of user      | casadi::OracleFu |
    |                  |                 | problem          | nction           |
    |                  |                 | functions to be  |                  |
    |                  |                 | monitored        |                  |
    +------------------+-----------------+------------------+------------------+
    | never_inline     | OT_BOOL         | Forbid inlining. | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | output_scheme    | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | post_expand      | OT_BOOL         | After            | casadi::Function |
    |                  |                 | construction,    | Internal         |
    |                  |                 | expand this      |                  |
    |                  |                 | Function .       |                  |
    |                  |                 | Default: False   |                  |
    +------------------+-----------------+------------------+------------------+
    | post_expand_opti | OT_DICT         | Options to be    | casadi::Function |
    | ons              |                 | passed to post-  | Internal         |
    |                  |                 | construction     |                  |
    |                  |                 | expansion.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | postpone_expand  | OT_BOOL         | When expand is   | casadi::OracleFu |
    |                  |                 | active, postpone | nction           |
    |                  |                 | it until after   |                  |
    |                  |                 | creation of      |                  |
    |                  |                 | derivatives.     |                  |
    |                  |                 | Default: False   |                  |
    +------------------+-----------------+------------------+------------------+
    | print_canonical  | OT_BOOL         | When printing    | casadi::Function |
    |                  |                 | numerical        | Internal         |
    |                  |                 | matrices, use a  |                  |
    |                  |                 | format that is   |                  |
    |                  |                 | exact and        |                  |
    |                  |                 | reproducible in  |                  |
    |                  |                 | generated C      |                  |
    |                  |                 | code.            |                  |
    +------------------+-----------------+------------------+------------------+
    | print_in         | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_out        | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs          |                  |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_time       | OT_BOOL         | print            | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time. Implies    |                  |
    |                  |                 | record_time.     |                  |
    +------------------+-----------------+------------------+------------------+
    | record_time      | OT_BOOL         | record           | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time, for        |                  |
    |                  |                 | retrieval with   |                  |
    |                  |                 | stats().         |                  |
    +------------------+-----------------+------------------+------------------+
    | regularity_check | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when NaN or Inf  | ction            |
    |                  |                 | appears during   |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | reverse_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | reverse mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | show_eval_warnin | OT_BOOL         | Show warnings    | casadi::OracleFu |
    | gs               |                 | generated from   | nction           |
    |                  |                 | function         |                  |
    |                  |                 | evaluations      |                  |
    |                  |                 | [true]           |                  |
    +------------------+-----------------+------------------+------------------+
    | specific_options | OT_DICT         | Options for      | casadi::OracleFu |
    |                  |                 | specific auto-   | nction           |
    |                  |                 | generated        |                  |
    |                  |                 | functions,       |                  |
    |                  |                 | overwriting the  |                  |
    |                  |                 | defaults from    |                  |
    |                  |                 | common_options.  |                  |
    |                  |                 | Nested           |                  |
    |                  |                 | dictionary.      |                  |
    +------------------+-----------------+------------------+------------------+
    | user_data        | OT_VOIDPTR      | A user-defined   | casadi::Function |
    |                  |                 | field that can   | Internal         |
    |                  |                 | be used to       |                  |
    |                  |                 | identify the     |                  |
    |                  |                 | function or pass |                  |
    |                  |                 | additional       |                  |
    |                  |                 | information      |                  |
    +------------------+-----------------+------------------+------------------+
    | verbose          | OT_BOOL         | Verbose          | casadi::ProtoFun |
    |                  |                 | evaluation  for  | ction            |
    |                  |                 | debugging        |                  |
    +------------------+-----------------+------------------+------------------+

    >Input scheme: casadi::RootfinderInput (ROOTFINDER_NUM_IN = 2)

    +---------------+-------+---------------------------------+
    |   Full name   | Short |           Description           |
    +===============+=======+=================================+
    | ROOTFINDER_X0 | x0    | Initial guess for the solution. |
    +---------------+-------+---------------------------------+
    | ROOTFINDER_P  | p     | Parameters.                     |
    +---------------+-------+---------------------------------+

    >Output scheme: casadi::RootfinderOutput (ROOTFINDER_NUM_OUT = 1)

    +--------------+-------+--------------------------------------+
    |  Full name   | Short |             Description              |
    +==============+=======+======================================+
    | ROOTFINDER_X | x     | Solution to the system of equations. |
    +--------------+-------+--------------------------------------+

    List of plugins
    - kinsol

    - fast_newton

    - nlpsol

    - newton

    Note: some of the plugins in this list might not be available on your 

    system.  Also, there might be extra plugins available to you that are 
    not 
    listed here. You can obtain their documentation with  
    Rootfinder.doc("myextraplugin")



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

    kinsol
    ------



    KINSOL interface from the Sundials suite

    Extra doc: https://github.com/casadi/casadi/wiki/L_226

    >List of available options

    +---------------------------+-----------------+----------------------------+
    |            Id             |      Type       |        Description         |
    +===========================+=================+============================+
    | abstol                    | OT_DOUBLE       | Stopping criterion         |
    |                           |                 | tolerance                  |
    +---------------------------+-----------------+----------------------------+
    | disable_internal_warnings | OT_BOOL         | Disable KINSOL internal    |
    |                           |                 | warning messages           |
    +---------------------------+-----------------+----------------------------+
    | exact_jacobian            | OT_BOOL         | Use exact Jacobian         |
    |                           |                 | information                |
    +---------------------------+-----------------+----------------------------+
    | f_scale                   | OT_DOUBLEVECTOR | Equation scaling factors   |
    +---------------------------+-----------------+----------------------------+
    | iterative_solver          | OT_STRING       | gmres|bcgstab|tfqmr        |
    +---------------------------+-----------------+----------------------------+
    | linear_solver_type        | OT_STRING       | dense|banded|iterative|use |
    |                           |                 | r_defined                  |
    +---------------------------+-----------------+----------------------------+
    | lower_bandwidth           | OT_INT          | Lower bandwidth for banded |
    |                           |                 | linear solvers             |
    +---------------------------+-----------------+----------------------------+
    | max_iter                  | OT_INT          | Maximum number of Newton   |
    |                           |                 | iterations. Putting 0 sets |
    |                           |                 | the default value of       |
    |                           |                 | KinSol.                    |
    +---------------------------+-----------------+----------------------------+
    | max_krylov                | OT_INT          | Maximum Krylov space       |
    |                           |                 | dimension                  |
    +---------------------------+-----------------+----------------------------+
    | pretype                   | OT_STRING       | Type of preconditioner     |
    +---------------------------+-----------------+----------------------------+
    | print_level               | OT_INT          | Verbosity level            |
    +---------------------------+-----------------+----------------------------+
    | strategy                  | OT_STRING       | Globalization strategy     |
    +---------------------------+-----------------+----------------------------+
    | u_scale                   | OT_DOUBLEVECTOR | Variable scaling factors   |
    +---------------------------+-----------------+----------------------------+
    | upper_bandwidth           | OT_INT          | Upper bandwidth for banded |
    |                           |                 | linear solvers             |
    +---------------------------+-----------------+----------------------------+
    | use_preconditioner        | OT_BOOL         | Precondition an iterative  |
    |                           |                 | solver                     |
    +---------------------------+-----------------+----------------------------+



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

    fast_newton
    -----------



    Implements simple newton iterations to solve an implicit function.

    Extra doc: https://github.com/casadi/casadi/wiki/L_237

    >List of available options

    +------------+-----------+-------------------------------------------------+
    |     Id     |   Type    |                   Description                   |
    +============+===========+=================================================+
    | abstol     | OT_DOUBLE | Stopping criterion tolerance on ||g||__inf)     |
    +------------+-----------+-------------------------------------------------+
    | abstolStep | OT_DOUBLE | Stopping criterion tolerance on step size       |
    +------------+-----------+-------------------------------------------------+
    | max_iter   | OT_INT    | Maximum number of Newton iterations to perform  |
    |            |           | before returning.                               |
    +------------+-----------+-------------------------------------------------+



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

    nlpsol
    ------





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

    newton
    ------



    Implements simple newton iterations to solve an implicit function.

    Extra doc: https://github.com/casadi/casadi/wiki/L_236

    >List of available options

    +-----------------+-----------+--------------------------------------------+
    |       Id        |   Type    |                Description                 |
    +=================+===========+============================================+
    | abstol          | OT_DOUBLE | Stopping criterion tolerance on max(|F|)   |
    +-----------------+-----------+--------------------------------------------+
    | abstolStep      | OT_DOUBLE | Stopping criterion tolerance on step size  |
    +-----------------+-----------+--------------------------------------------+
    | line_search     | OT_BOOL   | Enable line-search (default: true)         |
    +-----------------+-----------+--------------------------------------------+
    | max_iter        | OT_INT    | Maximum number of Newton iterations to     |
    |                 |           | perform before returning.                  |
    +-----------------+-----------+--------------------------------------------+
    | print_iteration | OT_BOOL   | Print information about each iteration     |
    +-----------------+-----------+--------------------------------------------+

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_21r

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L111

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L111-L114



    .............


    .......

    ::

      rootfinder(str name, str solver, dict:MX rfp, dict opts)
      rootfinder(str name, str solver, Function f, dict opts)



    [INTERNAL] 

    .............



    """
    return _casadi.rootfinder(*args)

def rootfinder_in(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      rootfinder_in() -> [str]
      rootfinder_in(int ind) -> str

    Get rootfinder input scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1u0

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L47

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L47-L54



    .......

    ::

      rootfinder_in()



    [INTERNAL] 
    Get rootfinder input scheme.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ty

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L35

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L35-L39



    .............


    .......

    ::

      rootfinder_in(int ind)



    [INTERNAL] 
    Get rootfinder input scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1u0

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L47

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L47-L54



    .............



    """
    return _casadi.rootfinder_in(*args)

def rootfinder_out(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      rootfinder_out() -> [str]
      rootfinder_out(int ind) -> str

    Get rootfinder output scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1u1

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L56

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L56-L62



    .......

    ::

      rootfinder_out()



    [INTERNAL] 
    Get rootfinder output scheme.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1tz

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L41

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L41-L45



    .............


    .......

    ::

      rootfinder_out(int ind)



    [INTERNAL] 
    Get rootfinder output scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1u1

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L56

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L56-L62



    .............



    """
    return _casadi.rootfinder_out(*args)

def rootfinder_n_in(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      rootfinder_n_in() -> int

    Number of rootfinder inputs.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1u2

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L64

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L64-L66




    """
    return _casadi.rootfinder_n_in(*args)

def rootfinder_n_out(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      rootfinder_n_out() -> int

    Number of rootfinder outputs.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1u3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L68

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L68-L70




    """
    return _casadi.rootfinder_n_out(*args)

def rootfinder_options(*args) -> "std::vector< std::string,std::allocator< std::string > >":
    """
      [INTERNAL] 

    ::

      rootfinder_options(str name) -> [str]

    Get all options for a plugin.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1u4

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L87

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L87-L89




    """
    return _casadi.rootfinder_options(*args)

def rootfinder_option_type(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      rootfinder_option_type(str name, str op) -> str

    Get type info for a particular option.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1u5

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L91

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L91-L93




    """
    return _casadi.rootfinder_option_type(*args)

def rootfinder_option_info(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      rootfinder_option_info(str name, str op) -> str

    Get documentation for a particular option.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1u6

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L95

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L95-L97




    """
    return _casadi.rootfinder_option_info(*args)

def has_rootfinder(*args) -> "bool":
    """
      [INTERNAL] 

    ::

      has_rootfinder(str name) -> bool

    Check if a particular plugin is available.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L99

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L99-L101




    """
    return _casadi.has_rootfinder(*args)

def load_rootfinder(*args) -> "void":
    """
      [INTERNAL] 

    ::

      load_rootfinder(str name)

    Explicitly load a plugin dynamically.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L103

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L103-L105




    """
    return _casadi.load_rootfinder(*args)

def doc_rootfinder(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      doc_rootfinder(str name) -> str

    Get the documentation string for a plugin.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.hpp#L107

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/rootfinder.cpp#L107-L109




    """
    return _casadi.doc_rootfinder(*args)
class Linsol(SharedObject, PrintableCommon):
    """
      [INTERNAL] 

    ::


    Linear solver.

    Create a solver for linear systems of equations Solves the linear 
    system 
    A*X = B or A^T*X = B for X with A square and non-singular

    If A is structurally singular, an error will be thrown during init. If
     A is
     numerically singular, the prepare step will fail.
    General informationList 
    of plugins
    - csparsecholesky

    - csparse

    - ma27

    - lapacklu

    - lapackqr

    - mumps

    - ldl

    - qr

    - tridiag

    - symbolicqr

    Note: some of the plugins in this list might not be available on your 

    system.  Also, there might be extra plugins available to you that are 
    not 
    listed here. You can obtain their documentation with   
    Linsol.doc("myextraplugin")



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

    csparsecholesky
    ---------------



    Linsol with CSparseCholesky Interface

    Extra doc: https://github.com/casadi/casadi/wiki/L_21u



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

    csparse
    -------



    Linsol with CSparse Interface

    Extra doc: https://github.com/casadi/casadi/wiki/L_21t



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

    ma27
    ----



    Interface to the sparse direct linear solver MA27 Works for symmetric

    indefinite systems Partly adopted from qpOASES 3.2 
    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_229



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

    lapacklu
    --------



    This class solves the linear system  A.x=b by making an LU factorization of 
    A:  A = L.U, with L lower and U upper triangular

    Extra doc: https://github.com/casadi/casadi/wiki/L_22h

    >List of available options

    +-----------------------------+---------+----------------------------------+
    |             Id              |  Type   |           Description            |
    +=============================+=========+==================================+
    | allow_equilibration_failure | OT_BOOL | Non-fatal error when             |
    |                             |         | equilibration fails              |
    +-----------------------------+---------+----------------------------------+
    | equilibration               | OT_BOOL | Equilibrate the matrix           |
    +-----------------------------+---------+----------------------------------+



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

    lapackqr
    --------



    This class solves the linear system  A.x=b by making an QR factorization of 
    A:  A = Q.R, with Q orthogonal and R upper triangular

    Extra doc: https://github.com/casadi/casadi/wiki/L_22g

    >List of available options

    +----------+--------+------------------------------------------------------+
    |    Id    |  Type  |                     Description                      |
    +==========+========+======================================================+
    | max_nrhs | OT_INT | Maximum number of right-hand-sides that get          |
    |          |        | processed in a single pass [default:10].             |
    +----------+--------+------------------------------------------------------+



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

    mumps
    -----



    Interface to the sparse direct linear solver MUMPS Works for 
    symmetric 
    indefinite systems 
    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_22t

    >List of available options

    +-----------+---------+-------------------+
    |    Id     |  Type   |    Description    |
    +===========+=========+===================+
    | posdef    | OT_BOOL | Positive definite |
    +-----------+---------+-------------------+
    | symmetric | OT_BOOL | Symmetric matrix  |
    +-----------+---------+-------------------+



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

    ldl
    ---



    Linear solver using sparse direct LDL factorization

    Extra doc: https://github.com/casadi/casadi/wiki/L_233

    >List of available options

    +-------------+---------+-----------------------------------------------+
    |     Id      |  Type   |                  Description                  |
    +=============+=========+===============================================+
    | incomplete  | OT_BOOL | Incomplete factorization, without any fill-in |
    +-------------+---------+-----------------------------------------------+
    | preordering | OT_BOOL | Approximate minimal degree (AMD) preordering  |
    +-------------+---------+-----------------------------------------------+



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

    qr
    --



    Linear solver using sparse direct QR factorization

    Extra doc: https://github.com/casadi/casadi/wiki/L_22z

    >List of available options

    +-------+-----------+------------------------------------------------------+
    |  Id   |   Type    |                     Description                      |
    +=======+===========+======================================================+
    | cache | OT_DOUBLE | Amount of factorisations to remember (thread-local)  |
    |       |           | [0]                                                  |
    +-------+-----------+------------------------------------------------------+
    | eps   | OT_DOUBLE | Minimum R entry before singularity is declared       |
    |       |           | [1e-12]                                              |
    +-------+-----------+------------------------------------------------------+



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

    tridiag
    -------



    Linear solver for tridiagonal matrices

    Extra doc: https://github.com/casadi/casadi/wiki/L_22v



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

    symbolicqr
    ----------



    Linear solver for sparse least-squares problems Inspired from 
    https://github.com/scipy/scipy/blob/v0.14.0/scipy/sparse/linalg/isolve/lsqr.py#L96

    Extra doc: https://github.com/casadi/casadi/wiki/L_230

    Linsol based on QR factorization with sparsity pattern based reordering  
    without partial pivoting

    Extra doc: https://github.com/casadi/casadi/wiki/L_231

    >List of available options

    +-------+---------+----------------------------------------------------+
    |  Id   |  Type   |                    Description                     |
    +=======+=========+====================================================+
    | fopts | OT_DICT | Options to be passed to generated function objects |
    +-------+---------+----------------------------------------------------+

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_1kh

    C++ includes: linsol.hpp



    """

    __swig_setmethods__ = {}
    for _s in [SharedObject, PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, Linsol, name, value)
    __swig_getmethods__ = {}
    for _s in [SharedObject, PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, Linsol, name)
    __repr__ = _swig_repr

    def type_name(*args) -> "std::string":
        """


        ::

          type_name() -> str



        """
        return _casadi.Linsol_type_name(*args)

    type_name = staticmethod(type_name)

    def has_plugin(*args) -> "bool":
        """


        ::

          has_plugin(str name) -> bool



        """
        return _casadi.Linsol_has_plugin(*args)

    has_plugin = staticmethod(has_plugin)

    def load_plugin(*args) -> "void":
        """


        ::

          load_plugin(str name)



        """
        return _casadi.Linsol_load_plugin(*args)

    load_plugin = staticmethod(load_plugin)

    def doc(*args) -> "std::string":
        """


        ::

          doc(str name) -> str



        """
        return _casadi.Linsol_doc(*args)

    doc = staticmethod(doc)

    def plugin_name(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          plugin_name(self) -> str

        Query plugin name.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L97

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L65-L67



        """
        return _casadi.Linsol_plugin_name(self, *args)


    def sparsity(self, *args) -> "casadi::Sparsity const &":
        """
          [INTERNAL] 

        ::

          sparsity(self) -> Sparsity

        Get linear system sparsity.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L100

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L69-L71



        """
        return _casadi.Linsol_sparsity(self, *args)


    def sfact(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          sfact(self, DM A)

        Symbolic factorization of the linear system, e.g. selecting 
        pivots.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L103

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L105-L108




        """
        return _casadi.Linsol_sfact(self, *args)


    def nfact(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          nfact(self, DM A)

        Numeric factorization of the linear system.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L106

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L127-L130




        """
        return _casadi.Linsol_nfact(self, *args)


    def solve(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          solve(self, DM A, DM B, bool tr) -> DM
          solve(self, MX A, MX B, bool tr) -> MX

         Solve linear system of equations

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L111

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L101-L103



        .......

        ::

          solve(self, DM A, DM B, bool tr)



        [INTERNAL] 
         Solve linear system of equations

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L110

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L73-L99


        .............


        .......

        ::

          solve(self, MX A, MX B, bool tr)



        [INTERNAL] 
         Solve linear system of equations

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L111

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L101-L103



        .............



        """
        return _casadi.Linsol_solve(self, *args)


    def neig(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          neig(self, DM A) -> int

        Number of negative eigenvalues.

        Not available for all solvers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1kk

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L119

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L166-L171




        """
        return _casadi.Linsol_neig(self, *args)


    def rank(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          rank(self, DM A) -> int

         Matrix rank.

        Not available for all solvers

        Extra doc: https://github.com/casadi/casadi/wiki/L_1kl

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L126

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L177-L182




        """
        return _casadi.Linsol_rank(self, *args)


    def stats(self, *args) -> "casadi::Dict":
        """
          [INTERNAL] 

        ::

          stats(self, int mem) -> dict

        Get all statistics obtained at the end of the last evaluate 
        call.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L129

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L218-L222




        """
        return _casadi.Linsol_stats(self, *args)


    def __init__(self, *args):
        """


        ::

          Linsol()
          Linsol(Linsol other)
          Linsol(str name, str solver, Sparsity sp, dict opts)


        .......

        ::

          Linsol(Linsol other)



        .............


        .......

        ::

          Linsol()



        [INTERNAL] 
        Default constructor.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L63

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L32-L33


        .............


        .......

        ::

          Linsol(str name, str solver, Sparsity sp, dict opts)



        [INTERNAL] 
        Constructor.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L66

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L35-L39


        .............



        """
        this = _casadi.new_Linsol(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_Linsol
Linsol_swigregister = _casadi.Linsol_swigregister
Linsol_swigregister(Linsol)

def Linsol_type_name(*args) -> "std::string":
    """


    ::

      type_name() -> str



    """
    return _casadi.Linsol_type_name(*args)

def Linsol_has_plugin(*args) -> "bool":
    """


    ::

      has_plugin(str name) -> bool



    """
    return _casadi.Linsol_has_plugin(*args)

def Linsol_load_plugin(*args) -> "void":
    """


    ::

      load_plugin(str name)



    """
    return _casadi.Linsol_load_plugin(*args)

def Linsol_doc(*args) -> "std::string":
    """


    ::

      doc(str name) -> str



    """
    return _casadi.Linsol_doc(*args)


def has_linsol(*args) -> "bool":
    """
      [INTERNAL] 

    ::

      has_linsol(str name) -> bool

    Check if a particular plugin is available.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L206

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L206-L208




    """
    return _casadi.has_linsol(*args)

def load_linsol(*args) -> "void":
    """
      [INTERNAL] 

    ::

      load_linsol(str name)

    Explicitly load a plugin dynamically.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L210

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L210-L212




    """
    return _casadi.load_linsol(*args)

def doc_linsol(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      doc_linsol(str name) -> str

    Get the documentation string for a plugin.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/linsol.hpp#L214

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/linsol.cpp#L214-L216




    """
    return _casadi.doc_linsol(*args)

def dplesol(*args) -> "casadi::DMVector":
    """
      [INTERNAL] 

    ::

      dplesol([DM] A, [DM] V, str solver, dict opts) -> [DM]
      dplesol(MX A, MX V, str solver, dict opts) -> MX
      dplesol([MX] A, [MX] V, str solver, dict opts) -> [MX]
      dplesol(str name, str solver, dict:Sparsity st, dict opts) -> Function


    .......

    ::

      dplesol([DM] A, [DM] V, str solver, dict opts)
      dplesol(MX A, MX V, str solver, dict opts)
      dplesol([MX] A, [MX] V, str solver, dict opts)



    [INTERNAL] 

    .............


    .......

    ::

      dplesol(str name, str solver, dict:Sparsity st, dict opts)



    [INTERNAL]

    Discrete periodic Lyapunov Equation solver Given matrices  $A_k$ and 
    symmetric  $V_k, k = 0..K-1$

    ::

      A_k in R^(n x n)
      V_k in R^n


    provides all of  $P_k$ that satisfy:

    ::

      P_0 = A_(K-1)*P_(K-1)*A_(K-1)' + V_k
      P_k+1 = A_k*P_k*A_k' + V_k  for k = 1..K-1


    General information

    >List of available options

    +------------------+-----------------+------------------+------------------+
    |        Id        |      Type       |   Description    |     Used in      |
    +==================+=================+==================+==================+
    | ad_weight        | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for derivative   | Internal         |
    |                  |                 | calculation.When |                  |
    |                  |                 | there is an      |                  |
    |                  |                 | option of either |                  |
    |                  |                 | using forward or |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | directional      |                  |
    |                  |                 | derivatives, the |                  |
    |                  |                 | condition ad_wei |                  |
    |                  |                 | ght*nf<=(1-      |                  |
    |                  |                 | ad_weight)*na is |                  |
    |                  |                 | used where nf    |                  |
    |                  |                 | and na are       |                  |
    |                  |                 | estimates of the |                  |
    |                  |                 | number of        |                  |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | mode directional |                  |
    |                  |                 | derivatives      |                  |
    |                  |                 | needed. By       |                  |
    |                  |                 | default,         |                  |
    |                  |                 | ad_weight is     |                  |
    |                  |                 | calculated       |                  |
    |                  |                 | automatically,   |                  |
    |                  |                 | but this can be  |                  |
    |                  |                 | overridden by    |                  |
    |                  |                 | setting this     |                  |
    |                  |                 | option. In       |                  |
    |                  |                 | particular, 0    |                  |
    |                  |                 | means forcing    |                  |
    |                  |                 | forward mode and |                  |
    |                  |                 | 1 forcing        |                  |
    |                  |                 | reverse mode.    |                  |
    |                  |                 | Leave unset for  |                  |
    |                  |                 | (class specific) |                  |
    |                  |                 | heuristics.      |                  |
    +------------------+-----------------+------------------+------------------+
    | ad_weight_sp     | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for sparsity     | Internal         |
    |                  |                 | pattern          |                  |
    |                  |                 | calculation calc |                  |
    |                  |                 | ulation.Override |                  |
    |                  |                 | s default        |                  |
    |                  |                 | behavior. Set to |                  |
    |                  |                 | 0 and 1 to force |                  |
    |                  |                 | forward and      |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | respectively.    |                  |
    |                  |                 | Cf. option       |                  |
    |                  |                 | "ad_weight".     |                  |
    |                  |                 | When set to -1,  |                  |
    |                  |                 | sparsity is      |                  |
    |                  |                 | completely       |                  |
    |                  |                 | ignored and      |                  |
    |                  |                 | dense matrices   |                  |
    |                  |                 | are used.        |                  |
    +------------------+-----------------+------------------+------------------+
    | always_inline    | OT_BOOL         | Force inlining.  | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | cache            | OT_DICT         | Prepopulate the  | casadi::Function |
    |                  |                 | function cache.  | Internal         |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | compiler         | OT_STRING       | Just-in-time     | casadi::Function |
    |                  |                 | compiler plugin  | Internal         |
    |                  |                 | to be used.      |                  |
    +------------------+-----------------+------------------+------------------+
    | const_dim        | OT_BOOL         | Assume constant  | casadi::Dple     |
    |                  |                 | dimension of P   |                  |
    +------------------+-----------------+------------------+------------------+
    | custom_jacobian  | OT_FUNCTION     | Override         | casadi::Function |
    |                  |                 | CasADi's AD. Use | Internal         |
    |                  |                 | together with    |                  |
    |                  |                 | 'jac_penalty':   |                  |
    |                  |                 | 0. Note: Highly  |                  |
    |                  |                 | experimental.    |                  |
    |                  |                 | Syntax may break |                  |
    |                  |                 | often.           |                  |
    +------------------+-----------------+------------------+------------------+
    | der_options      | OT_DICT         | Default options  | casadi::Function |
    |                  |                 | to be used to    | Internal         |
    |                  |                 | populate         |                  |
    |                  |                 | forward_options, |                  |
    |                  |                 | reverse_options, |                  |
    |                  |                 | and              |                  |
    |                  |                 | jacobian_options |                  |
    |                  |                 | before those     |                  |
    |                  |                 | options are      |                  |
    |                  |                 | merged in.       |                  |
    +------------------+-----------------+------------------+------------------+
    | derivative_of    | OT_FUNCTION     | The function is  | casadi::Function |
    |                  |                 | a derivative of  | Internal         |
    |                  |                 | another          |                  |
    |                  |                 | function. The    |                  |
    |                  |                 | type of          |                  |
    |                  |                 | derivative       |                  |
    |                  |                 | (directional     |                  |
    |                  |                 | derivative,      |                  |
    |                  |                 | Jacobian) is     |                  |
    |                  |                 | inferred from    |                  |
    |                  |                 | the function     |                  |
    |                  |                 | name.            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump             | OT_BOOL         | Dump function to | casadi::Function |
    |                  |                 | file upon first  | Internal         |
    |                  |                 | evaluation.      |                  |
    |                  |                 | [false]          |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_dir         | OT_STRING       | Directory to     | casadi::Function |
    |                  |                 | dump             | Internal         |
    |                  |                 | inputs/outputs   |                  |
    |                  |                 | to. Make sure    |                  |
    |                  |                 | the directory    |                  |
    |                  |                 | exists [.]       |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_format      | OT_STRING       | Choose file      | casadi::Function |
    |                  |                 | format to dump   | Internal         |
    |                  |                 | matrices. See    |                  |
    |                  |                 | DM.from_file     |                  |
    |                  |                 | [mtx]            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_in          | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | to file          |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_out         | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs to file  |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_fd        | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation by   |                  |
    |                  |                 | finite           |                  |
    |                  |                 | differencing.    |                  |
    |                  |                 | [default:        |                  |
    |                  |                 | false]]          |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_forward   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using forward    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_jacobian  | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobians of all |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | outputs with     |                  |
    |                  |                 | respect to all   |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | inputs - if      |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_reverse   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | transposed       |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using reverse    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | eps_unstable     | OT_DOUBLE       | A margin for     | casadi::Dple     |
    |                  |                 | unstability      |                  |
    |                  |                 | detection        |                  |
    +------------------+-----------------+------------------+------------------+
    | error_on_fail    | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when function    | ction            |
    |                  |                 | evaluation fails |                  |
    |                  |                 | (default true).  |                  |
    +------------------+-----------------+------------------+------------------+
    | error_unstable   | OT_BOOL         | Throw an         | casadi::Dple     |
    |                  |                 | exception when   |                  |
    |                  |                 | it is detected   |                  |
    |                  |                 | that             |                  |
    |                  |                 | Product(A_i,     |                  |
    |                  |                 | i=N..1)has       |                  |
    |                  |                 | eigenvalues      |                  |
    |                  |                 | greater than     |                  |
    |                  |                 | 1-eps_unstable   |                  |
    +------------------+-----------------+------------------+------------------+
    | external_transfo | OT_VECTORVECTOR | List of external | casadi::Function |
    | rm               |                 | _transform       | Internal         |
    |                  |                 | instruction      |                  |
    |                  |                 | arguments.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_method        | OT_STRING       | Method for       | casadi::Function |
    |                  |                 | finite           | Internal         |
    |                  |                 | differencing     |                  |
    |                  |                 | [default         |                  |
    |                  |                 | 'central']       |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_options       | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | finite           |                  |
    |                  |                 | difference       |                  |
    |                  |                 | instance         |                  |
    +------------------+-----------------+------------------+------------------+
    | forward_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | forward mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | gather_stats     | OT_BOOL         | Deprecated       | casadi::Function |
    |                  |                 | option           | Internal         |
    |                  |                 | (ignored):       |                  |
    |                  |                 | Statistics are   |                  |
    |                  |                 | now always       |                  |
    |                  |                 | collected.       |                  |
    +------------------+-----------------+------------------+------------------+
    | input_scheme     | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | inputs_check     | OT_BOOL         | Throw exceptions | casadi::Function |
    |                  |                 | when the         | Internal         |
    |                  |                 | numerical values |                  |
    |                  |                 | of the inputs    |                  |
    |                  |                 | don't make sense |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_in       | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each input if it | Internal         |
    |                  |                 | should be        |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_out      | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each output if   | Internal         |
    |                  |                 | it should be     |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | jac_penalty      | OT_DOUBLE       | When requested   | casadi::Function |
    |                  |                 | for a number of  | Internal         |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | directions, it   |                  |
    |                  |                 | may be cheaper   |                  |
    |                  |                 | to compute first |                  |
    |                  |                 | the full         |                  |
    |                  |                 | jacobian and     |                  |
    |                  |                 | then multiply    |                  |
    |                  |                 | with seeds,      |                  |
    |                  |                 | rather than      |                  |
    |                  |                 | obtain the       |                  |
    |                  |                 | requested        |                  |
    |                  |                 | directions in a  |                  |
    |                  |                 | straightforward  |                  |
    |                  |                 | manner. Casadi   |                  |
    |                  |                 | uses a heuristic |                  |
    |                  |                 | to decide which  |                  |
    |                  |                 | is cheaper. A    |                  |
    |                  |                 | high value of    |                  |
    |                  |                 | 'jac_penalty'    |                  |
    |                  |                 | makes it less    |                  |
    |                  |                 | likely for the   |                  |
    |                  |                 | heurstic to      |                  |
    |                  |                 | chose the full   |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy. The    |                  |
    |                  |                 | special value -1 |                  |
    |                  |                 | indicates never  |                  |
    |                  |                 | to use the full  |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy         |                  |
    +------------------+-----------------+------------------+------------------+
    | jacobian_options | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | Jacobian         |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | jit              | OT_BOOL         | Use just-in-time | casadi::Function |
    |                  |                 | compiler to      | Internal         |
    |                  |                 | speed up the     |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_cleanup      | OT_BOOL         | Cleanup up the   | casadi::Function |
    |                  |                 | temporary source | Internal         |
    |                  |                 | file that jit    |                  |
    |                  |                 | creates.         |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_name         | OT_STRING       | The file name    | casadi::Function |
    |                  |                 | used to write    | Internal         |
    |                  |                 | out code. The    |                  |
    |                  |                 | actual file      |                  |
    |                  |                 | names used       |                  |
    |                  |                 | depend on 'jit_t |                  |
    |                  |                 | emp_suffix' and  |                  |
    |                  |                 | include          |                  |
    |                  |                 | extensions.      |                  |
    |                  |                 | Default:         |                  |
    |                  |                 | 'jit_tmp'        |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_options      | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | jit compiler.    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_serialize    | OT_STRING       | Specify          | casadi::Function |
    |                  |                 | behaviour when   | Internal         |
    |                  |                 | serializing a    |                  |
    |                  |                 | jitted function: |                  |
    |                  |                 | SOURCE|link|embe |                  |
    |                  |                 | d.               |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_temp_suffix  | OT_BOOL         | Use a temporary  | casadi::Function |
    |                  |                 | (seemingly       | Internal         |
    |                  |                 | random) filename |                  |
    |                  |                 | suffix for       |                  |
    |                  |                 | generated code   |                  |
    |                  |                 | and libraries.   |                  |
    |                  |                 | This is desired  |                  |
    |                  |                 | for thread-      |                  |
    |                  |                 | safety. This     |                  |
    |                  |                 | behaviour may    |                  |
    |                  |                 | defeat caching   |                  |
    |                  |                 | compiler         |                  |
    |                  |                 | wrappers.        |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | max_io           | OT_INT          | Acceptable       | casadi::Function |
    |                  |                 | number of inputs | Internal         |
    |                  |                 | and outputs.     |                  |
    |                  |                 | Warn if          |                  |
    |                  |                 | exceeded.        |                  |
    +------------------+-----------------+------------------+------------------+
    | max_num_dir      | OT_INT          | Specify the      | casadi::Function |
    |                  |                 | maximum number   | Internal         |
    |                  |                 | of directions    |                  |
    |                  |                 | for derivative   |                  |
    |                  |                 | functions.       |                  |
    |                  |                 | Overrules the    |                  |
    |                  |                 | builtin optimize |                  |
    |                  |                 | d_num_dir.       |                  |
    +------------------+-----------------+------------------+------------------+
    | never_inline     | OT_BOOL         | Forbid inlining. | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | output_scheme    | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | pos_def          | OT_BOOL         | Assume P         | casadi::Dple     |
    |                  |                 | positive         |                  |
    |                  |                 | definite         |                  |
    +------------------+-----------------+------------------+------------------+
    | post_expand      | OT_BOOL         | After            | casadi::Function |
    |                  |                 | construction,    | Internal         |
    |                  |                 | expand this      |                  |
    |                  |                 | Function .       |                  |
    |                  |                 | Default: False   |                  |
    +------------------+-----------------+------------------+------------------+
    | post_expand_opti | OT_DICT         | Options to be    | casadi::Function |
    | ons              |                 | passed to post-  | Internal         |
    |                  |                 | construction     |                  |
    |                  |                 | expansion.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | print_canonical  | OT_BOOL         | When printing    | casadi::Function |
    |                  |                 | numerical        | Internal         |
    |                  |                 | matrices, use a  |                  |
    |                  |                 | format that is   |                  |
    |                  |                 | exact and        |                  |
    |                  |                 | reproducible in  |                  |
    |                  |                 | generated C      |                  |
    |                  |                 | code.            |                  |
    +------------------+-----------------+------------------+------------------+
    | print_in         | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_out        | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs          |                  |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_time       | OT_BOOL         | print            | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time. Implies    |                  |
    |                  |                 | record_time.     |                  |
    +------------------+-----------------+------------------+------------------+
    | record_time      | OT_BOOL         | record           | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time, for        |                  |
    |                  |                 | retrieval with   |                  |
    |                  |                 | stats().         |                  |
    +------------------+-----------------+------------------+------------------+
    | regularity_check | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when NaN or Inf  | ction            |
    |                  |                 | appears during   |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | reverse_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | reverse mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | user_data        | OT_VOIDPTR      | A user-defined   | casadi::Function |
    |                  |                 | field that can   | Internal         |
    |                  |                 | be used to       |                  |
    |                  |                 | identify the     |                  |
    |                  |                 | function or pass |                  |
    |                  |                 | additional       |                  |
    |                  |                 | information      |                  |
    +------------------+-----------------+------------------+------------------+
    | verbose          | OT_BOOL         | Verbose          | casadi::ProtoFun |
    |                  |                 | evaluation  for  | ction            |
    |                  |                 | debugging        |                  |
    +------------------+-----------------+------------------+------------------+

    >Input scheme: casadi::DpleInput (DPLE_NUM_IN = 2)

    +-----------+-------+------------------------------------------------------+
    | Full name | Short |                     Description                      |
    +===========+=======+======================================================+
    | DPLE_A    | a     | A matrices (horzcat when const_dim, diagcat          |
    |           |       | otherwise) [a].                                      |
    +-----------+-------+------------------------------------------------------+
    | DPLE_V    | v     | V matrices (horzcat when const_dim, diagcat          |
    |           |       | otherwise) [v].                                      |
    +-----------+-------+------------------------------------------------------+

    >Output scheme: casadi::DpleOutput (DPLE_NUM_OUT = 1)

    +-----------+-------+------------------------------------------------------+
    | Full name | Short |                     Description                      |
    +===========+=======+======================================================+
    | DPLE_P    | p     | Lyapunov matrix (horzcat when const_dim, diagcat     |
    |           |       | otherwise) (Cholesky of P if pos_def) [p].           |
    +-----------+-------+------------------------------------------------------+

    List of plugins
    - slicot

    Note: some of the plugins in this list might not be available on your 

    system.  Also, there might be extra plugins available to you that are 
    not 
    listed here. You can obtain their documentation with  
    Dple.doc("myextraplugin")



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

    slicot
    ------



    An efficient solver for Discrete Periodic Lyapunov Equations using 
    SLICOT

    Uses Periodic Schur Decomposition ('psd') and does not assume positive

    definiteness. Based on Periodic Lyapunov equations: some applications
     and 
    new algorithms. Int. J. Control, vol. 67, pp. 69-87, 1997.

    Overview of the method: J. Gillis Practical Methods for Approximate 
    Robust 
    Periodic Optimal Control ofNonlinear Mechanical Systems, PhD 
    Thesis, 
    KULeuven, 2015

    Extra doc: https://github.com/casadi/casadi/wiki/L_22j

    >List of available options

    +-----------------------+-----------+--------------------------------------+
    |          Id           |   Type    |             Description              |
    +=======================+===========+======================================+
    | linear_solver         | OT_STRING | User-defined linear solver class.    |
    |                       |           | Needed for sensitivities.            |
    +-----------------------+-----------+--------------------------------------+
    | linear_solver_options | OT_DICT   | Options to be passed to the linear   |
    |                       |           | solver.                              |
    +-----------------------+-----------+--------------------------------------+
    | psd_num_zero          | OT_DOUBLE | Numerical zero used in Periodic      |
    |                       |           | Schur decomposition with slicot.This |
    |                       |           | option is needed when your systems   |
    |                       |           | has Floquet multiplierszero or close |
    |                       |           | to zero                              |
    +-----------------------+-----------+--------------------------------------+

    Joris Gillis

    Extra doc: https://github.com/casadi/casadi/wiki/L_21o

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.hpp#L97

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.cpp#L97-L100


    .............



    """
    return _casadi.dplesol(*args)

def dple_in(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      dple_in() -> [str]
      dple_in(int ind) -> str

    Get DPLE input scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ne

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.hpp#L114

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.cpp#L114-L121


    .......

    ::

      dple_in()



    [INTERNAL] 
    Get input scheme of DPLE solvers.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1nc

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.hpp#L102

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.cpp#L102-L106


    .............


    .......

    ::

      dple_in(int ind)



    [INTERNAL] 
    Get DPLE input scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ne

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.hpp#L114

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.cpp#L114-L121


    .............



    """
    return _casadi.dple_in(*args)

def dple_out(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      dple_out() -> [str]
      dple_out(int ind) -> str

    Get DPLE output scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1nf

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.hpp#L123

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.cpp#L123-L129


    .......

    ::

      dple_out(int ind)



    [INTERNAL] 
    Get DPLE output scheme name by index.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1nf

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.hpp#L123

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.cpp#L123-L129


    .............


    .......

    ::

      dple_out()



    [INTERNAL] 
    Get output scheme of DPLE solvers.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1nd

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.hpp#L108

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.cpp#L108-L112


    .............



    """
    return _casadi.dple_out(*args)

def dple_n_in(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      dple_n_in() -> int

    Get the number of QP solver inputs.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ng

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.hpp#L131

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.cpp#L131-L133



    """
    return _casadi.dple_n_in(*args)

def dple_n_out(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      dple_n_out() -> int

    Get the number of QP solver outputs.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1nh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.hpp#L135

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.cpp#L135-L137



    """
    return _casadi.dple_n_out(*args)

def has_dple(*args) -> "bool":
    """
      [INTERNAL] 

    ::

      has_dple(str name) -> bool

    Check if a particular plugin is available.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.hpp#L31

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.cpp#L31-L33



    """
    return _casadi.has_dple(*args)

def load_dple(*args) -> "void":
    """
      [INTERNAL] 

    ::

      load_dple(str name)

    Explicitly load a plugin dynamically.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.hpp#L35

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.cpp#L35-L37



    """
    return _casadi.load_dple(*args)

def doc_dple(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      doc_dple(str name) -> str

    Get the documentation string for a plugin.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.hpp#L39

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/dple.cpp#L39-L41



    """
    return _casadi.doc_dple(*args)

def expmsol(*args) -> "casadi::Function":
    """
      [INTERNAL]

    ::

      expmsol(str name, str solver, Sparsity A, dict opts) -> Function


    Performs a matrix exponentiation expm(A)
    General information

    >List of available options

    +------------------+-----------------+------------------+------------------+
    |        Id        |      Type       |   Description    |     Used in      |
    +==================+=================+==================+==================+
    | ad_weight        | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for derivative   | Internal         |
    |                  |                 | calculation.When |                  |
    |                  |                 | there is an      |                  |
    |                  |                 | option of either |                  |
    |                  |                 | using forward or |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | directional      |                  |
    |                  |                 | derivatives, the |                  |
    |                  |                 | condition ad_wei |                  |
    |                  |                 | ght*nf<=(1-      |                  |
    |                  |                 | ad_weight)*na is |                  |
    |                  |                 | used where nf    |                  |
    |                  |                 | and na are       |                  |
    |                  |                 | estimates of the |                  |
    |                  |                 | number of        |                  |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | mode directional |                  |
    |                  |                 | derivatives      |                  |
    |                  |                 | needed. By       |                  |
    |                  |                 | default,         |                  |
    |                  |                 | ad_weight is     |                  |
    |                  |                 | calculated       |                  |
    |                  |                 | automatically,   |                  |
    |                  |                 | but this can be  |                  |
    |                  |                 | overridden by    |                  |
    |                  |                 | setting this     |                  |
    |                  |                 | option. In       |                  |
    |                  |                 | particular, 0    |                  |
    |                  |                 | means forcing    |                  |
    |                  |                 | forward mode and |                  |
    |                  |                 | 1 forcing        |                  |
    |                  |                 | reverse mode.    |                  |
    |                  |                 | Leave unset for  |                  |
    |                  |                 | (class specific) |                  |
    |                  |                 | heuristics.      |                  |
    +------------------+-----------------+------------------+------------------+
    | ad_weight_sp     | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for sparsity     | Internal         |
    |                  |                 | pattern          |                  |
    |                  |                 | calculation calc |                  |
    |                  |                 | ulation.Override |                  |
    |                  |                 | s default        |                  |
    |                  |                 | behavior. Set to |                  |
    |                  |                 | 0 and 1 to force |                  |
    |                  |                 | forward and      |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | respectively.    |                  |
    |                  |                 | Cf. option       |                  |
    |                  |                 | "ad_weight".     |                  |
    |                  |                 | When set to -1,  |                  |
    |                  |                 | sparsity is      |                  |
    |                  |                 | completely       |                  |
    |                  |                 | ignored and      |                  |
    |                  |                 | dense matrices   |                  |
    |                  |                 | are used.        |                  |
    +------------------+-----------------+------------------+------------------+
    | always_inline    | OT_BOOL         | Force inlining.  | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | cache            | OT_DICT         | Prepopulate the  | casadi::Function |
    |                  |                 | function cache.  | Internal         |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | compiler         | OT_STRING       | Just-in-time     | casadi::Function |
    |                  |                 | compiler plugin  | Internal         |
    |                  |                 | to be used.      |                  |
    +------------------+-----------------+------------------+------------------+
    | const_A          | OT_BOOL         | Assume A is      | casadi::Expm     |
    |                  |                 | constant.        |                  |
    |                  |                 | Default: false.  |                  |
    +------------------+-----------------+------------------+------------------+
    | custom_jacobian  | OT_FUNCTION     | Override         | casadi::Function |
    |                  |                 | CasADi's AD. Use | Internal         |
    |                  |                 | together with    |                  |
    |                  |                 | 'jac_penalty':   |                  |
    |                  |                 | 0. Note: Highly  |                  |
    |                  |                 | experimental.    |                  |
    |                  |                 | Syntax may break |                  |
    |                  |                 | often.           |                  |
    +------------------+-----------------+------------------+------------------+
    | der_options      | OT_DICT         | Default options  | casadi::Function |
    |                  |                 | to be used to    | Internal         |
    |                  |                 | populate         |                  |
    |                  |                 | forward_options, |                  |
    |                  |                 | reverse_options, |                  |
    |                  |                 | and              |                  |
    |                  |                 | jacobian_options |                  |
    |                  |                 | before those     |                  |
    |                  |                 | options are      |                  |
    |                  |                 | merged in.       |                  |
    +------------------+-----------------+------------------+------------------+
    | derivative_of    | OT_FUNCTION     | The function is  | casadi::Function |
    |                  |                 | a derivative of  | Internal         |
    |                  |                 | another          |                  |
    |                  |                 | function. The    |                  |
    |                  |                 | type of          |                  |
    |                  |                 | derivative       |                  |
    |                  |                 | (directional     |                  |
    |                  |                 | derivative,      |                  |
    |                  |                 | Jacobian) is     |                  |
    |                  |                 | inferred from    |                  |
    |                  |                 | the function     |                  |
    |                  |                 | name.            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump             | OT_BOOL         | Dump function to | casadi::Function |
    |                  |                 | file upon first  | Internal         |
    |                  |                 | evaluation.      |                  |
    |                  |                 | [false]          |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_dir         | OT_STRING       | Directory to     | casadi::Function |
    |                  |                 | dump             | Internal         |
    |                  |                 | inputs/outputs   |                  |
    |                  |                 | to. Make sure    |                  |
    |                  |                 | the directory    |                  |
    |                  |                 | exists [.]       |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_format      | OT_STRING       | Choose file      | casadi::Function |
    |                  |                 | format to dump   | Internal         |
    |                  |                 | matrices. See    |                  |
    |                  |                 | DM.from_file     |                  |
    |                  |                 | [mtx]            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_in          | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | to file          |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_out         | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs to file  |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_fd        | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation by   |                  |
    |                  |                 | finite           |                  |
    |                  |                 | differencing.    |                  |
    |                  |                 | [default:        |                  |
    |                  |                 | false]]          |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_forward   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using forward    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_jacobian  | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobians of all |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | outputs with     |                  |
    |                  |                 | respect to all   |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | inputs - if      |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_reverse   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | transposed       |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using reverse    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | error_on_fail    | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when function    | ction            |
    |                  |                 | evaluation fails |                  |
    |                  |                 | (default true).  |                  |
    +------------------+-----------------+------------------+------------------+
    | external_transfo | OT_VECTORVECTOR | List of external | casadi::Function |
    | rm               |                 | _transform       | Internal         |
    |                  |                 | instruction      |                  |
    |                  |                 | arguments.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_method        | OT_STRING       | Method for       | casadi::Function |
    |                  |                 | finite           | Internal         |
    |                  |                 | differencing     |                  |
    |                  |                 | [default         |                  |
    |                  |                 | 'central']       |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_options       | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | finite           |                  |
    |                  |                 | difference       |                  |
    |                  |                 | instance         |                  |
    +------------------+-----------------+------------------+------------------+
    | forward_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | forward mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | gather_stats     | OT_BOOL         | Deprecated       | casadi::Function |
    |                  |                 | option           | Internal         |
    |                  |                 | (ignored):       |                  |
    |                  |                 | Statistics are   |                  |
    |                  |                 | now always       |                  |
    |                  |                 | collected.       |                  |
    +------------------+-----------------+------------------+------------------+
    | input_scheme     | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | inputs_check     | OT_BOOL         | Throw exceptions | casadi::Function |
    |                  |                 | when the         | Internal         |
    |                  |                 | numerical values |                  |
    |                  |                 | of the inputs    |                  |
    |                  |                 | don't make sense |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_in       | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each input if it | Internal         |
    |                  |                 | should be        |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_out      | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each output if   | Internal         |
    |                  |                 | it should be     |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | jac_penalty      | OT_DOUBLE       | When requested   | casadi::Function |
    |                  |                 | for a number of  | Internal         |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | directions, it   |                  |
    |                  |                 | may be cheaper   |                  |
    |                  |                 | to compute first |                  |
    |                  |                 | the full         |                  |
    |                  |                 | jacobian and     |                  |
    |                  |                 | then multiply    |                  |
    |                  |                 | with seeds,      |                  |
    |                  |                 | rather than      |                  |
    |                  |                 | obtain the       |                  |
    |                  |                 | requested        |                  |
    |                  |                 | directions in a  |                  |
    |                  |                 | straightforward  |                  |
    |                  |                 | manner. Casadi   |                  |
    |                  |                 | uses a heuristic |                  |
    |                  |                 | to decide which  |                  |
    |                  |                 | is cheaper. A    |                  |
    |                  |                 | high value of    |                  |
    |                  |                 | 'jac_penalty'    |                  |
    |                  |                 | makes it less    |                  |
    |                  |                 | likely for the   |                  |
    |                  |                 | heurstic to      |                  |
    |                  |                 | chose the full   |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy. The    |                  |
    |                  |                 | special value -1 |                  |
    |                  |                 | indicates never  |                  |
    |                  |                 | to use the full  |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy         |                  |
    +------------------+-----------------+------------------+------------------+
    | jacobian_options | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | Jacobian         |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | jit              | OT_BOOL         | Use just-in-time | casadi::Function |
    |                  |                 | compiler to      | Internal         |
    |                  |                 | speed up the     |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_cleanup      | OT_BOOL         | Cleanup up the   | casadi::Function |
    |                  |                 | temporary source | Internal         |
    |                  |                 | file that jit    |                  |
    |                  |                 | creates.         |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_name         | OT_STRING       | The file name    | casadi::Function |
    |                  |                 | used to write    | Internal         |
    |                  |                 | out code. The    |                  |
    |                  |                 | actual file      |                  |
    |                  |                 | names used       |                  |
    |                  |                 | depend on 'jit_t |                  |
    |                  |                 | emp_suffix' and  |                  |
    |                  |                 | include          |                  |
    |                  |                 | extensions.      |                  |
    |                  |                 | Default:         |                  |
    |                  |                 | 'jit_tmp'        |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_options      | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | jit compiler.    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_serialize    | OT_STRING       | Specify          | casadi::Function |
    |                  |                 | behaviour when   | Internal         |
    |                  |                 | serializing a    |                  |
    |                  |                 | jitted function: |                  |
    |                  |                 | SOURCE|link|embe |                  |
    |                  |                 | d.               |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_temp_suffix  | OT_BOOL         | Use a temporary  | casadi::Function |
    |                  |                 | (seemingly       | Internal         |
    |                  |                 | random) filename |                  |
    |                  |                 | suffix for       |                  |
    |                  |                 | generated code   |                  |
    |                  |                 | and libraries.   |                  |
    |                  |                 | This is desired  |                  |
    |                  |                 | for thread-      |                  |
    |                  |                 | safety. This     |                  |
    |                  |                 | behaviour may    |                  |
    |                  |                 | defeat caching   |                  |
    |                  |                 | compiler         |                  |
    |                  |                 | wrappers.        |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | max_io           | OT_INT          | Acceptable       | casadi::Function |
    |                  |                 | number of inputs | Internal         |
    |                  |                 | and outputs.     |                  |
    |                  |                 | Warn if          |                  |
    |                  |                 | exceeded.        |                  |
    +------------------+-----------------+------------------+------------------+
    | max_num_dir      | OT_INT          | Specify the      | casadi::Function |
    |                  |                 | maximum number   | Internal         |
    |                  |                 | of directions    |                  |
    |                  |                 | for derivative   |                  |
    |                  |                 | functions.       |                  |
    |                  |                 | Overrules the    |                  |
    |                  |                 | builtin optimize |                  |
    |                  |                 | d_num_dir.       |                  |
    +------------------+-----------------+------------------+------------------+
    | never_inline     | OT_BOOL         | Forbid inlining. | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | output_scheme    | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | post_expand      | OT_BOOL         | After            | casadi::Function |
    |                  |                 | construction,    | Internal         |
    |                  |                 | expand this      |                  |
    |                  |                 | Function .       |                  |
    |                  |                 | Default: False   |                  |
    +------------------+-----------------+------------------+------------------+
    | post_expand_opti | OT_DICT         | Options to be    | casadi::Function |
    | ons              |                 | passed to post-  | Internal         |
    |                  |                 | construction     |                  |
    |                  |                 | expansion.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | print_canonical  | OT_BOOL         | When printing    | casadi::Function |
    |                  |                 | numerical        | Internal         |
    |                  |                 | matrices, use a  |                  |
    |                  |                 | format that is   |                  |
    |                  |                 | exact and        |                  |
    |                  |                 | reproducible in  |                  |
    |                  |                 | generated C      |                  |
    |                  |                 | code.            |                  |
    +------------------+-----------------+------------------+------------------+
    | print_in         | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_out        | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs          |                  |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_time       | OT_BOOL         | print            | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time. Implies    |                  |
    |                  |                 | record_time.     |                  |
    +------------------+-----------------+------------------+------------------+
    | record_time      | OT_BOOL         | record           | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time, for        |                  |
    |                  |                 | retrieval with   |                  |
    |                  |                 | stats().         |                  |
    +------------------+-----------------+------------------+------------------+
    | regularity_check | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when NaN or Inf  | ction            |
    |                  |                 | appears during   |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | reverse_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | reverse mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | user_data        | OT_VOIDPTR      | A user-defined   | casadi::Function |
    |                  |                 | field that can   | Internal         |
    |                  |                 | be used to       |                  |
    |                  |                 | identify the     |                  |
    |                  |                 | function or pass |                  |
    |                  |                 | additional       |                  |
    |                  |                 | information      |                  |
    +------------------+-----------------+------------------+------------------+
    | verbose          | OT_BOOL         | Verbose          | casadi::ProtoFun |
    |                  |                 | evaluation  for  | ction            |
    |                  |                 | debugging        |                  |
    +------------------+-----------------+------------------+------------------+

    List of plugins
    - slicot

    Note: some of the plugins in this list might not be available on your 

    system.  Also, there might be extra plugins available to you that are 
    not 
    listed here. You can obtain their documentation with  
    Expm.doc("myextraplugin")



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

    slicot
    ------



    Extra doc: https://github.com/casadi/casadi/wiki/L_22l

    Joris Gillis

    Extra doc: https://github.com/casadi/casadi/wiki/L_21l

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/expm.hpp#L44

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/expm.cpp#L44-L47



    """
    return _casadi.expmsol(*args)

def expm_n_in(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      expm_n_in() -> int

    Get the number of expm solver inputs.

    Extra doc: https://github.com/casadi/casadi/wiki/L_rs

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/expm.hpp#L49

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/expm.cpp#L49-L51



    """
    return _casadi.expm_n_in(*args)

def expm_n_out(*args) -> "casadi_int":
    """
      [INTERNAL] 

    ::

      expm_n_out() -> int

    Get the number of expm solver outputs.

    Extra doc: https://github.com/casadi/casadi/wiki/L_rt

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/expm.hpp#L53

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/expm.cpp#L53-L55



    """
    return _casadi.expm_n_out(*args)

def has_expm(*args) -> "bool":
    """
      [INTERNAL] 

    ::

      has_expm(str name) -> bool

    Check if a particular plugin is available.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/expm.hpp#L32

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/expm.cpp#L32-L34



    """
    return _casadi.has_expm(*args)

def load_expm(*args) -> "void":
    """
      [INTERNAL] 

    ::

      load_expm(str name)

    Explicitly load a plugin dynamically.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/expm.hpp#L36

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/expm.cpp#L36-L38



    """
    return _casadi.load_expm(*args)

def doc_expm(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      doc_expm(str name) -> str

    Get the documentation string for a plugin.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/expm.hpp#L40

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/expm.cpp#L40-L42



    """
    return _casadi.doc_expm(*args)

def interpolant(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      interpolant(str name, str solver, [[float]] grid, int m, dict opts) -> Function
      interpolant(str name, str solver, [int] grid_dims, int m, dict opts) -> Function
      interpolant(str name, str solver, [[float]] grid, [float] values, dict opts) -> Function
      interpolant(str name, str solver, [int] grid_dims, [float] values, dict opts) -> Function

    Parametric variant of interpolant.

    The resulting function will have an additional argument for the grid

    By default, derivatives wrt the coefficients are not supported (zero).
     Some
     interpolant plugins may support the  inline=true which enables correct 
    derivatives

    Extra doc: https://github.com/casadi/casadi/wiki/L_1p5

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.hpp#L171

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.cpp#L171-L187



    .......

    ::

      interpolant(str name, str solver, [[float]] grid, [float] values, dict opts)



    [INTERNAL]

    An interpolant function for lookup table data

    Parameters:
    -----------

    name: 
    label for the resulting  Function

    solver: 
    name of the plugin

    grid: 
    collection of 1D grids whose outer product defines the full N-D 

    rectangular grid

    values: 
    flattened vector of all values for all gridpoints

    Syntax 1D

    ::

      * # Python
      * xgrid = np.linspace(1,6,6)
      * V = [-1,-1,-2,-3,0,2]
      * LUT = casadi.interpolant("LUT","bspline",[xgrid],V)
      * print(LUT(2.5))
      * 



    ::

      * % Matlab
      * xgrid = 1:6;
      * V = [-1 -1 -2 -3 0 2];
      * LUT = casadi.interpolant('LUT','bspline',{xgrid},V);
      * LUT(2.5)
      * 



    Syntax 2D

    ::

      * # Python
      * xgrid = np.linspace(-5,5,11)
      * ygrid = np.linspace(-4,4,9)
      * X,Y = np.meshgrid(xgrid,ygrid,indexing='ij')
      * R = np.sqrt(5*X**2 + Y**2)+ 1
      * data = np.sin(R)/R
      * data_flat = data.ravel(order='F')
      * LUT = casadi.interpolant('name','bspline',[xgrid,ygrid],data_flat)
      * print(LUT([0.5,1]))
      * \\enverbatim
      * \\verbatim
      * % Matlab
      * xgrid = -5:1:5;
      * ygrid = -4:1:4;
      * R = sqrt(5*X.^2 + Y.^2)+ 1;
      * V = sin(R)./(R);
      * LUT = interpolant('LUT','bspline',{xgrid, ygrid},V(:));
      * LUT([0.5 1])
      * 

    General information

    >List of available options

    +------------------+-----------------+------------------+------------------+
    |        Id        |      Type       |   Description    |     Used in      |
    +==================+=================+==================+==================+
    | ad_weight        | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for derivative   | Internal         |
    |                  |                 | calculation.When |                  |
    |                  |                 | there is an      |                  |
    |                  |                 | option of either |                  |
    |                  |                 | using forward or |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | directional      |                  |
    |                  |                 | derivatives, the |                  |
    |                  |                 | condition ad_wei |                  |
    |                  |                 | ght*nf<=(1-      |                  |
    |                  |                 | ad_weight)*na is |                  |
    |                  |                 | used where nf    |                  |
    |                  |                 | and na are       |                  |
    |                  |                 | estimates of the |                  |
    |                  |                 | number of        |                  |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | mode directional |                  |
    |                  |                 | derivatives      |                  |
    |                  |                 | needed. By       |                  |
    |                  |                 | default,         |                  |
    |                  |                 | ad_weight is     |                  |
    |                  |                 | calculated       |                  |
    |                  |                 | automatically,   |                  |
    |                  |                 | but this can be  |                  |
    |                  |                 | overridden by    |                  |
    |                  |                 | setting this     |                  |
    |                  |                 | option. In       |                  |
    |                  |                 | particular, 0    |                  |
    |                  |                 | means forcing    |                  |
    |                  |                 | forward mode and |                  |
    |                  |                 | 1 forcing        |                  |
    |                  |                 | reverse mode.    |                  |
    |                  |                 | Leave unset for  |                  |
    |                  |                 | (class specific) |                  |
    |                  |                 | heuristics.      |                  |
    +------------------+-----------------+------------------+------------------+
    | ad_weight_sp     | OT_DOUBLE       | Weighting factor | casadi::Function |
    |                  |                 | for sparsity     | Internal         |
    |                  |                 | pattern          |                  |
    |                  |                 | calculation calc |                  |
    |                  |                 | ulation.Override |                  |
    |                  |                 | s default        |                  |
    |                  |                 | behavior. Set to |                  |
    |                  |                 | 0 and 1 to force |                  |
    |                  |                 | forward and      |                  |
    |                  |                 | reverse mode     |                  |
    |                  |                 | respectively.    |                  |
    |                  |                 | Cf. option       |                  |
    |                  |                 | "ad_weight".     |                  |
    |                  |                 | When set to -1,  |                  |
    |                  |                 | sparsity is      |                  |
    |                  |                 | completely       |                  |
    |                  |                 | ignored and      |                  |
    |                  |                 | dense matrices   |                  |
    |                  |                 | are used.        |                  |
    +------------------+-----------------+------------------+------------------+
    | always_inline    | OT_BOOL         | Force inlining.  | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | batch_x          | OT_INT          | Evaluate a batch | casadi::Interpol |
    |                  |                 | of different     | ant              |
    |                  |                 | inputs at once   |                  |
    |                  |                 | (default 1).     |                  |
    +------------------+-----------------+------------------+------------------+
    | cache            | OT_DICT         | Prepopulate the  | casadi::Function |
    |                  |                 | function cache.  | Internal         |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | compiler         | OT_STRING       | Just-in-time     | casadi::Function |
    |                  |                 | compiler plugin  | Internal         |
    |                  |                 | to be used.      |                  |
    +------------------+-----------------+------------------+------------------+
    | custom_jacobian  | OT_FUNCTION     | Override         | casadi::Function |
    |                  |                 | CasADi's AD. Use | Internal         |
    |                  |                 | together with    |                  |
    |                  |                 | 'jac_penalty':   |                  |
    |                  |                 | 0. Note: Highly  |                  |
    |                  |                 | experimental.    |                  |
    |                  |                 | Syntax may break |                  |
    |                  |                 | often.           |                  |
    +------------------+-----------------+------------------+------------------+
    | der_options      | OT_DICT         | Default options  | casadi::Function |
    |                  |                 | to be used to    | Internal         |
    |                  |                 | populate         |                  |
    |                  |                 | forward_options, |                  |
    |                  |                 | reverse_options, |                  |
    |                  |                 | and              |                  |
    |                  |                 | jacobian_options |                  |
    |                  |                 | before those     |                  |
    |                  |                 | options are      |                  |
    |                  |                 | merged in.       |                  |
    +------------------+-----------------+------------------+------------------+
    | derivative_of    | OT_FUNCTION     | The function is  | casadi::Function |
    |                  |                 | a derivative of  | Internal         |
    |                  |                 | another          |                  |
    |                  |                 | function. The    |                  |
    |                  |                 | type of          |                  |
    |                  |                 | derivative       |                  |
    |                  |                 | (directional     |                  |
    |                  |                 | derivative,      |                  |
    |                  |                 | Jacobian) is     |                  |
    |                  |                 | inferred from    |                  |
    |                  |                 | the function     |                  |
    |                  |                 | name.            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump             | OT_BOOL         | Dump function to | casadi::Function |
    |                  |                 | file upon first  | Internal         |
    |                  |                 | evaluation.      |                  |
    |                  |                 | [false]          |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_dir         | OT_STRING       | Directory to     | casadi::Function |
    |                  |                 | dump             | Internal         |
    |                  |                 | inputs/outputs   |                  |
    |                  |                 | to. Make sure    |                  |
    |                  |                 | the directory    |                  |
    |                  |                 | exists [.]       |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_format      | OT_STRING       | Choose file      | casadi::Function |
    |                  |                 | format to dump   | Internal         |
    |                  |                 | matrices. See    |                  |
    |                  |                 | DM.from_file     |                  |
    |                  |                 | [mtx]            |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_in          | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | to file          |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | dump_out         | OT_BOOL         | Dump numerical   | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs to file  |                  |
    |                  |                 | (readable with   |                  |
    |                  |                 | DM.from_file )   |                  |
    |                  |                 | [default: false] |                  |
    |                  |                 | A counter is     |                  |
    |                  |                 | used to generate |                  |
    |                  |                 | unique names.    |                  |
    |                  |                 | The counter may  |                  |
    |                  |                 | be reset using r |                  |
    |                  |                 | eset_dump_count. |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_fd        | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation by   |                  |
    |                  |                 | finite           |                  |
    |                  |                 | differencing.    |                  |
    |                  |                 | [default:        |                  |
    |                  |                 | false]]          |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_forward   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using forward    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_jacobian  | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | Jacobians of all |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | outputs with     |                  |
    |                  |                 | respect to all   |                  |
    |                  |                 | differentiable   |                  |
    |                  |                 | inputs - if      |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | enable_reverse   | OT_BOOL         | Enable           | casadi::Function |
    |                  |                 | derivative       | Internal         |
    |                  |                 | calculation      |                  |
    |                  |                 | using generated  |                  |
    |                  |                 | functions for    |                  |
    |                  |                 | transposed       |                  |
    |                  |                 | Jacobian-times-  |                  |
    |                  |                 | vector products  |                  |
    |                  |                 | - typically      |                  |
    |                  |                 | using reverse    |                  |
    |                  |                 | mode AD - if     |                  |
    |                  |                 | available.       |                  |
    |                  |                 | [default: true]  |                  |
    +------------------+-----------------+------------------+------------------+
    | error_on_fail    | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when function    | ction            |
    |                  |                 | evaluation fails |                  |
    |                  |                 | (default true).  |                  |
    +------------------+-----------------+------------------+------------------+
    | external_transfo | OT_VECTORVECTOR | List of external | casadi::Function |
    | rm               |                 | _transform       | Internal         |
    |                  |                 | instruction      |                  |
    |                  |                 | arguments.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_method        | OT_STRING       | Method for       | casadi::Function |
    |                  |                 | finite           | Internal         |
    |                  |                 | differencing     |                  |
    |                  |                 | [default         |                  |
    |                  |                 | 'central']       |                  |
    +------------------+-----------------+------------------+------------------+
    | fd_options       | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | finite           |                  |
    |                  |                 | difference       |                  |
    |                  |                 | instance         |                  |
    +------------------+-----------------+------------------+------------------+
    | forward_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | forward mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | gather_stats     | OT_BOOL         | Deprecated       | casadi::Function |
    |                  |                 | option           | Internal         |
    |                  |                 | (ignored):       |                  |
    |                  |                 | Statistics are   |                  |
    |                  |                 | now always       |                  |
    |                  |                 | collected.       |                  |
    +------------------+-----------------+------------------+------------------+
    | inline           | OT_BOOL         | Implement the    | casadi::Interpol |
    |                  |                 | lookup table in  | ant              |
    |                  |                 | MX primitives.   |                  |
    |                  |                 | Useful when you  |                  |
    |                  |                 | need derivatives |                  |
    |                  |                 | with respect to  |                  |
    |                  |                 | grid and/or      |                  |
    |                  |                 | coefficients.    |                  |
    |                  |                 | Such derivatives |                  |
    |                  |                 | are              |                  |
    |                  |                 | fundamentally    |                  |
    |                  |                 | dense, so use    |                  |
    |                  |                 | with caution.    |                  |
    +------------------+-----------------+------------------+------------------+
    | input_scheme     | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | inputs_check     | OT_BOOL         | Throw exceptions | casadi::Function |
    |                  |                 | when the         | Internal         |
    |                  |                 | numerical values |                  |
    |                  |                 | of the inputs    |                  |
    |                  |                 | don't make sense |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_in       | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each input if it | Internal         |
    |                  |                 | should be        |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | is_diff_out      | OT_BOOLVECTOR   | Indicate for     | casadi::Function |
    |                  |                 | each output if   | Internal         |
    |                  |                 | it should be     |                  |
    |                  |                 | differentiable.  |                  |
    +------------------+-----------------+------------------+------------------+
    | jac_penalty      | OT_DOUBLE       | When requested   | casadi::Function |
    |                  |                 | for a number of  | Internal         |
    |                  |                 | forward/reverse  |                  |
    |                  |                 | directions, it   |                  |
    |                  |                 | may be cheaper   |                  |
    |                  |                 | to compute first |                  |
    |                  |                 | the full         |                  |
    |                  |                 | jacobian and     |                  |
    |                  |                 | then multiply    |                  |
    |                  |                 | with seeds,      |                  |
    |                  |                 | rather than      |                  |
    |                  |                 | obtain the       |                  |
    |                  |                 | requested        |                  |
    |                  |                 | directions in a  |                  |
    |                  |                 | straightforward  |                  |
    |                  |                 | manner. Casadi   |                  |
    |                  |                 | uses a heuristic |                  |
    |                  |                 | to decide which  |                  |
    |                  |                 | is cheaper. A    |                  |
    |                  |                 | high value of    |                  |
    |                  |                 | 'jac_penalty'    |                  |
    |                  |                 | makes it less    |                  |
    |                  |                 | likely for the   |                  |
    |                  |                 | heurstic to      |                  |
    |                  |                 | chose the full   |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy. The    |                  |
    |                  |                 | special value -1 |                  |
    |                  |                 | indicates never  |                  |
    |                  |                 | to use the full  |                  |
    |                  |                 | Jacobian         |                  |
    |                  |                 | strategy         |                  |
    +------------------+-----------------+------------------+------------------+
    | jacobian_options | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | Jacobian         |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | jit              | OT_BOOL         | Use just-in-time | casadi::Function |
    |                  |                 | compiler to      | Internal         |
    |                  |                 | speed up the     |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_cleanup      | OT_BOOL         | Cleanup up the   | casadi::Function |
    |                  |                 | temporary source | Internal         |
    |                  |                 | file that jit    |                  |
    |                  |                 | creates.         |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_name         | OT_STRING       | The file name    | casadi::Function |
    |                  |                 | used to write    | Internal         |
    |                  |                 | out code. The    |                  |
    |                  |                 | actual file      |                  |
    |                  |                 | names used       |                  |
    |                  |                 | depend on 'jit_t |                  |
    |                  |                 | emp_suffix' and  |                  |
    |                  |                 | include          |                  |
    |                  |                 | extensions.      |                  |
    |                  |                 | Default:         |                  |
    |                  |                 | 'jit_tmp'        |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_options      | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to the    | Internal         |
    |                  |                 | jit compiler.    |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_serialize    | OT_STRING       | Specify          | casadi::Function |
    |                  |                 | behaviour when   | Internal         |
    |                  |                 | serializing a    |                  |
    |                  |                 | jitted function: |                  |
    |                  |                 | SOURCE|link|embe |                  |
    |                  |                 | d.               |                  |
    +------------------+-----------------+------------------+------------------+
    | jit_temp_suffix  | OT_BOOL         | Use a temporary  | casadi::Function |
    |                  |                 | (seemingly       | Internal         |
    |                  |                 | random) filename |                  |
    |                  |                 | suffix for       |                  |
    |                  |                 | generated code   |                  |
    |                  |                 | and libraries.   |                  |
    |                  |                 | This is desired  |                  |
    |                  |                 | for thread-      |                  |
    |                  |                 | safety. This     |                  |
    |                  |                 | behaviour may    |                  |
    |                  |                 | defeat caching   |                  |
    |                  |                 | compiler         |                  |
    |                  |                 | wrappers.        |                  |
    |                  |                 | Default: true    |                  |
    +------------------+-----------------+------------------+------------------+
    | lookup_mode      | OT_STRINGVECTOR | Specifies, for   | casadi::Interpol |
    |                  |                 | each grid        | ant              |
    |                  |                 | dimension, the   |                  |
    |                  |                 | lookup algorithm |                  |
    |                  |                 | used to find the |                  |
    |                  |                 | correct index.   |                  |
    |                  |                 | 'linear' uses a  |                  |
    |                  |                 | for-loop +       |                  |
    |                  |                 | break; (default  |                  |
    |                  |                 | when             |                  |
    |                  |                 | #knots<=100),    |                  |
    |                  |                 | 'exact' uses     |                  |
    |                  |                 | floored division |                  |
    |                  |                 | (only for        |                  |
    |                  |                 | uniform grids),  |                  |
    |                  |                 | 'binary' uses a  |                  |
    |                  |                 | binary search.   |                  |
    |                  |                 | (default when    |                  |
    |                  |                 | #knots>100).     |                  |
    +------------------+-----------------+------------------+------------------+
    | max_io           | OT_INT          | Acceptable       | casadi::Function |
    |                  |                 | number of inputs | Internal         |
    |                  |                 | and outputs.     |                  |
    |                  |                 | Warn if          |                  |
    |                  |                 | exceeded.        |                  |
    +------------------+-----------------+------------------+------------------+
    | max_num_dir      | OT_INT          | Specify the      | casadi::Function |
    |                  |                 | maximum number   | Internal         |
    |                  |                 | of directions    |                  |
    |                  |                 | for derivative   |                  |
    |                  |                 | functions.       |                  |
    |                  |                 | Overrules the    |                  |
    |                  |                 | builtin optimize |                  |
    |                  |                 | d_num_dir.       |                  |
    +------------------+-----------------+------------------+------------------+
    | never_inline     | OT_BOOL         | Forbid inlining. | casadi::Function |
    |                  |                 |                  | Internal         |
    +------------------+-----------------+------------------+------------------+
    | output_scheme    | OT_STRINGVECTOR | Deprecated       | casadi::Function |
    |                  |                 | option (ignored) | Internal         |
    +------------------+-----------------+------------------+------------------+
    | post_expand      | OT_BOOL         | After            | casadi::Function |
    |                  |                 | construction,    | Internal         |
    |                  |                 | expand this      |                  |
    |                  |                 | Function .       |                  |
    |                  |                 | Default: False   |                  |
    +------------------+-----------------+------------------+------------------+
    | post_expand_opti | OT_DICT         | Options to be    | casadi::Function |
    | ons              |                 | passed to post-  | Internal         |
    |                  |                 | construction     |                  |
    |                  |                 | expansion.       |                  |
    |                  |                 | Default: empty   |                  |
    +------------------+-----------------+------------------+------------------+
    | print_canonical  | OT_BOOL         | When printing    | casadi::Function |
    |                  |                 | numerical        | Internal         |
    |                  |                 | matrices, use a  |                  |
    |                  |                 | format that is   |                  |
    |                  |                 | exact and        |                  |
    |                  |                 | reproducible in  |                  |
    |                  |                 | generated C      |                  |
    |                  |                 | code.            |                  |
    +------------------+-----------------+------------------+------------------+
    | print_in         | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of inputs | Internal         |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_out        | OT_BOOL         | Print numerical  | casadi::Function |
    |                  |                 | values of        | Internal         |
    |                  |                 | outputs          |                  |
    |                  |                 | [default: false] |                  |
    +------------------+-----------------+------------------+------------------+
    | print_time       | OT_BOOL         | print            | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time. Implies    |                  |
    |                  |                 | record_time.     |                  |
    +------------------+-----------------+------------------+------------------+
    | record_time      | OT_BOOL         | record           | casadi::ProtoFun |
    |                  |                 | information      | ction            |
    |                  |                 | about execution  |                  |
    |                  |                 | time, for        |                  |
    |                  |                 | retrieval with   |                  |
    |                  |                 | stats().         |                  |
    +------------------+-----------------+------------------+------------------+
    | regularity_check | OT_BOOL         | Throw exceptions | casadi::ProtoFun |
    |                  |                 | when NaN or Inf  | ction            |
    |                  |                 | appears during   |                  |
    |                  |                 | evaluation       |                  |
    +------------------+-----------------+------------------+------------------+
    | reverse_options  | OT_DICT         | Options to be    | casadi::Function |
    |                  |                 | passed to a      | Internal         |
    |                  |                 | reverse mode     |                  |
    |                  |                 | constructor      |                  |
    +------------------+-----------------+------------------+------------------+
    | user_data        | OT_VOIDPTR      | A user-defined   | casadi::Function |
    |                  |                 | field that can   | Internal         |
    |                  |                 | be used to       |                  |
    |                  |                 | identify the     |                  |
    |                  |                 | function or pass |                  |
    |                  |                 | additional       |                  |
    |                  |                 | information      |                  |
    +------------------+-----------------+------------------+------------------+
    | verbose          | OT_BOOL         | Verbose          | casadi::ProtoFun |
    |                  |                 | evaluation  for  | ction            |
    |                  |                 | debugging        |                  |
    +------------------+-----------------+------------------+------------------+

    List of plugins
    - bspline

    - linear

    Note: some of the plugins in this list might not be available on your 

    system.  Also, there might be extra plugins available to you that are 
    not 
    listed here. You can obtain their documentation with  
    Interpolant.doc("myextraplugin")



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

    bspline
    -------



    Extra doc: https://github.com/casadi/casadi/wiki/L_239

    >List of available options

    +-----------------------+--------------+-----------------------------------+
    |          Id           |     Type     |            Description            |
    +=======================+==============+===================================+
    | algorithm             | OT_STRING    | Algorithm used for fitting the    |
    |                       |              | data: 'not_a_knot' (default, same |
    |                       |              | as Matlab), 'smooth_linear'.      |
    +-----------------------+--------------+-----------------------------------+
    | degree                | OT_INTVECTOR | Sets, for each grid dimension,    |
    |                       |              | the degree of the spline.         |
    +-----------------------+--------------+-----------------------------------+
    | linear_solver         | OT_STRING    | Solver used for constructing the  |
    |                       |              | coefficient tensor.               |
    +-----------------------+--------------+-----------------------------------+
    | linear_solver_options | OT_DICT      | Options to be passed to the       |
    |                       |              | linear solver.                    |
    +-----------------------+--------------+-----------------------------------+
    | smooth_linear_frac    | OT_DOUBLE    | When 'smooth_linear' algorithm is |
    |                       |              | active, determines sharpness      |
    |                       |              | between 0 (sharp, as linear       |
    |                       |              | interpolation) and 0.5            |
    |                       |              | (smooth).Default value is 0.1.    |
    +-----------------------+--------------+-----------------------------------+



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

    linear
    ------



    Extra doc: https://github.com/casadi/casadi/wiki/L_23b

    >List of available options

    +-------------+-----------------+------------------------------------------+
    |     Id      |      Type       |               Description                |
    +=============+=================+==========================================+
    | lookup_mode | OT_STRINGVECTOR | Sets, for each grid dimenion, the lookup |
    |             |                 | algorithm used to find the correct       |
    |             |                 | index. 'linear' uses a for-loop + break; |
    |             |                 | 'exact' uses floored division (only for  |
    |             |                 | uniform grids).                          |
    +-------------+-----------------+------------------------------------------+

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_21p

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.hpp#L125

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.cpp#L125-L147



    .............


    .......

    ::

      interpolant(str name, str solver, [[float]] grid, int m, dict opts)



    [INTERNAL] 
    Parametric variant of interpolant.

    The resulting function will have an additional argument for the 

    coefficients

    By default, derivatives wrt the coefficients are not supported (zero).
     Some
     interpolant plugins may support the  inline=true which enables correct 
    derivatives

    Extra doc: https://github.com/casadi/casadi/wiki/L_1p3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.hpp#L189

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.cpp#L189-L203



    .............


    .......

    ::

      interpolant(str name, str solver, [int] grid_dims, int m, dict opts)



    [INTERNAL] 
    Parametric variant of interpolant.

    The resulting function will have additional arguments for the grid and

    coefficients

    By default, derivatives wrt the coefficients are not supported (zero).
     Some
     interpolant plugins may support the  inline=true which enables correct 
    derivatives

    Extra doc: https://github.com/casadi/casadi/wiki/L_1p4

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.hpp#L205

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.cpp#L205-L213



    .............


    .......

    ::

      interpolant(str name, str solver, [int] grid_dims, [float] values, dict opts)



    [INTERNAL] 
    Parametric variant of interpolant.

    The resulting function will have an additional argument for the grid

    By default, derivatives wrt the coefficients are not supported (zero).
     Some
     interpolant plugins may support the  inline=true which enables correct 
    derivatives

    Extra doc: https://github.com/casadi/casadi/wiki/L_1p5

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.hpp#L171

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.cpp#L171-L187



    .............



    """
    return _casadi.interpolant(*args)

def has_interpolant(*args) -> "bool":
    """
      [INTERNAL] 

    ::

      has_interpolant(str name) -> bool

    Check if a particular plugin is available.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.hpp#L34

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.cpp#L34-L36




    """
    return _casadi.has_interpolant(*args)

def load_interpolant(*args) -> "void":
    """
      [INTERNAL] 

    ::

      load_interpolant(str name)

    Explicitly load a plugin dynamically.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.hpp#L38

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.cpp#L38-L40




    """
    return _casadi.load_interpolant(*args)

def doc_interpolant(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      doc_interpolant(str name) -> str

    Get the documentation string for a plugin.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.hpp#L42

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/interpolant.cpp#L42-L44




    """
    return _casadi.doc_interpolant(*args)

def blazing_spline(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      blazing_spline(str name, [[float]] knots, dict opts) -> Function

    Construct a specialized parametric BSpline.

    Specialized in these ways:
    order 3 is assumed

    up to dimension 3 supported

    a single scalar output (m=1)

    Extra doc: https://github.com/casadi/casadi/wiki/L_2b9

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/blazing_spline.hpp#L38

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/blazing_spline.cpp#L38-L42




    """
    return _casadi.blazing_spline(*args)
class CodeGenerator(_object):
    """
      [INTERNAL] 

    ::


    Helper class for C code generation.

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_ru

    C++ includes: code_generator.hpp



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, CodeGenerator, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, CodeGenerator, name)
    __repr__ = _swig_repr

    def __init__(self, *args):
        """
          [INTERNAL] 

        ::

          CodeGenerator(str name, dict opts)

        Constructor.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/code_generator.hpp#L46

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/code_generator.cpp#L37-L201




        """
        this = _casadi.new_CodeGenerator(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this

    def add(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          add(self, Function f, bool with_jac_sparsity)

        Add a function (name generated)

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/code_generator.hpp#L49

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/code_generator.cpp#L331-L374




        """
        return _casadi.CodeGenerator_add(self, *args)


    def dump(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          dump(self) -> str

        Generate a file, return code as string.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/code_generator.hpp#L57

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/code_generator.cpp#L376-L380




        """
        return _casadi.CodeGenerator_dump(self, *args)


    def generate(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          generate(self, str prefix) -> str

        Generate file(s)

        The "prefix" argument will be prepended to the generated files and 
        may be
         a directory or a file prefix. returns the filename

        Extra doc: https://github.com/casadi/casadi/wiki/L_rv

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/code_generator.hpp#L66

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/code_generator.cpp#L468-L533




        """
        return _casadi.CodeGenerator_generate(self, *args)


    def add_include(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          add_include(self, str new_include, bool relative_path, str use_ifdef)

        Add an include file optionally using a relative path "..." 
        instead 
        of an absolute path <...>

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/code_generator.hpp#L69

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/code_generator.cpp#L1122-L1142




        """
        return _casadi.CodeGenerator_add_include(self, *args)

    __swig_destroy__ = _casadi.delete_CodeGenerator
CodeGenerator_swigregister = _casadi.CodeGenerator_swigregister
CodeGenerator_swigregister(CodeGenerator)

FLAG = _casadi.FLAG

def _horzcat(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Concatenate horizontally, six matrices.

    ::

      _horzcat([Sparsity] v) -> Sparsity
      _horzcat([DM] v) -> DM
      _horzcat([SX] v) -> SX
      _horzcat([MX] v) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_4e

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L502

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L502-L505




    """
    return _casadi._horzcat(*args)

def _vertcat(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Concatenate vertically, six matrices.

    ::

      _vertcat([Sparsity] v) -> Sparsity
      _vertcat([DM] v) -> DM
      _vertcat([SX] v) -> SX
      _vertcat([MX] v) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_4j

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L540

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L540-L543




    """
    return _casadi._vertcat(*args)

def horzsplit(*args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
    """
      split horizontally, retaining fixed-sized groups of columns

    ::

      horzsplit(Sparsity v, int incr) -> [Sparsity]
      horzsplit(DM v, int incr) -> [DM]
      horzsplit(SX v, int incr) -> [SX]
      horzsplit(MX v, int incr) -> [MX]
      horzsplit(Sparsity v, [int] offset) -> [Sparsity]
      horzsplit(DM v, [int] offset) -> [DM]
      horzsplit(SX v, [int] offset) -> [SX]
      horzsplit(MX v, [int] offset) -> [MX]


    Parameters:
    -----------

    incr: 
    Size (width) of each group of columns

    horzcat(horzsplit(x, ...)) = x

    \\seealso horzsplit_n

    Extra doc: https://github.com/casadi/casadi/wiki/L_3h

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L134

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L134-L136




    """
    return _casadi.horzsplit(*args)

def horzsplit_n(*args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
    """
      split horizontally, retaining fixed-sized groups of columns

    ::

      horzsplit_n(Sparsity v, int n) -> [Sparsity]
      horzsplit_n(DM v, int n) -> [DM]
      horzsplit_n(SX v, int n) -> [SX]
      horzsplit_n(MX v, int n) -> [MX]


    Parameters:
    -----------

    n: 
    Number of groups of columns

    Will error when the number of columns is not a multiple of n

    horzcat(horzsplit(x, ...)) = x

    \\seealso horzsplit

    Extra doc: https://github.com/casadi/casadi/wiki/L_277

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L149

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L149-L151




    """
    return _casadi.horzsplit_n(*args)

def offset(*args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
    """
      Helper function, get offsets corresponding to a vector of matrices.

    ::

      offset([Sparsity] v, bool vert) -> [int]
      offset([DM] v, bool vert) -> [int]
      offset([SX] v, bool vert) -> [int]
      offset([MX] v, bool vert) -> [int]


    Extra doc: https://github.com/casadi/casadi/wiki/L_3j

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L169

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L169-L171




    """
    return _casadi.offset(*args)

def vertsplit(*args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
    """
      split vertically, retaining fixed-sized groups of rows

    ::

      vertsplit(Sparsity v, int incr) -> [Sparsity]
      vertsplit(DM v, int incr) -> [DM]
      vertsplit(SX v, int incr) -> [SX]
      vertsplit(MX v, int incr) -> [MX]
      vertsplit(Sparsity v, [int] offset) -> [Sparsity]
      vertsplit(DM v, [int] offset) -> [DM]
      vertsplit(SX v, [int] offset) -> [SX]
      vertsplit(MX v, [int] offset) -> [MX]


    Parameters:
    -----------

    incr: 
    Size of each group of rows

    vertcat(vertsplit(x, ...)) = x



    ::

      >>> print vertsplit(SX.sym("a",4))
      [SX(a_0), SX(a_1), SX(a_2), SX(a_3)]






    ::

      >>> print vertsplit(SX.sym("a",4),2)
      [SX([a_0, a_1]), SX([a_2, a_3])]




    If the number of rows is not a multiple of  incr, the last entry returned 
    will have a size smaller than  incr.



    ::

      >>> print vertsplit(DM([0,1,2,3,4]),2)
      [DM([0, 1]), DM([2, 3]), DM(4)]




    \\seealso vertsplit_n

    Extra doc: https://github.com/casadi/casadi/wiki/L_3k

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L204

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L204-L206




    """
    return _casadi.vertsplit(*args)

def vertsplit_n(*args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
    """
      split vertically, retaining fixed-sized groups of rows

    ::

      vertsplit_n(Sparsity v, int n) -> [Sparsity]
      vertsplit_n(DM v, int n) -> [DM]
      vertsplit_n(SX v, int n) -> [SX]
      vertsplit_n(MX v, int n) -> [MX]


    Parameters:
    -----------

    n: 
    Number of groups of rows

    Will error when the number of rows is not a multiple of n

    vertcat(vertsplit(x, ...)) = x

    \\seealso vertsplit

    Extra doc: https://github.com/casadi/casadi/wiki/L_278

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L219

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L219-L221




    """
    return _casadi.vertsplit_n(*args)

def blocksplit(*args) -> "std::vector< std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >,std::allocator< std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > > > >":
    """
      chop up into blocks

    ::

      blocksplit(Sparsity x, int vert_incr, int horz_incr) -> [[Sparsity]]
      blocksplit(DM x, int vert_incr, int horz_incr) -> [[DM]]
      blocksplit(SX x, int vert_incr, int horz_incr) -> [[SX]]
      blocksplit(MX x, int vert_incr, int horz_incr) -> [[MX]]
      blocksplit(Sparsity x, [int] vert_offset, [int] horz_offset) -> [[Sparsity]]
      blocksplit(DM x, [int] vert_offset, [int] horz_offset) -> [[DM]]
      blocksplit(SX x, [int] vert_offset, [int] horz_offset) -> [[SX]]
      blocksplit(MX x, [int] vert_offset, [int] horz_offset) -> [[MX]]


    Parameters:
    -----------

    vert_incr: 
    Defines the increment for block boundaries in row dimension

    horz_incr: 
    Defines the increment for block boundaries in column dimension

    blockcat(blocksplit(x,..., ...)) = x

    Extra doc: https://github.com/casadi/casadi/wiki/L_3o

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L262

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L262-L264




    """
    return _casadi.blocksplit(*args)

def _diagcat(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Concatenate along diagonal, six matrices.

    ::

      _diagcat([Sparsity] A) -> Sparsity
      _diagcat([DM] A) -> DM
      _diagcat([SX] A) -> SX
      _diagcat([MX] A) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_4o

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L578

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L578-L581




    """
    return _casadi._diagcat(*args)

def diagsplit(*args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
    """
      split diagonally, retaining fixed-sized matrices

    ::

      diagsplit(Sparsity x, int incr) -> [Sparsity]
      diagsplit(DM x, int incr) -> [DM]
      diagsplit(SX x, int incr) -> [SX]
      diagsplit(MX x, int incr) -> [MX]
      diagsplit(Sparsity x, [int] output_offset) -> [Sparsity]
      diagsplit(DM x, [int] output_offset) -> [DM]
      diagsplit(SX x, [int] output_offset) -> [SX]
      diagsplit(MX x, [int] output_offset) -> [MX]
      diagsplit(Sparsity x, int incr1, int incr2) -> [Sparsity]
      diagsplit(Sparsity x, [int] output_offset1, [int] output_offset2) -> [Sparsity]
      diagsplit(DM x, int incr1, int incr2) -> [DM]
      diagsplit(DM x, [int] output_offset1, [int] output_offset2) -> [DM]
      diagsplit(SX x, int incr1, int incr2) -> [SX]
      diagsplit(SX x, [int] output_offset1, [int] output_offset2) -> [SX]
      diagsplit(MX x, int incr1, int incr2) -> [MX]
      diagsplit(MX x, [int] output_offset1, [int] output_offset2) -> [MX]


    Parameters:
    -----------

    incr1: 
    Row dimension of each matrix

    incr2: 
    Column dimension of each matrix

    diagsplit(diagsplit(x, ...)) = x

    Extra doc: https://github.com/casadi/casadi/wiki/L_3t

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L324

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L324-L326




    """
    return _casadi.diagsplit(*args)

def _veccat(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      concatenate vertically while vectorizing all arguments with vec

    ::

      _veccat([Sparsity] x) -> Sparsity
      _veccat([DM] x) -> DM
      _veccat([SX] x) -> SX
      _veccat([MX] x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_3u

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L331

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L331-L333




    """
    return _casadi._veccat(*args)

def mtimes(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Matrix product of n matrices.

    ::

      mtimes([Sparsity] args) -> Sparsity
      mtimes([DM] args) -> DM
      mtimes([SX] args) -> SX
      mtimes([MX] args) -> MX
      mtimes(Sparsity x, Sparsity y) -> Sparsity
      mtimes(DM x, DM y) -> DM
      mtimes(SX x, SX y) -> SX
      mtimes(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_3w

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L345

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L345-L347




    """
    return _casadi.mtimes(*args)

def mac(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Multiply-accumulate operation.

    ::

      mac(Sparsity X, Sparsity Y, Sparsity Z) -> Sparsity
      mac(DM X, DM Y, DM Z) -> DM
      mac(SX X, SX Y, SX Z) -> SX
      mac(MX X, MX Y, MX Z) -> MX


    Matrix product of two matrices (x and y), adding the result to a third 

    matrix z. The result has the same sparsity pattern as C meaning that 
    other 
    entries of (x*y) are ignored. The operation is equivalent to: 

    z+mtimes(x,y).project(z.sparsity()).

    Extra doc: https://github.com/casadi/casadi/wiki/L_3x

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L358

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L358-L360




    """
    return _casadi.mac(*args)

def transpose(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Transpose.

    ::

      transpose(Sparsity X) -> Sparsity
      transpose(DM X) -> DM
      transpose(SX X) -> SX
      transpose(MX X) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_3y

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L365

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L365-L367




    """
    return _casadi.transpose(*args)

def vec(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      make a vector

    ::

      vec(Sparsity a) -> Sparsity
      vec(DM a) -> DM
      vec(SX a) -> SX
      vec(MX a) -> MX


    Reshapes/vectorizes the matrix such that the shape becomes 
    (expr.numel(), 
    1). Columns are stacked on top of each other. Same as 
    reshape(expr, 
    expr.numel(), 1)

    a c 
    b d 
     turns into

    a 
    b 
    c 
    d 
     Extra doc: https://github.com/casadi/casadi/wiki/L_3z

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L386

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L386-L388




    """
    return _casadi.vec(*args)

def reshape(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Reshape the matrix.

    ::

      reshape(Sparsity a, (int,int) rc) -> Sparsity
      reshape(Sparsity a, Sparsity sp) -> Sparsity
      reshape(DM a, (int,int) rc) -> DM
      reshape(DM a, Sparsity sp) -> DM
      reshape(SX a, (int,int) rc) -> SX
      reshape(SX a, Sparsity sp) -> SX
      reshape(MX a, (int,int) rc) -> MX
      reshape(MX a, Sparsity sp) -> MX
      reshape(Sparsity a, int nrow, int ncol) -> Sparsity
      reshape(DM a, int nrow, int ncol) -> DM
      reshape(SX a, int nrow, int ncol) -> SX
      reshape(MX a, int nrow, int ncol) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_42

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L407

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L407-L409




    """
    return _casadi.reshape(*args)

def sparsity_cast(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Cast matrix nonzeros to different Sparsity.

    ::

      sparsity_cast(Sparsity a, Sparsity sp) -> Sparsity
      sparsity_cast(DM a, Sparsity sp) -> DM
      sparsity_cast(SX a, Sparsity sp) -> SX
      sparsity_cast(MX a, Sparsity sp) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_24z

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L414

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L414-L416




    """
    return _casadi.sparsity_cast(*args)

def sprank(*args) -> "casadi_int":
    """


    ::

      sprank(Sparsity A) -> int
      sprank(DM A) -> int
      sprank(SX A) -> int
      sprank(MX A) -> int



    """
    return _casadi.sprank(*args)

def norm_0_mul(*args) -> "casadi_int":
    """


    ::

      norm_0_mul(Sparsity x, Sparsity y) -> int
      norm_0_mul(DM x, DM y) -> int
      norm_0_mul(SX x, SX y) -> int
      norm_0_mul(MX x, MX y) -> int



    """
    return _casadi.norm_0_mul(*args)

def triu(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Get the upper triangular part of a matrix.

    ::

      triu(Sparsity a, bool includeDiagonal) -> Sparsity
      triu(DM a, bool includeDiagonal) -> DM
      triu(SX a, bool includeDiagonal) -> SX
      triu(MX a, bool includeDiagonal) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_45

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L435

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L435-L437




    """
    return _casadi.triu(*args)

def tril(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Get the lower triangular part of a matrix.

    ::

      tril(Sparsity a, bool includeDiagonal) -> Sparsity
      tril(DM a, bool includeDiagonal) -> DM
      tril(SX a, bool includeDiagonal) -> SX
      tril(MX a, bool includeDiagonal) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_46

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L442

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L442-L444




    """
    return _casadi.tril(*args)

def kron(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Kronecker tensor product.

    ::

      kron(Sparsity a, Sparsity b) -> Sparsity
      kron(DM a, DM b) -> DM
      kron(SX a, SX b) -> SX
      kron(MX a, MX b) -> MX


    Creates a block matrix in which each element (i, j) is a_ij*b

    Extra doc: https://github.com/casadi/casadi/wiki/L_47

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L451

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L451-L453




    """
    return _casadi.kron(*args)

def repmat(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Repeat matrix A n times vertically and m times horizontally.

    ::

      repmat(Sparsity A, int n, int m) -> Sparsity
      repmat(Sparsity A, (int,int) rc) -> Sparsity
      repmat(DM A, int n, int m) -> DM
      repmat(DM A, (int,int) rc) -> DM
      repmat(SX A, int n, int m) -> SX
      repmat(SX A, (int,int) rc) -> SX
      repmat(MX A, int n, int m) -> MX
      repmat(MX A, (int,int) rc) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_49

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L465

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L465-L467




    """
    return _casadi.repmat(*args)

def sum2(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Return a column-wise summation of elements.

    ::

      sum2(Sparsity x) -> Sparsity
      sum2(DM x) -> DM
      sum2(SX x) -> SX
      sum2(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_4q

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L591

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L591-L591




    """
    return _casadi.sum2(*args)

def sum1(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Return a row-wise summation of elements.

    ::

      sum1(Sparsity x) -> Sparsity
      sum1(DM x) -> DM
      sum1(SX x) -> SX
      sum1(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_4p

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L586

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L586-L586




    """
    return _casadi.sum1(*args)

def sum(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      sum

    ::

      sum(Sparsity x) -> Sparsity
      sum(DM x) -> DM
      sum(SX x) -> SX
      sum(MX x) -> MX
      sum(Sparsity x, int dim) -> Sparsity
      sum(DM x, int dim) -> DM
      sum(SX x, int dim) -> SX
      sum(MX x, int dim) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1ll

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L930

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L930-L934




    """
    return _casadi.sum(*args)

def plus(*args) -> "double":
    """


    ::

      plus(float x, float y) -> float
      plus(DM x, DM y) -> DM
      plus(SX x, SX y) -> SX
      plus(MX x, MX y) -> MX



    """
    return _casadi.plus(*args)

def minus(*args) -> "double":
    """
      Subtraction: (x,y) -> x - y.

    ::

      minus(float x, float y) -> float
      minus(DM x, DM y) -> DM
      minus(SX x, SX y) -> SX
      minus(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_oo

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L83

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L83-L85




    """
    return _casadi.minus(*args)

def times(*args) -> "double":
    """
      Elementwise multiplication: (x,y) -> x .* y.

    ::

      times(float x, float y) -> float
      times(DM x, DM y) -> DM
      times(SX x, SX y) -> SX
      times(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_op

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L99

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L99-L101




    """
    return _casadi.times(*args)

def rdivide(*args) -> "double":
    """
      Elementwise division: (x,y) -> x ./ y.

    ::

      rdivide(float x, float y) -> float
      rdivide(DM x, DM y) -> DM
      rdivide(SX x, SX y) -> SX
      rdivide(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_oq

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L115

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L115-L117




    """
    return _casadi.rdivide(*args)

def ldivide(*args) -> "double":
    """


    ::

      ldivide(float x, float y) -> float
      ldivide(DM x, DM y) -> DM
      ldivide(SX x, SX y) -> SX
      ldivide(MX x, MX y) -> MX



    """
    return _casadi.ldivide(*args)

def lt(*args) -> "double":
    """
      Logical less than: (x,y) -> x < y.

    ::

      lt(float x, float y) -> float
      lt(DM x, DM y) -> DM
      lt(SX x, SX y) -> SX
      lt(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_or

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L131

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L131-L133




    """
    return _casadi.lt(*args)

def le(*args) -> "double":
    """
      Logical less or equal to: (x,y) -> x <= y.

    ::

      le(float x, float y) -> float
      le(DM x, DM y) -> DM
      le(SX x, SX y) -> SX
      le(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_os

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L146

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L146-L148




    """
    return _casadi.le(*args)

def gt(*args) -> "double":
    """
      Logical greater than: (x,y) -> x > y.

    ::

      gt(float x, float y) -> float
      gt(DM x, DM y) -> DM
      gt(SX x, SX y) -> SX
      gt(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_ot

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L161

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L161-L163




    """
    return _casadi.gt(*args)

def ge(*args) -> "double":
    """
      Logical greater or equal to: (x,y) -> x >= y.

    ::

      ge(float x, float y) -> float
      ge(DM x, DM y) -> DM
      ge(SX x, SX y) -> SX
      ge(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_ou

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L176

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L176-L178




    """
    return _casadi.ge(*args)

def eq(*args) -> "double":
    """
      Logical equal to: (x,y) -> x == y.

    ::

      eq(float x, float y) -> float
      eq(DM x, DM y) -> DM
      eq(SX x, SX y) -> SX
      eq(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_ov

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L191

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L191-L193




    """
    return _casadi.eq(*args)

def ne(*args) -> "double":
    """
      Logical not equal to: (x,y) -> x != y.

    ::

      ne(float x, float y) -> float
      ne(DM x, DM y) -> DM
      ne(SX x, SX y) -> SX
      ne(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_ow

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L206

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L206-L208




    """
    return _casadi.ne(*args)

def logic_and(*args) -> "double":
    """


    ::

      logic_and(float x, float y) -> float
      logic_and(DM x, DM y) -> DM
      logic_and(SX x, SX y) -> SX
      logic_and(MX x, MX y) -> MX



    """
    return _casadi.logic_and(*args)

def logic_or(*args) -> "double":
    """


    ::

      logic_or(float x, float y) -> float
      logic_or(DM x, DM y) -> DM
      logic_or(SX x, SX y) -> SX
      logic_or(MX x, MX y) -> MX



    """
    return _casadi.logic_or(*args)

def logic_not(*args) -> "double":
    """


    ::

      logic_not(float x) -> float
      logic_not(DM x) -> DM
      logic_not(SX x) -> SX
      logic_not(MX x) -> MX



    """
    return _casadi.logic_not(*args)

def fabs(*args) -> "double":
    """
      Absolute value: x -> abs(x)

    ::

      fabs(float x) -> float
      fabs(DM x) -> DM
      fabs(SX x) -> SX
      fabs(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_p0

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L275

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L275-L277




    """
    return _casadi.fabs(*args)

def sqrt(*args) -> "double":
    """
      Square root: x -> sqrt(x)

    ::

      sqrt(float x) -> float
      sqrt(DM x) -> DM
      sqrt(SX x) -> SX
      sqrt(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_p1

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L290

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L290-L292




    """
    return _casadi.sqrt(*args)

def sin(*args) -> "double":
    """
      Sine: x -> sin(x)

    ::

      sin(float x) -> float
      sin(DM x) -> DM
      sin(SX x) -> SX
      sin(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_p3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L314

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L314-L316




    """
    return _casadi.sin(*args)

def cos(*args) -> "double":
    """
      Cosine: x -> cos(x)

    ::

      cos(float x) -> float
      cos(DM x) -> DM
      cos(SX x) -> SX
      cos(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_p4

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L326

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L326-L328




    """
    return _casadi.cos(*args)

def tan(*args) -> "double":
    """
      Tangent: x -> tan(x)

    ::

      tan(float x) -> float
      tan(DM x) -> DM
      tan(SX x) -> SX
      tan(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_p5

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L338

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L338-L340




    """
    return _casadi.tan(*args)

def atan(*args) -> "double":
    """
      Arc tangent: x -> atan(x)

    ::

      atan(float x) -> float
      atan(DM x) -> DM
      atan(SX x) -> SX
      atan(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_p6

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L350

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L350-L352




    """
    return _casadi.atan(*args)

def asin(*args) -> "double":
    """
      Arc sine: x -> asin(x)

    ::

      asin(float x) -> float
      asin(DM x) -> DM
      asin(SX x) -> SX
      asin(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_p7

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L362

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L362-L364




    """
    return _casadi.asin(*args)

def acos(*args) -> "double":
    """
      Arc cosine: x -> acos(x)

    ::

      acos(float x) -> float
      acos(DM x) -> DM
      acos(SX x) -> SX
      acos(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_p8

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L374

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L374-L376




    """
    return _casadi.acos(*args)

def tanh(*args) -> "double":
    """
      Hyperbolic tangent: x -> tanh(x)

    ::

      tanh(float x) -> float
      tanh(DM x) -> DM
      tanh(SX x) -> SX
      tanh(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_p9

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L386

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L386-L388




    """
    return _casadi.tanh(*args)

def sinh(*args) -> "double":
    """
      Hyperbolic sin: x -> sinh(x)

    ::

      sinh(float x) -> float
      sinh(DM x) -> DM
      sinh(SX x) -> SX
      sinh(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pa

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L398

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L398-L400




    """
    return _casadi.sinh(*args)

def cosh(*args) -> "double":
    """
      Hyperbolic cosine: x -> cosh(x)

    ::

      cosh(float x) -> float
      cosh(DM x) -> DM
      cosh(SX x) -> SX
      cosh(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pb

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L410

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L410-L412




    """
    return _casadi.cosh(*args)

def atanh(*args) -> "double":
    """
      Inverse hyperbolic tangent: x -> atanh(x)

    ::

      atanh(float x) -> float
      atanh(DM x) -> DM
      atanh(SX x) -> SX
      atanh(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pc

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L422

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L422-L424




    """
    return _casadi.atanh(*args)

def asinh(*args) -> "double":
    """
      Inverse hyperbolic sin: x -> asinh(x)

    ::

      asinh(float x) -> float
      asinh(DM x) -> DM
      asinh(SX x) -> SX
      asinh(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pd

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L434

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L434-L436




    """
    return _casadi.asinh(*args)

def acosh(*args) -> "double":
    """
      Inverse hyperbolic cosine: x -> acosh(x)

    ::

      acosh(float x) -> float
      acosh(DM x) -> DM
      acosh(SX x) -> SX
      acosh(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pe

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L446

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L446-L448




    """
    return _casadi.acosh(*args)

def exp(*args) -> "double":
    """
      Elementwise exponential: x -> exp(x)

    ::

      exp(float x) -> float
      exp(DM x) -> DM
      exp(SX x) -> SX
      exp(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pf

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L458

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L458-L460




    """
    return _casadi.exp(*args)

def log(*args) -> "double":
    """
      Natural logarithm: x -> log(x)

    ::

      log(float x) -> float
      log(DM x) -> DM
      log(SX x) -> SX
      log(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pg

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L470

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L470-L472




    """
    return _casadi.log(*args)

def log10(*args) -> "double":
    """
      Base-10 logarithm: x -> log10(x)

    ::

      log10(float x) -> float
      log10(DM x) -> DM
      log10(SX x) -> SX
      log10(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_ph

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L482

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L482-L484




    """
    return _casadi.log10(*args)

def log1p(*args) -> "double":
    """
      Precision variant for natural logarithm: x -> log(x+1)

    ::

      log1p(float x) -> float
      log1p(DM x) -> DM
      log1p(SX x) -> SX
      log1p(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pi

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L494

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L494-L496




    """
    return _casadi.log1p(*args)

def expm1(*args) -> "double":
    """
      Precision variant for elementwise exponential: x -> exp(x)-1.

    ::

      expm1(float x) -> float
      expm1(DM x) -> DM
      expm1(SX x) -> SX
      expm1(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pj

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L506

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L506-L508




    """
    return _casadi.expm1(*args)

def floor(*args) -> "double":
    """
      Round down to nearest integer: x -> floor(x)

    ::

      floor(float x) -> float
      floor(DM x) -> DM
      floor(SX x) -> SX
      floor(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pk

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L518

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L518-L520




    """
    return _casadi.floor(*args)

def ceil(*args) -> "double":
    """
      Round up to nearest integer: x -> ceil(x)

    ::

      ceil(float x) -> float
      ceil(DM x) -> DM
      ceil(SX x) -> SX
      ceil(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pl

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L530

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L530-L532




    """
    return _casadi.ceil(*args)

def erf(*args) -> "double":
    """
      Error function: x -> erf(x)

    ::

      erf(float x) -> float
      erf(DM x) -> DM
      erf(SX x) -> SX
      erf(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pm

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L542

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L542-L544




    """
    return _casadi.erf(*args)

def erfinv(*args) -> "double":
    """
      Inverse error function: x -> erfinv(x)

    ::

      erfinv(float x) -> float
      erfinv(DM x) -> DM
      erfinv(SX x) -> SX
      erfinv(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pn

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L554

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L554-L556




    """
    return _casadi.erfinv(*args)

def sign(*args) -> "double":
    """
      Sign function:

    ::

      sign(float x) -> float
      sign(DM x) -> DM
      sign(SX x) -> SX
      sign(MX x) -> MX


    sign(x) := -1 for x<0 sign(x) := 1 for x>0, sign(0) := 0 sign(NaN) := 
    NaN

    Extra doc: https://github.com/casadi/casadi/wiki/L_po

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L571

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L571-L573




    """
    return _casadi.sign(*args)

def power(*args) -> "double":
    """


    ::

      power(float x, float n) -> float
      power(DM x, DM n) -> DM
      power(SX x, SX n) -> SX
      power(MX x, MX n) -> MX



    """
    return _casadi.power(*args)

def fmod(*args) -> "double":
    """
      Remainder after division: (x,y) -> fmod(x,y)

    ::

      fmod(float x, float y) -> float
      fmod(DM x, DM y) -> DM
      fmod(SX x, SX y) -> SX
      fmod(MX x, MX y) -> MX


    This  Function follows the convention of 
    https://en.cppreference.com/w/c/numeric/math/fmod

    Notably:
    fmod(5,3) -> 2

    fmod(5,-3) -> 2

    fmod(-5,3) -> -2

    fmod(-5,-3) -> -2

    This is equivalent to Python's numpy.fmod and Matlab's rem.

    \\seealso remainder

    ::

      Extra doc: https://github.com/casadi/casadi/wiki/L_pq 




    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L613

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L613-L615




    """
    return _casadi.fmod(*args)

def remainder(*args) -> "double":
    """
      Remainder after division: (x,y) -> remainder(x,y)

    ::

      remainder(float x, float y) -> float
      remainder(DM x, DM y) -> DM
      remainder(SX x, SX y) -> SX
      remainder(MX x, MX y) -> MX


    This Function follows the convention of 
    https://en.cppreference.com/w/c/numeric/math/remainder

    Notably:
    remainder(5,3) -> -1

    remainder(5,-3) -> -1

    remainder(-5,3) -> 1

    remainder(-5,-3) -> 1

    This is equivalent to Python's math.remainder. There is no equivalence
     in 
    Matlab.

    \\seealso fmod

    ::

      Extra doc: https://github.com/casadi/casadi/wiki/L_24x 




    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L634

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L634-L636




    """
    return _casadi.remainder(*args)

def atan2(*args) -> "double":
    """
      Two argument arc tangent: (y,x) -> atan2(y,x)

    ::

      atan2(float x, float y) -> float
      atan2(DM x, DM y) -> DM
      atan2(SX x, SX y) -> SX
      atan2(MX x, MX y) -> MX


    theta = atan2(y,x) corresponds to x = r cos(theta), y = r sin(theta)

    Extra doc: https://github.com/casadi/casadi/wiki/L_pr

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L648

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L648-L650




    """
    return _casadi.atan2(*args)

def fmin(*args) -> "double":
    """
      Smallest of two values: (x,y) -> min(x,y)

    ::

      fmin(float x, float y) -> float
      fmin(DM x, DM y) -> DM
      fmin(SX x, SX y) -> SX
      fmin(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pt

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L672

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L672-L674




    """
    return _casadi.fmin(*args)

def fmax(*args) -> "double":
    """
      Largest of two values: (x,y) -> max(x,y)

    ::

      fmax(float x, float y) -> float
      fmax(DM x, DM y) -> DM
      fmax(SX x, SX y) -> SX
      fmax(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pu

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L684

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L684-L686




    """
    return _casadi.fmax(*args)

def hypot(*args) -> "double":
    """
      Precision variant for 2 norm: (x,y) -> sqrt(x^2+y^2)

    ::

      hypot(float x, float y) -> float
      hypot(DM x, DM y) -> DM
      hypot(SX x, SX y) -> SX
      hypot(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_pw

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L742

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L742-L744




    """
    return _casadi.hypot(*args)

def simplify(*args) -> "double":
    """
      Simplify an expression.

    ::

      simplify(float x) -> float
      simplify(DM x) -> DM
      simplify(SX x) -> SX
      simplify(MX x) -> MX


    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1123

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1123-L1125




    """
    return _casadi.simplify(*args)

def is_equal(*args) -> "bool":
    """
      Check if two nodes are equivalent up to a given depth.

    ::

      is_equal(float x, float y, int depth) -> bool
      is_equal(DM x, DM y, int depth) -> bool
      is_equal(SX x, SX y, int depth) -> bool
      is_equal(MX x, MX y, int depth) -> bool


    Depth=0 checks if the expressions are identical, i.e. points to the 
    same 
    node.

    a = x*x b = x*x

    is_equal(a,b,0) will return false, but a.is_equal(a,b,1) will return 
    true

    Extra doc: https://github.com/casadi/casadi/wiki/L_pv

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L703

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L703-L705




    """
    return _casadi.is_equal(*args)

def copysign(*args) -> "double":
    """
      Copy sign

    ::

      copysign(float x, float y) -> float
      copysign(DM x, DM y) -> DM
      copysign(SX x, SX y) -> SX
      copysign(MX x, MX y) -> MX


    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L710

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L710-L712




    """
    return _casadi.copysign(*args)

def constpow(*args) -> "double":
    """
      Elementwise power with const power

    ::

      constpow(float x, float y) -> float
      constpow(DM x, DM y) -> DM
      constpow(SX x, SX y) -> SX
      constpow(MX x, MX y) -> MX


    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L720

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_expression.hpp#L720-L722




    """
    return _casadi.constpow(*args)

def mpower(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Matrix power x^n.

    ::

      mpower(DM x, DM n) -> DM
      mpower(SX x, SX n) -> SX
      mpower(MX x, MX n) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1bi

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L319

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L319-L321




    """
    return _casadi.mpower(*args)

def mrdivide(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Matrix divide (cf. slash '/' in MATLAB)

    ::

      mrdivide(DM x, DM y) -> DM
      mrdivide(SX x, SX y) -> SX
      mrdivide(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1bl

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L376

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L376-L378




    """
    return _casadi.mrdivide(*args)

def mldivide(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Matrix divide (cf. backslash '\\' in MATLAB)

    ::

      mldivide(DM x, DM y) -> DM
      mldivide(SX x, SX y) -> SX
      mldivide(MX x, MX y) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1bm

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L383

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L383-L385




    """
    return _casadi.mldivide(*args)

def symvar(*args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
    """
      Get symbols present in expression.

    ::

      symvar(DM x) -> [DM]
      symvar(SX x) -> [SX]
      symvar(MX x) -> [MX]


    Returned vector is ordered according to the order of  variable()/parameter()
     calls used to create the variables

    Extra doc: https://github.com/casadi/casadi/wiki/L_1u

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L578

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L532-L538




    """
    return _casadi.symvar(*args)

def bilin(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Calculate bilinear/quadratic form x^T A y.

    ::

      bilin(DM A, DM x) -> DM
      bilin(SX A, SX x) -> SX
      bilin(MX A, MX x) -> MX
      bilin(DM A, DM x, DM y) -> DM
      bilin(SX A, SX x, SX y) -> SX
      bilin(MX A, MX x, MX y) -> MX


    Parameters:
    -----------

    y: 
    can be omitted, in which case x^T A x is calculated

    Extra doc: https://github.com/casadi/casadi/wiki/L_1bo

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L409




    """
    return _casadi.bilin(*args)

def rank1(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Make a rank-1 update to a matrix A.

    ::

      rank1(DM A, DM alpha, DM x, DM y) -> DM
      rank1(SX A, SX alpha, SX x, SX y) -> SX
      rank1(MX A, MX alpha, MX x, MX y) -> MX


    Calculates A + 1/2 * alpha * x*y'

    Extra doc: https://github.com/casadi/casadi/wiki/L_1bp

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L422




    """
    return _casadi.rank1(*args)

def sumsqr(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Calculate sum of squares: sum_ij X_ij^2.

    ::

      sumsqr(DM X) -> DM
      sumsqr(SX X) -> SX
      sumsqr(MX X) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1bq

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L429

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L429-L431




    """
    return _casadi.sumsqr(*args)

def linspace(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Matlab's linspace.

    ::

      linspace(DM a, DM b, int nsteps) -> DM
      linspace(SX a, SX b, int nsteps) -> SX
      linspace(MX a, MX b, int nsteps) -> MX


    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L857

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L857-L868




    """
    return _casadi.linspace(*args)

def logsumexp(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Scaled version of logsumexp.

    ::

      logsumexp(DM a) -> DM
      logsumexp(SX a) -> SX
      logsumexp(MX a) -> MX
      logsumexp(DM a, DM margin) -> DM
      logsumexp(SX a, SX margin) -> SX
      logsumexp(MX a, MX margin) -> MX


    Scaled such that max(x) <= logsumexp(x, margin) <= max(x)+margin

    Extra doc: https://github.com/casadi/casadi/wiki/L_1bs

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L451

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L451-L454




    """
    return _casadi.logsumexp(*args)

def interp1d(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Performs 1d linear interpolation.

    ::

      interp1d([float] x, DM v, [float] xq, str mode, bool equidistant) -> DM
      interp1d([float] x, SX v, [float] xq, str mode, bool equidistant) -> SX
      interp1d([float] x, MX v, [float] xq, str mode, bool equidistant) -> MX


    The data-points to be interpolated are given as (x[i], v[i]). xq[j] is
     used
     as interpolating value

    Extra doc: https://github.com/casadi/casadi/wiki/L_1bh

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L311

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L311-L314




    """
    return _casadi.interp1d(*args)

def soc(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Construct second-order-convex.

    ::

      soc(DM x, DM y) -> DM
      soc(SX x, SX y) -> SX
      soc(MX x, MX y) -> MX


    Parameters:
    -----------

    x: 
    vector expression of size n

    y: 
    scalar expression

    soc(x,y) computes [y*eye(n) x; x' y]

    soc(x,y) positive semi definite <=> || x ||_2 <= y

    Extra doc: https://github.com/casadi/casadi/wiki/L_1bj

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L334

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L334-L336




    """
    return _casadi.soc(*args)

def cross(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Matlab's  cross command.

    ::

      cross(DM a, DM b, int dim) -> DM
      cross(SX a, SX b, int dim) -> SX
      cross(MX a, MX b, int dim) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1bu

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L467

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L467-L469




    """
    return _casadi.cross(*args)

def skew(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Generate a skew symmetric matrix from a 3-vector.

    ::

      skew(DM a) -> DM
      skew(SX a) -> SX
      skew(MX a) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1bv

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L474

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L474-L476




    """
    return _casadi.skew(*args)

def inv_skew(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Generate the 3-vector progenitor of a skew symmetric matrix.

    ::

      inv_skew(DM a) -> DM
      inv_skew(SX a) -> SX
      inv_skew(MX a) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1bw

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L481

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L481-L483




    """
    return _casadi.inv_skew(*args)

def det(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Matrix determinant (experimental)

    ::

      det(DM A) -> DM
      det(SX A) -> SX
      det(MX A) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1bx

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L488

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L488-L488




    """
    return _casadi.det(*args)

def inv_minor(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Matrix inverse (experimental)

    ::

      inv_minor(DM A) -> DM
      inv_minor(SX A) -> SX
      inv_minor(MX A) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1by

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L493

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L493-L493




    """
    return _casadi.inv_minor(*args)

def inv(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Element-wise inverse.

    ::

      inv(DM A) -> DM
      inv(SX A) -> SX
      inv(MX A) -> MX
      inv(DM A, str lsolver, dict opts) -> DM
      inv(SX A, str lsolver, dict opts) -> SX
      inv(MX A, str lsolver, dict opts) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_10y

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sx_elem.hpp#L242

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sx_elem.cpp#L166-L172




    """
    return _casadi.inv(*args)

def trace(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Matrix trace.

    ::

      trace(DM a) -> DM
      trace(SX a) -> SX
      trace(MX a) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1c1

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L514

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L514-L514




    """
    return _casadi.trace(*args)

def tril2symm(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Convert a lower triangular matrix to a symmetric one.

    ::

      tril2symm(DM a) -> DM
      tril2symm(SX a) -> SX
      tril2symm(MX a) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1c2

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L519

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L519-L519




    """
    return _casadi.tril2symm(*args)

def triu2symm(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Convert a upper triangular matrix to a symmetric one.

    ::

      triu2symm(DM a) -> DM
      triu2symm(SX a) -> SX
      triu2symm(MX a) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1c3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L524

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L524-L524




    """
    return _casadi.triu2symm(*args)

def norm_fro(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Frobenius norm.

    ::

      norm_fro(DM x) -> DM
      norm_fro(SX x) -> SX
      norm_fro(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1c4

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L529

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L529-L529




    """
    return _casadi.norm_fro(*args)

def norm_2(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      2-norm

    ::

      norm_2(DM x) -> DM
      norm_2(SX x) -> SX
      norm_2(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1c5

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L534

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L534-L534




    """
    return _casadi.norm_2(*args)

def norm_1(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      1-norm

    ::

      norm_1(DM x) -> DM
      norm_1(SX x) -> SX
      norm_1(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1c6

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L539

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L539-L539




    """
    return _casadi.norm_1(*args)

def norm_inf(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Infinity-norm.

    ::

      norm_inf(DM x) -> DM
      norm_inf(SX x) -> SX
      norm_inf(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1c7

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L544

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L544-L544




    """
    return _casadi.norm_inf(*args)

def dot(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Inner product of two matrices.

    ::

      dot(DM x, DM y) -> DM
      dot(SX x, SX y) -> SX
      dot(MX x, MX y) -> MX


    with x and y matrices of the same dimension

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ca

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L565

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L565-L567




    """
    return _casadi.dot(*args)

def nullspace(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Computes the nullspace of a matrix A.

    ::

      nullspace(DM A) -> DM
      nullspace(SX A) -> SX
      nullspace(MX A) -> MX


    Finds Z m-by-(m-n) such that AZ = 0 with A n-by-m with m > n

    Assumes A is full rank

    Inspired by Numerical Methods in Scientific Computing by Ake Bjorck

    Extra doc: https://github.com/casadi/casadi/wiki/L_1cb

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L579

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L579-L581




    """
    return _casadi.nullspace(*args)

def polyval(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Evaluate a polynomial with coefficients p in x.

    ::

      polyval(DM p, DM x) -> DM
      polyval(SX p, SX x) -> SX
      polyval(MX p, MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1cc

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L586

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L586-L588




    """
    return _casadi.polyval(*args)

def diag(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Get the diagonal of a matrix or construct a diagonal.

    ::

      diag(DM A) -> DM
      diag(SX A) -> SX
      diag(MX A) -> MX


    When the input is square, the diagonal elements are returned. If the 
    input 
    is vector-like, a diagonal matrix is constructed with it.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1cd

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L596

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L596-L598




    """
    return _casadi.diag(*args)

def unite(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Unite two matrices no overlapping sparsity.

    ::

      unite(DM A, DM B) -> DM
      unite(SX A, SX B) -> SX
      unite(MX A, MX B) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1ce

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L603

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L603-L605




    """
    return _casadi.unite(*args)

def densify(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Make the matrix dense and assign nonzeros to a value.

    ::

      densify(DM x) -> DM
      densify(SX x) -> SX
      densify(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1cg

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L617

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L617-L619




    """
    return _casadi.densify(*args)

def project(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Create a new matrix with a given sparsity pattern but with the.

    ::

      project(DM A, Sparsity sp, bool intersect) -> DM
      project(SX A, Sparsity sp, bool intersect) -> SX
      project(MX A, Sparsity sp, bool intersect) -> MX


    nonzeros taken from an existing matrix

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ch

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L626

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L626-L629




    """
    return _casadi.project(*args)

def if_else(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Ternary if_else: x ? y : z.

    ::

      if_else(DM cond, DM if_true, DM if_false, bool short_circuit) -> DM
      if_else(SX cond, SX if_true, SX if_false, bool short_circuit) -> SX
      if_else(MX cond, MX if_true, MX if_false, bool short_circuit) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_113

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sx_elem.hpp#L285

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sx_elem.hpp#L285-L287




    """
    return _casadi.if_else(*args)

def conditional(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Create a switch.

    ::

      conditional(DM ind, [DM] x, DM x_default, bool short_circuit) -> DM
      conditional(SX ind, [SX] x, SX x_default, bool short_circuit) -> SX
      conditional(MX ind, [MX] x, MX x_default, bool short_circuit) -> MX


    If the condition

    Parameters:
    -----------

    ind: 
    evaluates to the integer k, where 0<=k<f.size(), then x[k] will be 

    returned, otherwise

    x_default: 
    will be returned.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1cj

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L647

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L647-L650




    """
    return _casadi.conditional(*args)

def depends_on(*args) -> "bool":
    """
      Check if expression depends on the argument.

    ::

      depends_on(DM f, DM arg) -> bool
      depends_on(SX f, SX arg) -> bool
      depends_on(MX f, MX arg) -> bool


    The argument must be symbolic

    The dependency is in a mathematical way: Does the value of the 
    argument 
    affect the value of the expression? Equivalently, will the 
    corresponding 
    entry of the Jacobian by a non-zero?

    The symbol could still be present in the expression graph.

    To check that kind of dependency, use contains(symvar(f),arg)

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ck

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L665

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L665-L667




    """
    return _casadi.depends_on(*args)

def contains(*args) -> "bool":
    """
      Check if expression n is listed in v.

    ::

      contains([DM] v, DM n) -> bool
      contains([SX] v, SX n) -> bool
      contains([MX] v, MX n) -> bool


    This function checks for correspondence between nodes. The detection 
    does 
    not descend into the expression graph.

    contains({a,b},b) -> true contains({a+b},b) -> false

    e = a+b contains({e},e) -> true

    For mathematical dependency, see depends_on 
    See: 
     depends_on

    Extra doc: https://github.com/casadi/casadi/wiki/L_2c8

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L685

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L685-L687




    """
    return _casadi.contains(*args)

def contains_all(*args) -> "bool":
    """
      Check if expression n is listed in v.

    ::

      contains_all([DM] v, [DM] n) -> bool
      contains_all([SX] v, [SX] n) -> bool
      contains_all([MX] v, [MX] n) -> bool


    This function checks for correspondence between nodes. The detection 
    does 
    not descend into the expression graph.

    contains({a,b},b) -> true contains({a+b},b) -> false

    e = a+b contains({e},e) -> true

    For mathematical dependency, see depends_on 
    See: 
     depends_on

    Extra doc: https://github.com/casadi/casadi/wiki/L_2c8

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L689

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L689-L691




    """
    return _casadi.contains_all(*args)

def contains_any(*args) -> "bool":
    """
      Check if expression n is listed in v.

    ::

      contains_any([DM] v, [DM] n) -> bool
      contains_any([SX] v, [SX] n) -> bool
      contains_any([MX] v, [MX] n) -> bool


    This function checks for correspondence between nodes. The detection 
    does 
    not descend into the expression graph.

    contains({a,b},b) -> true contains({a+b},b) -> false

    e = a+b contains({e},e) -> true

    For mathematical dependency, see depends_on 
    See: 
     depends_on

    Extra doc: https://github.com/casadi/casadi/wiki/L_2c8

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L693

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L693-L695




    """
    return _casadi.contains_any(*args)

def solve(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Crunch the numbers; solve the problem.

    ::

      solve(DM A, DM b) -> DM
      solve(SX A, SX b) -> SX
      solve(MX A, MX b) -> MX
      solve(DM A, DM b, str lsolver, dict opts) -> DM
      solve(SX A, SX b, str lsolver, dict opts) -> SX
      solve(MX A, MX b, str lsolver, dict opts) -> MX


    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L240

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L213-L219




    """
    return _casadi.solve(*args)

def pinv(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Computes the Moore-Penrose pseudo-inverse.

    ::

      pinv(DM A) -> DM
      pinv(SX A) -> SX
      pinv(MX A) -> MX
      pinv(DM A, str lsolver, dict opts) -> DM
      pinv(SX A, str lsolver, dict opts) -> SX
      pinv(MX A, str lsolver, dict opts) -> MX


    If the matrix A is fat (size1>size2), mul(A, pinv(A)) is unity. If the

    matrix A is slender (size2<size1), mul(pinv(A), A) is unity.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1cu

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L823

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L823-L826




    """
    return _casadi.pinv(*args)

def expm_const(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Calculate  Matrix exponential.

    ::

      expm_const(DM A, DM t) -> DM
      expm_const(SX A, SX t) -> SX
      expm_const(MX A, MX t) -> MX


    Computes expm(A*t) with A constant

    Parameters:
    -----------

    A[in]: 
    Square matrix

    t[in]: 
    Scalar

    Extra doc: https://github.com/casadi/casadi/wiki/L_23v

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L838

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L838-L840




    """
    return _casadi.expm_const(*args)

def expm(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Calculate  Matrix exponential.

    ::

      expm(DM A) -> DM
      expm(SX A) -> SX
      expm(MX A) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_23w

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L846

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L846-L848




    """
    return _casadi.expm(*args)

def jacobian(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Calculate Jacobian.

    ::

      jacobian(DM ex, DM arg, dict opts) -> DM
      jacobian(SX ex, SX arg, dict opts) -> SX
      jacobian(MX ex, MX arg, dict opts) -> MX


    Sparse matrix

    Extra doc: https://github.com/casadi/casadi/wiki/L_1cv

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L855

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L855-L858




    """
    return _casadi.jacobian(*args)

def jtimes(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Calculate the Jacobian and multiply by a vector from the right.

    ::

      jtimes(DM ex, DM arg, DM v, bool tr, dict opts) -> DM
      jtimes(SX ex, SX arg, SX v, bool tr, dict opts) -> SX
      jtimes(MX ex, MX arg, MX v, bool tr, dict opts) -> MX


    This is equivalent to  mul(jacobian(ex, arg), v) or  mul(jacobian(ex, 
    arg).T, v) for tr set to false and true respectively. If contrast to these 

    expressions, it will use directional derivatives which is typically 
    (but 
    not necessarily) more efficient if the complete Jacobian is not 
    needed and 
    v has few rows.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1cw

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L888

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L888-L891




    """
    return _casadi.jtimes(*args)

def linearize(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Linearize an expression.

    ::

      linearize(DM f, DM x, DM x0) -> DM
      linearize(SX f, SX x, SX x0) -> SX
      linearize(MX f, MX x, MX x0) -> MX


    [DEPRECATED] confusing behaviour

    This function linearizes an expression around a point x0, using x as 
    delta 
    around that point.



    ::

    >>> linearize(sin(x),x,x0) -> sin(x0)+cos(x0)*x

    For a variant that returns sin(x0)+cos(x0)*(x-x0), see taylor.

    See: 
    taylor,  linear_coeff

    Extra doc: https://github.com/casadi/casadi/wiki/L_1cs

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L795

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L795-L798




    """
    return _casadi.linearize(*args)

def which_depends(*args) -> "std::vector< bool,std::allocator< bool > >":
    """
      Find out which variables enter with some order.

    ::

      which_depends(DM expr, DM var, int order, bool tr) -> [bool]
      which_depends(SX expr, SX var, int order, bool tr) -> [bool]
      which_depends(MX expr, MX var, int order, bool tr) -> [bool]


    Extra doc: https://github.com/casadi/casadi/wiki/L_1cz

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L930

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L930-L933




    """
    return _casadi.which_depends(*args)

def jacobian_sparsity(*args) -> "casadi::Sparsity":
    """
      Get the sparsity pattern of a jacobian.

    ::

      jacobian_sparsity(DM f, DM x) -> Sparsity
      jacobian_sparsity(SX f, SX x) -> Sparsity
      jacobian_sparsity(MX f, MX x) -> Sparsity


    Equivalent to, but cheaper to compute than, jacobian(f,x). sparsity()

    Extra doc: https://github.com/casadi/casadi/wiki/L_259

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L940

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L940-L942




    """
    return _casadi.jacobian_sparsity(*args)

def is_linear(*args) -> "bool":
    """
      Is expr linear in var?

    ::

      is_linear(DM expr, DM var) -> bool
      is_linear(SX expr, SX var) -> bool
      is_linear(MX expr, MX var) -> bool


    False negatives are possible (an expression may not be recognised as 
    linear
     while it really is), false positives not.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1d0

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L951

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L951-L953




    """
    return _casadi.is_linear(*args)

def is_quadratic(*args) -> "bool":
    """
      Is expr quadratic in var?

    ::

      is_quadratic(DM expr, DM var) -> bool
      is_quadratic(SX expr, SX var) -> bool
      is_quadratic(MX expr, MX var) -> bool


    False negatives are possible (an expression may not be recognised as 

    quadratic while it really is), false positives not.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1d1

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L962

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L962-L964




    """
    return _casadi.is_quadratic(*args)

def gradient(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Calculate the gradient of an expression.

    ::

      gradient(DM ex, DM arg, dict opts) -> DM
      gradient(SX ex, SX arg, dict opts) -> SX
      gradient(MX ex, MX arg, dict opts) -> MX


    Parameters:
    -----------

    ex[in]: 
    Scalar expression to take the gradient of

    arg[in]: 
    Vector expression of symbols

    opts[in]: 
    Options

    Dense column vector

    Extra doc: https://github.com/casadi/casadi/wiki/L_23x

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L868

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L868-L870




    """
    return _casadi.gradient(*args)

def tangent(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Calculate the tangent of an expression.

    ::

      tangent(DM ex, DM arg, dict opts) -> DM
      tangent(SX ex, SX arg, dict opts) -> SX
      tangent(MX ex, MX arg, dict opts) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_23y

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L875

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L875-L877




    """
    return _casadi.tangent(*args)

def hessian(*args) -> "casadi::Matrix< casadi::SXElem > &":
    """
      Hessian and (optionally) gradient.

    ::

      hessian(DM ex, DM arg, dict opts) -> (DM , DM OUTPUT1)
      hessian(SX ex, SX arg, dict opts) -> (SX , SX OUTPUT1)
      hessian(MX ex, MX arg, dict opts) -> (MX , MX OUTPUT1)


    Extra doc: https://github.com/casadi/casadi/wiki/L_23z

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L921

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L921-L924




    """
    return _casadi.hessian(*args)

def quadratic_coeff(*args) -> "casadi::Matrix< casadi::SXElem > &, casadi::Matrix< casadi::SXElem > &, casadi::Matrix< casadi::SXElem > &":
    """
      Recognizes quadratic form in scalar expression.

    ::

      quadratic_coeff(DM ex, DM arg, bool check) -> (DM OUTPUT1, DM OUTPUT2, DM OUTPUT3)
      quadratic_coeff(SX ex, SX arg, bool check) -> (SX OUTPUT1, SX OUTPUT2, SX OUTPUT3)
      quadratic_coeff(MX ex, MX arg, bool check) -> (MX OUTPUT1, MX OUTPUT2, MX OUTPUT3)


    1/2*x' A x + b' x + c

    e = 0.5*bilin(A,x,x)+dot(b,x)+c

    Parameters:
    -----------

    check[in]: 
    When true (default), A is checked to be independent of x. 
    Provided to 
    deal with false positive dependency checks.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1d2

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L976

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L976-L979




    """
    return _casadi.quadratic_coeff(*args)

def linear_coeff(*args) -> "casadi::Matrix< casadi::SXElem > &, casadi::Matrix< casadi::SXElem > &":
    """
      Recognizes linear form in vector expression.

    ::

      linear_coeff(DM ex, DM arg, bool check) -> (DM OUTPUT1, DM OUTPUT2)
      linear_coeff(SX ex, SX arg, bool check) -> (SX OUTPUT1, SX OUTPUT2)
      linear_coeff(MX ex, MX arg, bool check) -> (MX OUTPUT1, MX OUTPUT2)


    A x + b

    Parameters:
    -----------

    check[in]: 
    When true (default)m, A is checked to be independent of x. 
    Provided to
     deal with false positive dependency checks.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1d3

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L989

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L989-L992




    """
    return _casadi.linear_coeff(*args)

def n_nodes(*args) -> "casadi_int":
    """


    ::

      n_nodes(DM A) -> int
      n_nodes(SX A) -> int
      n_nodes(MX A) -> int



    """
    return _casadi.n_nodes(*args)

def print_operator(*args) -> "std::string":
    """
      Get a string representation for a binary MatType, using custom 

    ::

      print_operator(DM xb, [str] args) -> str
      print_operator(SX xb, [str] args) -> str
      print_operator(MX xb, [str] args) -> str

    arguments.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1d4

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1131

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1131-L1133




    """
    return _casadi.print_operator(*args)

def repsum(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Given a repeated matrix, computes the sum of repeated parts.

    ::

      repsum(DM A, int n, int m) -> DM
      repsum(SX A, int n, int m) -> SX
      repsum(MX A, int n, int m) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1d7

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1159

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1159-L1161




    """
    return _casadi.repsum(*args)

def diff(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      diff

    ::

      diff(DM A, int n, int axis) -> DM
      diff(SX A, int n, int axis) -> SX
      diff(MX A, int n, int axis) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1ln

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L959

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L959-L966




    """
    return _casadi.diff(*args)

def cumsum(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      cumulative sum

    ::

      cumsum(DM A, int axis) -> DM
      cumsum(SX A, int axis) -> SX
      cumsum(MX A, int axis) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1lm

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L937

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L937-L945




    """
    return _casadi.cumsum(*args)

def einstein(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Computes an einstein dense tensor contraction.

    ::

      einstein(DM A, DM B, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c) -> DM
      einstein(SX A, SX B, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c) -> SX
      einstein(MX A, MX B, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c) -> MX
      einstein(DM A, DM B, DM C, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c) -> DM
      einstein(SX A, SX B, SX C, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c) -> SX
      einstein(MX A, MX B, MX C, [int] dim_a, [int] dim_b, [int] dim_c, [int] a, [int] b, [int] c) -> MX


    Computes the product: C_c = A_a + B_b where a b c are index/einstein 

    notation in an encoded form

    For example, an matrix-matrix product may be written as: C_ij = A_ik 
    B_kj

    The encoded form uses strictly negative numbers to indicate labels. 
    For the
     above example, we would have: a {-1, -3} b {-3, -2} c {-1 -2}

    Extra doc: https://github.com/casadi/casadi/wiki/L_r5

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L564

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.cpp#L670-L676



    """
    return _casadi.einstein(*args)

def mmin(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Smallest element in a matrix.

    ::

      mmin(DM x) -> DM
      mmin(SX x) -> SX
      mmin(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1d8

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1167

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1167-L1169




    """
    return _casadi.mmin(*args)

def mmax(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Largest element in a matrix.

    ::

      mmax(DM x) -> DM
      mmax(SX x) -> SX
      mmax(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1d9

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1176

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1176-L1178




    """
    return _casadi.mmax(*args)

def evalf(*args) -> "casadi::DM":
    """
      Evaluates the expression numerically.

    ::

      evalf(DM x) -> DM
      evalf(SX x) -> DM
      evalf(MX x) -> DM


    An error is raised when the expression contains symbols

    Extra doc: https://github.com/casadi/casadi/wiki/L_rf

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L873

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L873-L875



    """
    return _casadi.evalf(*args)

def separate_linear(*args) -> "casadi::Matrix< casadi::SXElem > &, casadi::Matrix< casadi::SXElem > &, casadi::Matrix< casadi::SXElem > &":
    """


    ::

      separate_linear(DM expr, DM sym_lin, DM sym_const) -> (DM OUTPUT1, DM OUTPUT2, DM OUTPUT3)
      separate_linear(DM expr, [DM] sym_lin, [DM] sym_const) -> (DM OUTPUT1, DM OUTPUT2, DM OUTPUT3)
      separate_linear(SX expr, SX sym_lin, SX sym_const) -> (SX OUTPUT1, SX OUTPUT2, SX OUTPUT3)
      separate_linear(SX expr, [SX] sym_lin, [SX] sym_const) -> (SX OUTPUT1, SX OUTPUT2, SX OUTPUT3)
      separate_linear(MX expr, MX sym_lin, MX sym_const) -> (MX OUTPUT1, MX OUTPUT2, MX OUTPUT3)
      separate_linear(MX expr, [MX] sym_lin, [MX] sym_const) -> (MX OUTPUT1, MX OUTPUT2, MX OUTPUT3)



    """
    return _casadi.separate_linear(*args)

def cse(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Common subexpression elimination.

    ::

      cse(DM e) -> DM
      cse([DM] e) -> [DM]
      cse([SX] e) -> [SX]
      cse(SX e) -> SX
      cse(MX e) -> MX
      cse([MX] e) -> [MX]


    Extra doc: https://github.com/casadi/casadi/wiki/L_1cp

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L739

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L739-L741




    """
    return _casadi.cse(*args)

def extract_parametric(*args) -> "std::vector< casadi::Matrix< casadi::SXElem > > &, std::vector< casadi::Matrix< casadi::SXElem > > &, std::vector< casadi::Matrix< casadi::SXElem > > &":
    """
      Extract purely parametric parts from an expression graph.

    ::

      extract_parametric(DM expr, DM par, dict opts) -> (DM OUTPUT1, [DM] OUTPUT2, [DM] OUTPUT3)
      extract_parametric(DM expr, [DM] par, dict opts) -> (DM OUTPUT1, [DM] OUTPUT2, [DM] OUTPUT3)
      extract_parametric([DM] expr, DM par, dict opts) -> ([DM] OUTPUT1, [DM] OUTPUT2, [DM] OUTPUT3)
      extract_parametric([DM] expr, [DM] par, dict opts) -> ([DM] OUTPUT1, [DM] OUTPUT2, [DM] OUTPUT3)
      extract_parametric(SX expr, SX par, dict opts) -> (SX OUTPUT1, [SX] OUTPUT2, [SX] OUTPUT3)
      extract_parametric(SX expr, [SX] par, dict opts) -> (SX OUTPUT1, [SX] OUTPUT2, [SX] OUTPUT3)
      extract_parametric([SX] expr, SX par, dict opts) -> ([SX] OUTPUT1, [SX] OUTPUT2, [SX] OUTPUT3)
      extract_parametric([SX] expr, [SX] par, dict opts) -> ([SX] OUTPUT1, [SX] OUTPUT2, [SX] OUTPUT3)
      extract_parametric(MX expr, MX par, dict opts) -> (MX OUTPUT1, [MX] OUTPUT2, [MX] OUTPUT3)
      extract_parametric(MX expr, [MX] par, dict opts) -> (MX OUTPUT1, [MX] OUTPUT2, [MX] OUTPUT3)
      extract_parametric([MX] expr, MX par, dict opts) -> ([MX] OUTPUT1, [MX] OUTPUT2, [MX] OUTPUT3)
      extract_parametric([MX] expr, [MX] par, dict opts) -> ([MX] OUTPUT1, [MX] OUTPUT2, [MX] OUTPUT3)


    The purpose of extract_parametric is ultimately to save on evaluation 
    time 
    of an expression, by extracting out the parts that are only 
    solely 
    dependent on parameters.

    For any: [expr_ret, symbols, parametric] = extract_parametric(expr, 
    par) It
     holds that: substitute(expr_ret,symbols,parametric) == expr

    parametric is only dependant on par expr_ret is not dependant on par, 
    but 
    is dependant on symbols

    Example: [expr_ret, symbols, parametric] = 

    extract_parametric((x-sqrt(p))*y+cos(p)**2, p)

    expr_ret: (((x-extracted1)*y)+extracted2) symbols: [extracted1, 
    extracted2]
     parametric: [sqrt(p),cos(p)**2]

    Options to control the name of new symbols:
    offset (int), default 0: Offset 
    for new symbol counter

    prefix (str), default 'e_': Prefix for new symbols

    suffix (str), default '': Suffix for new symbols

    Option 'extract_trivial' controls the behaviour for extracted parts 
    that 
    consist of pure symbols. If false (default), these parts are not 
    extracted.

    Extra doc: https://github.com/casadi/casadi/wiki/L_288

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1025

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1025-L1031




    """
    return _casadi.extract_parametric(*args)

def forward(*args) -> "std::vector< std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >,std::allocator< std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > > > >":
    """
      Forward directional derivative.

    ::

      forward([DM] ex, [DM] arg, [[DM]] v, dict opts) -> [[DM]]
      forward([SX] ex, [SX] arg, [[SX]] v, dict opts) -> [[SX]]
      forward([MX] ex, [MX] arg, [[MX]] v, dict opts) -> [[MX]]


    Extra doc: https://github.com/casadi/casadi/wiki/L_1cx

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L897

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L897-L901




    """
    return _casadi.forward(*args)

def reverse(*args) -> "std::vector< std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >,std::allocator< std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > > > >":
    """
      Reverse a list.

    ::

      reverse([DM] ex, [DM] arg, [[DM]] v, dict opts) -> [[DM]]
      reverse([SX] ex, [SX] arg, [[SX]] v, dict opts) -> [[SX]]
      reverse([MX] ex, [MX] arg, [[MX]] v, dict opts) -> [[MX]]


    Extra doc: https://github.com/casadi/casadi/wiki/L_1la

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L603

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L603-L607




    """
    return _casadi.reverse(*args)

def substitute(*args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
    """
      Substitute variable var with expression expr in multiple expressions.

    ::

      substitute(DM ex, DM v, DM vdef) -> DM
      substitute([DM] ex, [DM] v, [DM] vdef) -> [DM]
      substitute(SX ex, SX v, SX vdef) -> SX
      substitute([SX] ex, [SX] v, [SX] vdef) -> [SX]
      substitute(MX ex, MX v, MX vdef) -> MX
      substitute([MX] ex, [MX] v, [MX] vdef) -> [MX]


    Extra doc: https://github.com/casadi/casadi/wiki/L_1cm

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L710

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L710-L713




    """
    return _casadi.substitute(*args)

def substitute_inplace(*args) -> "std::vector< casadi::Matrix< casadi::SXElem > > &, std::vector< casadi::Matrix< casadi::SXElem > > &":
    """
      Inplace substitution with piggyback expressions.

    ::

      substitute_inplace([DM] v, bool reverse) -> ([DM] INOUT1, [DM] INOUT2)
      substitute_inplace([SX] v, bool reverse) -> ([SX] INOUT1, [SX] INOUT2)
      substitute_inplace([MX] v, bool reverse) -> ([MX] INOUT1, [MX] INOUT2)


    Substitute variables v out of the expressions vdef sequentially, as 
    well as
     out of a number of other expressions piggyback

    Extra doc: https://github.com/casadi/casadi/wiki/L_1cn

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L722

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L722-L726




    """
    return _casadi.substitute_inplace(*args)

def extract(*args) -> "std::vector< casadi::Matrix< casadi::SXElem > > &, std::vector< casadi::Matrix< casadi::SXElem > > &, std::vector< casadi::Matrix< casadi::SXElem > > &":
    """
      Introduce intermediate variables for selected nodes in a graph.

    ::

      extract([DM] ex, dict opts) -> ([DM] OUTPUT1, [DM] OUTPUT2, [DM] OUTPUT3)
      extract([SX] ex, dict opts) -> ([SX] OUTPUT1, [SX] OUTPUT2, [SX] OUTPUT3)
      extract([MX] ex, dict opts) -> ([MX] OUTPUT1, [MX] OUTPUT2, [MX] OUTPUT3)


    Extra doc: https://github.com/casadi/casadi/wiki/L_1d5

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1138

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1138-L1143




    """
    return _casadi.extract(*args)

def shared(*args) -> "std::vector< casadi::Matrix< casadi::SXElem > > &, std::vector< casadi::Matrix< casadi::SXElem > > &, std::vector< casadi::Matrix< casadi::SXElem > > &":
    """
      Extract shared subexpressions from an set of expressions.

    ::

      shared([DM] ex, str v_prefix, str v_suffix) -> ([DM] OUTPUT1, [DM] OUTPUT2, [DM] OUTPUT3)
      shared([SX] ex, str v_prefix, str v_suffix) -> ([SX] OUTPUT1, [SX] OUTPUT2, [SX] OUTPUT3)
      shared([MX] ex, str v_prefix, str v_suffix) -> ([MX] OUTPUT1, [MX] OUTPUT2, [MX] OUTPUT3)


    Extra doc: https://github.com/casadi/casadi/wiki/L_1d6

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1148

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/generic_matrix.hpp#L1148-L1154




    """
    return _casadi.shared(*args)

def blockcat(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Construct a matrix from 4 blocks.

    ::

      blockcat([[DM]] v) -> DM
      blockcat([[SX]] v) -> SX
      blockcat([[MX]] v) -> MX
      blockcat(Sparsity A, Sparsity B, Sparsity C, Sparsity D) -> Sparsity
      blockcat(DM A, DM B, DM C, DM D) -> DM
      blockcat(SX A, SX B, SX C, SX D) -> SX
      blockcat(MX A, MX B, MX C, MX D) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_3m

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L234

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/sparsity_interface.hpp#L234-L236




    """
    return _casadi.blockcat(*args)

def logic_all(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Check if all arguments are true.

    ::

      logic_all(DM x) -> DM
      logic_all(SX x) -> SX


    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L77

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.cpp#L77-L82




    """
    return _casadi.logic_all(*args)

def logic_any(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Check if any arguments are true.

    ::

      logic_any(DM x) -> DM
      logic_any(SX x) -> SX


    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L84

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.cpp#L84-L89




    """
    return _casadi.logic_any(*args)

def adj(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Matrix adjoint.

    ::

      adj(DM A) -> DM
      adj(SX A) -> SX


    Extra doc: https://github.com/casadi/casadi/wiki/L_18p

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L529

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L529-L531




    """
    return _casadi.adj(*args)

def minor(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Get the (i,j) minor matrix.

    ::

      minor(DM x, int i, int j) -> DM
      minor(SX x, int i, int j) -> SX


    Extra doc: https://github.com/casadi/casadi/wiki/L_18q

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L536

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L536-L538




    """
    return _casadi.minor(*args)

def cofactor(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Get the (i,j) cofactor matrix.

    ::

      cofactor(DM x, int i, int j) -> DM
      cofactor(SX x, int i, int j) -> SX


    Extra doc: https://github.com/casadi/casadi/wiki/L_18r

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L543

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L543-L545




    """
    return _casadi.cofactor(*args)

def qr(*args) -> "casadi::Matrix< casadi::SXElem > &, casadi::Matrix< casadi::SXElem > &":
    """
      QR factorization using the modified Gram-Schmidt algorithm.

    ::

      qr(DM A) -> (DM OUTPUT1, DM OUTPUT2)
      qr(SX A) -> (SX OUTPUT1, SX OUTPUT2)


    More stable than the classical Gram-Schmidt, but may break down if the
     rows
     of A are nearly linearly dependent See J. Demmel: Applied 
    Numerical Linear
     Algebra (algorithm 3.1.). Note that in SWIG, Q and R 
    are returned by 
    value.

    Extra doc: https://github.com/casadi/casadi/wiki/L_18s

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L555

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L555-L557




    """
    return _casadi.qr(*args)

def qr_sparse(*args) -> "casadi::Matrix< casadi::SXElem > &, casadi::Matrix< casadi::SXElem > &, casadi::Matrix< casadi::SXElem > &, std::vector< casadi_int > &, std::vector< casadi_int > &":
    """
      Sparse direct QR factorization.

    ::

      qr_sparse(DM A, bool amd) -> (DM OUTPUT1, DM OUTPUT2, DM OUTPUT3, [int] OUTPUT4, [int] OUTPUT5)
      qr_sparse(SX A, bool amd) -> (SX OUTPUT1, SX OUTPUT2, SX OUTPUT3, [int] OUTPUT4, [int] OUTPUT5)


    See T. Davis: Direct Methods for Sparse Linear Systems

    Extra doc: https://github.com/casadi/casadi/wiki/L_18t

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L564

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L564-L568




    """
    return _casadi.qr_sparse(*args)

def qr_solve(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Solve using a sparse QR factorization.

    ::

      qr_solve(DM b, DM v, DM r, DM beta, [int] prinv, [int] pc, bool tr) -> DM
      qr_solve(SX b, SX v, SX r, SX beta, [int] prinv, [int] pc, bool tr) -> SX


    Extra doc: https://github.com/casadi/casadi/wiki/L_18u

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L574

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L574-L579




    """
    return _casadi.qr_solve(*args)

def ldl(*args) -> "casadi::Matrix< casadi::SXElem > &, casadi::Matrix< casadi::SXElem > &, std::vector< casadi_int > &":
    """
      Sparse LDL^T factorization.

    ::

      ldl(DM A, bool amd) -> (DM OUTPUT1, DM OUTPUT2, [int] OUTPUT3)
      ldl(SX A, bool amd) -> (SX OUTPUT1, SX OUTPUT2, [int] OUTPUT3)


    Returns D and the strictly upper triangular entries of L^T I.e. ones 
    on the
     diagonal are ignored. Only guarenteed to work for positive 
    definite 
    matrices.

    Extra doc: https://github.com/casadi/casadi/wiki/L_18w

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L598

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L598-L601




    """
    return _casadi.ldl(*args)

def ldl_solve(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Solve using a sparse LDL^T factorization.

    ::

      ldl_solve(DM b, DM D, DM LT, [int] p) -> DM
      ldl_solve(SX b, SX D, SX LT, [int] p) -> SX


    Extra doc: https://github.com/casadi/casadi/wiki/L_18x

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L607

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L607-L610




    """
    return _casadi.ldl_solve(*args)

def chol(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Obtain a Cholesky factorisation of a matrix.

    ::

      chol(DM A) -> DM
      chol(SX A) -> SX


    Performs and LDL transformation [L,D] = ldl(A) and returns 
    diag(sqrt(D))*L'

    Extra doc: https://github.com/casadi/casadi/wiki/L_18v

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L587

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L587-L589




    """
    return _casadi.chol(*args)

def norm_inf_mul(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Inf-norm of a Matrix-Matrix product.

    ::

      norm_inf_mul(DM x, DM y) -> DM
      norm_inf_mul(SX x, SX y) -> SX


    Extra doc: https://github.com/casadi/casadi/wiki/L_190

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L630

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L630-L632




    """
    return _casadi.norm_inf_mul(*args)

def sparsify(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Make a matrix sparse by removing numerical zeros.

    ::

      sparsify(DM A, float tol) -> DM
      sparsify(SX A, float tol) -> SX


    Extra doc: https://github.com/casadi/casadi/wiki/L_191

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L638

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L638-L640




    """
    return _casadi.sparsify(*args)

def expand(*args) -> "casadi::Matrix< casadi::SXElem > &, casadi::Matrix< casadi::SXElem > &":
    """
      Expand the expression as a weighted sum (with constant weights)

    ::

      expand(DM ex) -> (DM OUTPUT1, DM OUTPUT2)
      expand(SX ex) -> (SX OUTPUT1, SX OUTPUT2)


    Extra doc: https://github.com/casadi/casadi/wiki/L_192

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L645

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L645-L648




    """
    return _casadi.expand(*args)

def pw_const(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Create a piecewise constant function.

    ::

      pw_const(DM t, DM tval, DM val) -> DM
      pw_const(SX t, SX tval, SX val) -> SX


    Create a piecewise constant function with n=val.size() intervals

    Inputs:

    Parameters:
    -----------

    t: 
    a scalar variable (e.g. time)

    tval: 
    vector with the discrete values of t at the interval transitions 

    (length n-1)

    val: 
    vector with the value of the function for each interval (length n)

    Extra doc: https://github.com/casadi/casadi/wiki/L_193

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L660

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L660-L664




    """
    return _casadi.pw_const(*args)

def pw_lin(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      t a scalar variable (e.g. time)

    ::

      pw_lin(DM t, DM tval, DM val) -> DM
      pw_lin(SX t, SX tval, SX val) -> SX


    Create a piecewise linear function

    Create a piecewise linear function:

    Inputs:

    tval vector with the the discrete values of t (monotonically 
    increasing)

    val vector with the corresponding function values (same length as 
    tval)

    ::

                                                                                                          Extra doc: https://github.com/casadi/casadi/wiki/L_194 




    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L677

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L677-L680




    """
    return _casadi.pw_lin(*args)

def heaviside(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Heaviside function.

    ::

      heaviside(DM x) -> DM
      heaviside(SX x) -> SX


    \\[ \\begin {cases} H(x) = 0 & x<0 \\\\ H(x) = 1/2 & x=0 
    \\\\ 
    H(x) = 1 & x>0 \\\\ \\end {cases} \\]

    Extra doc: https://github.com/casadi/casadi/wiki/L_195

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L693

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L693-L695




    """
    return _casadi.heaviside(*args)

def rectangle(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      rectangle function

    ::

      rectangle(DM x) -> DM
      rectangle(SX x) -> SX


    \\[ \\begin {cases} \\Pi(x) = 1 & |x| < 1/2 \\\\ \\Pi(x) =
     1/2 
    & |x| = 1/2 \\\\ \\Pi(x) = 0 & |x| > 1/2 \\\\ \\end 
    {cases} 
    \\]

    Also called: gate function, block function, band function, pulse 
    function, 
    window function

    Extra doc: https://github.com/casadi/casadi/wiki/L_23n

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L710

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L710-L712




    """
    return _casadi.rectangle(*args)

def triangle(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      triangle function

    ::

      triangle(DM x) -> DM
      triangle(SX x) -> SX


    \\[ \\begin {cases} \\Lambda(x) = 0 & |x| >= 1 \\\\ 
    \\Lambda(x)
     = 1-|x| & |x| < 1 \\end {cases} \\]

    Extra doc: https://github.com/casadi/casadi/wiki/L_23o

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L725

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L725-L727




    """
    return _casadi.triangle(*args)

def ramp(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      ramp function

    ::

      ramp(DM x) -> DM
      ramp(SX x) -> SX


    \\[ \\begin {cases} R(x) = 0 & x <= 1 \\\\ R(x) = x & x > 1 

    \\\\ \\end {cases} \\]

    Also called: slope function

    Extra doc: https://github.com/casadi/casadi/wiki/L_23p

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L742

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L742-L744




    """
    return _casadi.ramp(*args)

def gauss_quadrature(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Integrate f from a to b using Gaussian quadrature with n points.

    ::

      gauss_quadrature(DM f, DM x, DM a, DM b, int order) -> DM
      gauss_quadrature(SX f, SX x, SX a, SX b, int order) -> SX
      gauss_quadrature(DM f, DM x, DM a, DM b, int order, DM w) -> DM
      gauss_quadrature(SX f, SX x, SX a, SX b, int order, SX w) -> SX


    Extra doc: https://github.com/casadi/casadi/wiki/L_196

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L757

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L757-L761




    """
    return _casadi.gauss_quadrature(*args)

def taylor(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      univariate Taylor series expansion

    ::

      taylor(DM ex, DM x, DM a, int order) -> DM
      taylor(SX ex, SX x, SX a, int order) -> SX


    Calculate the Taylor expansion of expression 'ex' up to order 'order' 
    with 
    respect to variable 'x' around the point 'a'

    $(x)=f(a)+f'(a)(x-a)+f''(a)\\frac 

    {(x-a)^2}{2!}+f'''(a)\\frac{(x-a)^3}{3!}+\\ldots$

    Example usage:

    ::

    >>> taylor(sin(x), x)

    ::

    >>   x





    ::

    >>> taylor(sin(x),x,x0) -> sin(x0)+cos(x0)*(x-x0)

    See: 
     linearize,  mtaylor,  linear_coeff

    Extra doc: https://github.com/casadi/casadi/wiki/L_23q

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L789

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L789-L791




    """
    return _casadi.taylor(*args)

def mtaylor(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      multivariate Taylor series expansion

    ::

      mtaylor(DM ex, DM x, DM a, int order) -> DM
      mtaylor(SX ex, SX x, SX a, int order) -> SX
      mtaylor(DM ex, DM x, DM a, int order, [int] order_contributions) -> DM
      mtaylor(SX ex, SX x, SX a, int order, [int] order_contributions) -> SX


    Do Taylor expansions until the aggregated order of a term is equal to 

    'order'. The aggregated order of  $x^n y^m$ equals  $n+m$.

    The argument order_contributions can denote how match each variable 

    contributes to the aggregated order. If x=[x, y] and 

    order_contributions=[1, 2], then the aggregated order of  $x^n y^m$ equals  
    $1n+2m$.

    Example usage



    ::

    >>> taylor(sin(x+y),[x, y],[a, b], 1)
     $ \\sin(b+a)+\\cos(b+a)(x-a)+\\cos(b+a)(y-b) $

    ::

    >>> taylor(sin(x+y),[x, y],[0, 0], 4)
     $ y+x-(x^3+3y x^2+3 y^2 x+y^3)/6 $

    ::

    >>> taylor(sin(x+y),[x, y],[0, 0], 4,[1, 2])
     $ (-3 x^2 y-x^3)/6+y+x $

    See: 
     taylor

    Extra doc: https://github.com/casadi/casadi/wiki/L_23s

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L834

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L834-L838




    """
    return _casadi.mtaylor(*args)

def poly_coeff(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      extracts polynomial coefficients from an expression

    ::

      poly_coeff(DM ex, DM x) -> DM
      poly_coeff(SX ex, SX x) -> SX


    Parameters:
    -----------

    ex: 
    Scalar expression that represents a polynomial

    x: 
    Scalar symbol that the polynomial is build up with

    Extra doc: https://github.com/casadi/casadi/wiki/L_197

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L846

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L846-L849




    """
    return _casadi.poly_coeff(*args)

def poly_roots(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Attempts to find the roots of a polynomial.

    ::

      poly_roots(DM p) -> DM
      poly_roots(SX p) -> SX


    This will only work for polynomials up to order 3 It is assumed that 
    the 
    roots are real.

    Extra doc: https://github.com/casadi/casadi/wiki/L_198

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L857

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L857-L859




    """
    return _casadi.poly_roots(*args)

def eig_symbolic(*args) -> "casadi::Matrix< casadi::SXElem >":
    """
      Attempts to find the eigenvalues of a symbolic matrix.

    ::

      eig_symbolic(DM m) -> DM
      eig_symbolic(SX m) -> SX


    This will only work for up to 3x3 matrices

    Extra doc: https://github.com/casadi/casadi/wiki/L_199

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L866

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/matrix_decl.hpp#L866-L868




    """
    return _casadi.eig_symbolic(*args)

def find(*args) -> "casadi::MX":
    """
      find nonzeros

    ::

      find(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_1le

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L632

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/casadi_misc.hpp#L632-L638




    """
    return _casadi.find(*args)

def low(*args) -> "casadi::MX":
    """
      Find first nonzero.

    ::

      low(MX v, MX p, dict options) -> MX


    If failed, returns the number of rows

    Extra doc: https://github.com/casadi/casadi/wiki/L_r8

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L757

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L757-L759



    """
    return _casadi.low(*args)

def inv_node(*args) -> "casadi::MX":
    """
      Inverse node.

    ::

      inv_node(MX x) -> MX


    Extra doc: https://github.com/casadi/casadi/wiki/L_re

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L864

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L864-L866



    """
    return _casadi.inv_node(*args)

def matrix_expand(*args) -> "casadi::MX":
    """
      Expand  MX graph to SXFunction call.

    ::

      matrix_expand(MX e, [MX] boundary, dict options) -> MX
      matrix_expand([MX] e, [MX] boundary, dict options) -> [MX]


    Expand the given expression e, optionally supplying expressions 
    contained 
    in it at which expansion should stop.

    Extra doc: https://github.com/casadi/casadi/wiki/L_rc

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L816

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L816-L820



    """
    return _casadi.matrix_expand(*args)

def graph_substitute(*args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
    """
      Substitute multiple expressions in graph.

    ::

      graph_substitute(MX ex, [MX] v, [MX] vdef) -> MX
      graph_substitute([MX] ex, [MX] v, [MX] vdef) -> [MX]


    Substitute variable var with expression expr in multiple expressions, 

    preserving nodes

    Extra doc: https://github.com/casadi/casadi/wiki/L_ra

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L783

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L783-L787



    """
    return _casadi.graph_substitute(*args)

def bspline(*args) -> "casadi::MX":
    """


    ::

      bspline(MX x, DM coeffs, [[float]] knots, [int] degree, int m, dict opts) -> MX
      bspline(MX x, MX coeffs, [[float]] knots, [int] degree, int m, dict opts) -> MX



    """
    return _casadi.bspline(*args)

def convexify(*args) -> "casadi::MX":
    """


    ::

      convexify(MX H, dict opts) -> MX



    """
    return _casadi.convexify(*args)

def stop_diff(*args) -> "casadi::MX":
    """
      Stop derivatives of an expression wrt to a select set of symbolic 

    ::

      stop_diff(MX expr, int order) -> MX
      stop_diff(MX expr, MX var, int order) -> MX


    variables.

    Extra doc: https://github.com/casadi/casadi/wiki/L_25o

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L906

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L906-L908



    """
    return _casadi.stop_diff(*args)

def difference(*args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
    """
      \\bried Return all elements of a that do not occur in b, preserving 

    ::

      difference([MX] a, [MX] b) -> [MX]

    order

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L911

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L911-L913



    """
    return _casadi.difference(*args)

def no_hess(*args) -> "casadi::MX":
    """
      Stop second derivatives of an expression wrt to all its symbolic 

    ::

      no_hess(MX expr) -> MX

    variables.

    \\seealso stop_diff

    Extra doc: https://github.com/casadi/casadi/wiki/L_25n

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L898

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L898-L900



    """
    return _casadi.no_hess(*args)

def no_grad(*args) -> "casadi::MX":
    """
      Stop first derivatives of an expression wrt to all its symbolic 

    ::

      no_grad(MX expr) -> MX

    variables.

    \\seealso stop_diff

    Extra doc: https://github.com/casadi/casadi/wiki/L_25m

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L889

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/mx.hpp#L889-L891



    """
    return _casadi.no_grad(*args)
class Importer(SharedObject, PrintableCommon):
    """
      [INTERNAL] 

    ::


     Importer.

    Just-in-time compilation of code
    General informationList of plugins
    - clang

    - shell

    Note: some of the plugins in this list might not be available on your 

    system.  Also, there might be extra plugins available to you that are 
    not 
    listed here. You can obtain their documentation with   
    Importer.doc("myextraplugin")



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

    clang
    -----



    Interface to the JIT compiler CLANG

    Extra doc: https://github.com/casadi/casadi/wiki/L_21v

    >List of available options

    +--------------+-----------------+-----------------------------------------+
    |      Id      |      Type       |               Description               |
    +==============+=================+=========================================+
    | flags        | OT_STRINGVECTOR | Compile flags for the JIT compiler.     |
    |              |                 | Default: None                           |
    +--------------+-----------------+-----------------------------------------+
    | include_path | OT_STRING       | Include paths for the JIT compiler. The |
    |              |                 | include directory shipped with CasADi   |
    |              |                 | will be automatically appended.         |
    +--------------+-----------------+-----------------------------------------+



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

    shell
    -----



    Interface to the JIT compiler SHELL

    Extra doc: https://github.com/casadi/casadi/wiki/L_22w

    >List of available options

    +----------------------+-----------------+---------------------------------+
    |          Id          |      Type       |           Description           |
    +======================+=================+=================================+
    | cleanup              | OT_BOOL         | Cleanup temporary files when    |
    |                      |                 | unloading. Default: true        |
    +----------------------+-----------------+---------------------------------+
    | compiler             | OT_STRING       | Compiler command                |
    +----------------------+-----------------+---------------------------------+
    | compiler_flags       | OT_STRINGVECTOR | Alias for 'compiler_flags'      |
    +----------------------+-----------------+---------------------------------+
    | compiler_output_flag | OT_STRING       | Compiler flag to denote object  |
    |                      |                 | output. Default: '-o '          |
    +----------------------+-----------------+---------------------------------+
    | compiler_setup       | OT_STRING       | Compiler setup command.         |
    |                      |                 | Intended to be fixed. The       |
    |                      |                 | 'flag' option is the prefered   |
    |                      |                 | way to set custom flags.        |
    +----------------------+-----------------+---------------------------------+
    | directory            | OT_STRING       | Directory to put temporary      |
    |                      |                 | objects in. Must end with a     |
    |                      |                 | file separator.                 |
    +----------------------+-----------------+---------------------------------+
    | extra_suffixes       | OT_STRINGVECTOR | List of suffixes for extra      |
    |                      |                 | files that the compiler may     |
    |                      |                 | generate. Default: None         |
    +----------------------+-----------------+---------------------------------+
    | flags                | OT_STRINGVECTOR | Compile flags for the JIT       |
    |                      |                 | compiler. Default: None         |
    +----------------------+-----------------+---------------------------------+
    | linker               | OT_STRING       | Linker command                  |
    +----------------------+-----------------+---------------------------------+
    | linker_flags         | OT_STRINGVECTOR | Linker flags for the JIT        |
    |                      |                 | compiler. Default: None         |
    +----------------------+-----------------+---------------------------------+
    | linker_output_flag   | OT_STRING       | Linker flag to denote shared    |
    |                      |                 | library output. Default: '-o '  |
    +----------------------+-----------------+---------------------------------+
    | linker_setup         | OT_STRING       | Linker setup command. Intended  |
    |                      |                 | to be fixed. The 'flag' option  |
    |                      |                 | is the prefered way to set      |
    |                      |                 | custom flags.                   |
    +----------------------+-----------------+---------------------------------+
    | name                 | OT_STRING       | The file name used to write out |
    |                      |                 | compiled objects/libraries. The |
    |                      |                 | actual file names used depend   |
    |                      |                 | on 'temp_suffix' and include    |
    |                      |                 | extensions. Default:            |
    |                      |                 | 'tmp_casadi_compiler_shell'     |
    +----------------------+-----------------+---------------------------------+
    | temp_suffix          | OT_BOOL         | Use a temporary (seemingly      |
    |                      |                 | random) filename suffix for     |
    |                      |                 | file names. This is desired for |
    |                      |                 | thread-safety. This behaviour   |
    |                      |                 | may defeat caching compiler     |
    |                      |                 | wrappers. Default: true         |
    +----------------------+-----------------+---------------------------------+

    Joris Gillis

    Extra doc: https://github.com/casadi/casadi/wiki/L_161

    C++ includes: importer.hpp



    """

    __swig_setmethods__ = {}
    for _s in [SharedObject, PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, Importer, name, value)
    __swig_getmethods__ = {}
    for _s in [SharedObject, PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, Importer, name)
    __repr__ = _swig_repr

    def type_name(*args) -> "std::string":
        """


        ::

          type_name() -> str



        """
        return _casadi.Importer_type_name(*args)

    type_name = staticmethod(type_name)

    def test_cast(*args) -> "bool":
        """


        ::

          test_cast(casadi::SharedObjectInternal const * ptr) -> bool



        """
        return _casadi.Importer_test_cast(*args)

    test_cast = staticmethod(test_cast)

    def has_plugin(*args) -> "bool":
        """


        ::

          has_plugin(str name) -> bool



        """
        return _casadi.Importer_has_plugin(*args)

    has_plugin = staticmethod(has_plugin)

    def load_plugin(*args) -> "void":
        """


        ::

          load_plugin(str name)



        """
        return _casadi.Importer_load_plugin(*args)

    load_plugin = staticmethod(load_plugin)

    def doc(*args) -> "std::string":
        """


        ::

          doc(str name) -> str



        """
        return _casadi.Importer_doc(*args)

    doc = staticmethod(doc)

    def plugin_name(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          plugin_name(self) -> str

        Query plugin name.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.hpp#L118

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.cpp#L71-L73




        """
        return _casadi.Importer_plugin_name(self, *args)


    def has_function(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_function(self, str symname) -> bool



        """
        return _casadi.Importer_has_function(self, *args)


    def has_meta(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_meta(self, str cmd, int ind) -> bool

        Does a meta entry exist?

        Extra doc: https://github.com/casadi/casadi/wiki/L_165

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.hpp#L145

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.cpp#L83-L85




        """
        return _casadi.Importer_has_meta(self, *args)


    def get_meta(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          get_meta(self, str cmd, int ind) -> str

        Get entry as a text.

        Extra doc: https://github.com/casadi/casadi/wiki/L_166

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.hpp#L150

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.cpp#L87-L89




        """
        return _casadi.Importer_get_meta(self, *args)


    def inlined(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          inlined(self, str symname) -> bool

        Check if a function is inlined.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.hpp#L153

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.cpp#L91-L93




        """
        return _casadi.Importer_inlined(self, *args)


    def body(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          body(self, str symname) -> str

        Get the function body, if inlined.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.hpp#L156

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.cpp#L95-L97




        """
        return _casadi.Importer_body(self, *args)


    def library(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          library(self) -> str

        Get library name.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.hpp#L159

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.cpp#L99-L101




        """
        return _casadi.Importer_library(self, *args)


    def serialize(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          serialize(self, casadi::SerializingStream & s)

        Serialize an object.

        Extra doc: https://github.com/casadi/casadi/wiki/L_16c

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.hpp#L211

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.cpp#L103-L105




        """
        return _casadi.Importer_serialize(self, *args)


    def deserialize(*args) -> "casadi::Importer":
        """


        ::

          deserialize(casadi::DeserializingStream & s) -> Importer



        """
        return _casadi.Importer_deserialize(*args)

    deserialize = staticmethod(deserialize)

    def __init__(self, *args):
        """


        ::

          Importer()
          Importer(Importer other)
          Importer(str name, str compiler, dict opts)


        .......

        ::

          Importer(Importer other)



        .............


        .......

        ::

          Importer()



        [INTERNAL] 
        Default constructor.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.hpp#L94

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.cpp#L31-L32



        .............


        .......

        ::

          Importer(str name, str compiler, dict opts)



        [INTERNAL] 
         Importer factory.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.hpp#L97

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/importer.cpp#L34-L45



        .............



        """
        this = _casadi.new_Importer(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_Importer
Importer_swigregister = _casadi.Importer_swigregister
Importer_swigregister(Importer)

def Importer_type_name(*args) -> "std::string":
    """


    ::

      type_name() -> str



    """
    return _casadi.Importer_type_name(*args)

def Importer_test_cast(*args) -> "bool":
    """


    ::

      test_cast(casadi::SharedObjectInternal const * ptr) -> bool



    """
    return _casadi.Importer_test_cast(*args)

def Importer_has_plugin(*args) -> "bool":
    """


    ::

      has_plugin(str name) -> bool



    """
    return _casadi.Importer_has_plugin(*args)

def Importer_load_plugin(*args) -> "void":
    """


    ::

      load_plugin(str name)



    """
    return _casadi.Importer_load_plugin(*args)

def Importer_doc(*args) -> "std::string":
    """


    ::

      doc(str name) -> str



    """
    return _casadi.Importer_doc(*args)

def Importer_deserialize(*args) -> "casadi::Importer":
    """


    ::

      deserialize(casadi::DeserializingStream & s) -> Importer



    """
    return _casadi.Importer_deserialize(*args)

class Callback(Function):
    """
      [INTERNAL] 

    ::


     Callback function functionality.

    This class provides a public API to the FunctionInternal class that 
    can be 
    subclassed by the user, who is then able to implement the 
    different virtual
     method. Note that the  Function class also provides a public API to 
    FunctionInternal, but only allows
     calling, not being called.

    The user is responsible for not deleting this class for the lifetime 
    of the
     internal function object.

    Joris Gillis, Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_o0

    C++ includes: callback.hpp



    """

    __swig_setmethods__ = {}
    for _s in [Function]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, Callback, name, value)
    __swig_getmethods__ = {}
    for _s in [Function]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, Callback, name)
    __repr__ = _swig_repr

    def type_name(*args) -> "std::string":
        """


        ::

          type_name() -> str



        """
        return _casadi.Callback_type_name(*args)

    type_name = staticmethod(type_name)

    def __init__(self, *args):
        """
          [INTERNAL] 

        ::

          Callback(self)
          Callback(self, Callback obj)

        Copy constructor (throws an error)

        Extra doc: https://github.com/casadi/casadi/wiki/L_o3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L64

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L32-L34



        .......

        ::

          Callback(self)



        [INTERNAL] 
        Default constructor.

        Extra doc: https://github.com/casadi/casadi/wiki/L_o2

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L59

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L29-L30



        .............


        .......

        ::

          Callback(self, Callback obj)



        [INTERNAL] 
        Copy constructor (throws an error)

        Extra doc: https://github.com/casadi/casadi/wiki/L_o3

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L64

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L32-L34



        .............



        """
        if self.__class__ == Callback:
            _self = None
        else:
            _self = self
        this = _casadi.new_Callback(_self, *args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_Callback

    def construct(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          construct(self, str name, dict opts)

        Construct internal object.

        This is the step that actually construct the internal object, as the 
        class 
        constructor only creates a null pointer. It should be called 
        from the user 
        constructor.

        Extra doc: https://github.com/casadi/casadi/wiki/L_o5

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L78

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L36-L42




        """
        return _casadi.Callback_construct(self, *args)


    def init(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          init(self)

        Initialize the object.

        This function is called after the object construction (for the whole 
        class 
        hierarchy) is complete, but before the finalization step. It is 
        called 
        recursively for the whole class hierarchy, starting with the 
        lowest level.

        Extra doc: https://github.com/casadi/casadi/wiki/L_o6

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L88

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L88-L88




        """
        return _casadi.Callback_init(self, *args)


    def finalize(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          finalize(self)

        Finalize the object.

        This function is called after the construction and init steps are 

        completed, but before user functions are called. It is called 
        recursively 
        for the whole class hierarchy, starting with the highest 
        level.

        Extra doc: https://github.com/casadi/casadi/wiki/L_o7

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L98

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L98-L98




        """
        return _casadi.Callback_finalize(self, *args)


    def eval(self, *args) -> "std::vector< casadi::DM,std::allocator< casadi::DM > >":
        """
          [INTERNAL] 

        ::

          eval(self, [DM] arg) -> [DM]

        Evaluate numerically, using temporary matrices and work vectors.

        This signature is not thread-safe. For guaranteed thread-safety, use  
        eval_buffer

        Extra doc: https://github.com/casadi/casadi/wiki/L_o8

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L106

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L60-L62




        """
        return _casadi.Callback_eval(self, *args)


    def eval_buffer(self, *args) -> "int":
        """
          [INTERNAL] 

        ::

          eval_buffer(self, double const ** arg, [int] sizes_arg, double ** res, [int] sizes_res) -> int

        A copy-free low level interface.

        In Python, you will be passed two tuples of memoryview objects Note 
        that 
        only the structural nonzeros are present in the memoryview 
        objects/buffers.

        Make sure to override  has_eval_buffer() to indicate support for this 
        method.

        Extra doc: https://github.com/casadi/casadi/wiki/L_o9

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L116

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L53-L56




        """
        return _casadi.Callback_eval_buffer(self, *args)


    def has_eval_buffer(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_eval_buffer(self) -> bool

        Does the  Callback class support a copy-free low level interface
         ?

        Extra doc: https://github.com/casadi/casadi/wiki/L_265

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L122

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L57-L59




        """
        return _casadi.Callback_has_eval_buffer(self, *args)


    def get_n_in(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          get_n_in(self) -> int

        Get the number of inputs.

        This function is called during construction.

        Extra doc: https://github.com/casadi/casadi/wiki/L_oa

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L129

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L64-L66




        """
        return _casadi.Callback_get_n_in(self, *args)


    def get_n_out(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          get_n_out(self) -> int

        Get the number of outputs.

        This function is called during construction.

        Extra doc: https://github.com/casadi/casadi/wiki/L_ob

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L136

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L68-L70




        """
        return _casadi.Callback_get_n_out(self, *args)


    def get_sparsity_in(self, *args) -> "casadi::Sparsity":
        """
          [INTERNAL] 

        ::

          get_sparsity_in(self, int i) -> Sparsity

        Get the sparsity of an input.

        This function is called during construction.

        Extra doc: https://github.com/casadi/casadi/wiki/L_oc

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L143

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L72-L74




        """
        return _casadi.Callback_get_sparsity_in(self, *args)


    def get_sparsity_out(self, *args) -> "casadi::Sparsity":
        """
          [INTERNAL] 

        ::

          get_sparsity_out(self, int i) -> Sparsity

        Get the sparsity of an output.

        This function is called during construction.

        Extra doc: https://github.com/casadi/casadi/wiki/L_od

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L150

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L76-L78




        """
        return _casadi.Callback_get_sparsity_out(self, *args)


    def get_name_in(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          get_name_in(self, int i) -> str

        Get the name of an input.

        This function is called during construction.

        Extra doc: https://github.com/casadi/casadi/wiki/L_oe

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L157

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L80-L82




        """
        return _casadi.Callback_get_name_in(self, *args)


    def get_name_out(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          get_name_out(self, int i) -> str

        Get the name of an output.

        This function is called during construction.

        Extra doc: https://github.com/casadi/casadi/wiki/L_of

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L164

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L84-L86




        """
        return _casadi.Callback_get_name_out(self, *args)


    def uses_output(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          uses_output(self) -> bool

        Do the derivative functions need nondifferentiated outputs?

        Extra doc: https://github.com/casadi/casadi/wiki/L_og

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L169

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L88-L90




        """
        return _casadi.Callback_uses_output(self, *args)


    def get_factory(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          get_factory(self, str name, [str] s_in, [str] s_out, dict:[str] aux, dict opts) -> Function

        Customize calls to the function factory.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2de

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L174

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L92-L98




        """
        return _casadi.Callback_get_factory(self, *args)


    def has_jacobian(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_jacobian(self) -> bool

        Return Jacobian of all input elements with respect to all output

        elements.

        Extra doc: https://github.com/casadi/casadi/wiki/L_oh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L184

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L100-L102




        """
        return _casadi.Callback_has_jacobian(self, *args)


    def get_jacobian(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          get_jacobian(self, str name, [str] inames, [str] onames, dict opts) -> Function

        Return Jacobian of all input elements with respect to all output

        elements.

        Extra doc: https://github.com/casadi/casadi/wiki/L_oh

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L185

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L105-L110




        """
        return _casadi.Callback_get_jacobian(self, *args)


    def has_forward(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_forward(self, int nfwd) -> bool

        Return function that calculates forward derivatives.

        forward(nfwd) returns a cached instance if available, and calls   Function 
        get_forward(casadi_int nfwd) if no cached version is available.

        Extra doc: https://github.com/casadi/casadi/wiki/L_oi

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L199

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L120-L122




        """
        return _casadi.Callback_has_forward(self, *args)


    def get_forward(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          get_forward(self, int nfwd, str name, [str] inames, [str] onames, dict opts) -> Function

        Return function that calculates forward derivatives.

        forward(nfwd) returns a cached instance if available, and calls   Function 
        get_forward(casadi_int nfwd) if no cached version is available.

        Extra doc: https://github.com/casadi/casadi/wiki/L_oi

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L200

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L113-L118




        """
        return _casadi.Callback_get_forward(self, *args)


    def has_reverse(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_reverse(self, int nadj) -> bool

        Return function that calculates adjoint derivatives.

        reverse(nadj) returns a cached instance if available, and calls   Function 
        get_reverse(casadi_int nadj) if no cached version is available.

        Extra doc: https://github.com/casadi/casadi/wiki/L_oj

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L214

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L132-L134




        """
        return _casadi.Callback_has_reverse(self, *args)


    def get_reverse(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          get_reverse(self, int nadj, str name, [str] inames, [str] onames, dict opts) -> Function

        Return function that calculates adjoint derivatives.

        reverse(nadj) returns a cached instance if available, and calls   Function 
        get_reverse(casadi_int nadj) if no cached version is available.

        Extra doc: https://github.com/casadi/casadi/wiki/L_oj

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L215

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.cpp#L125-L130




        """
        return _casadi.Callback_get_reverse(self, *args)


    def has_jac_sparsity(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_jac_sparsity(self, int oind, int iind) -> bool

        Return sparsity of Jacobian of all input elements.

        with respect to all output elements

        Extra doc: https://github.com/casadi/casadi/wiki/L_ok

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L227

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L227-L227




        """
        return _casadi.Callback_has_jac_sparsity(self, *args)


    def get_jac_sparsity(self, *args) -> "casadi::Sparsity":
        """
          [INTERNAL] 

        ::

          get_jac_sparsity(self, int oind, int iind, bool symmetric) -> Sparsity

        Return sparsity of Jacobian of all input elements.

        with respect to all output elements

        Extra doc: https://github.com/casadi/casadi/wiki/L_ok

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L228

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/callback.hpp#L228-L229




        """
        return _casadi.Callback_get_jac_sparsity(self, *args)

    def __disown__(self):
        self.this.disown()
        _casadi.disown_Callback(self)
        return weakref_proxy(self)
Callback_swigregister = _casadi.Callback_swigregister
Callback_swigregister(Callback)

def Callback_type_name(*args) -> "std::string":
    """


    ::

      type_name() -> str



    """
    return _casadi.Callback_type_name(*args)

class GlobalOptions(_object):
    """
      [INTERNAL] 

    ::


    Collects global CasADi options.

    Note to developers: 
    use sparingly. Global options are - in general - a 
    rather bad idea

    this class must never be instantiated. Access its static members 
    directly 

    Joris Gillis

    Extra doc: https://github.com/casadi/casadi/wiki/L_23m

    C++ includes: global_options.hpp



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, GlobalOptions, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, GlobalOptions, name)
    __repr__ = _swig_repr

    def setSimplificationOnTheFly(*args) -> "void":
        """


        ::

          setSimplificationOnTheFly(bool flag)



        """
        return _casadi.GlobalOptions_setSimplificationOnTheFly(*args)

    setSimplificationOnTheFly = staticmethod(setSimplificationOnTheFly)

    def getSimplificationOnTheFly(*args) -> "bool":
        """


        ::

          getSimplificationOnTheFly() -> bool



        """
        return _casadi.GlobalOptions_getSimplificationOnTheFly(*args)

    getSimplificationOnTheFly = staticmethod(getSimplificationOnTheFly)

    def setHierarchicalSparsity(*args) -> "void":
        """


        ::

          setHierarchicalSparsity(bool flag)



        """
        return _casadi.GlobalOptions_setHierarchicalSparsity(*args)

    setHierarchicalSparsity = staticmethod(setHierarchicalSparsity)

    def getHierarchicalSparsity(*args) -> "bool":
        """


        ::

          getHierarchicalSparsity() -> bool



        """
        return _casadi.GlobalOptions_getHierarchicalSparsity(*args)

    getHierarchicalSparsity = staticmethod(getHierarchicalSparsity)

    def setCasadiPath(*args) -> "void":
        """


        ::

          setCasadiPath(str path)



        """
        return _casadi.GlobalOptions_setCasadiPath(*args)

    setCasadiPath = staticmethod(setCasadiPath)

    def getCasadiPath(*args) -> "std::string":
        """


        ::

          getCasadiPath() -> str



        """
        return _casadi.GlobalOptions_getCasadiPath(*args)

    getCasadiPath = staticmethod(getCasadiPath)

    def setCasadiIncludePath(*args) -> "void":
        """


        ::

          setCasadiIncludePath(str path)



        """
        return _casadi.GlobalOptions_setCasadiIncludePath(*args)

    setCasadiIncludePath = staticmethod(setCasadiIncludePath)

    def getCasadiIncludePath(*args) -> "std::string":
        """


        ::

          getCasadiIncludePath() -> str



        """
        return _casadi.GlobalOptions_getCasadiIncludePath(*args)

    getCasadiIncludePath = staticmethod(getCasadiIncludePath)

    def setMaxNumDir(*args) -> "void":
        """


        ::

          setMaxNumDir(int ndir)



        """
        return _casadi.GlobalOptions_setMaxNumDir(*args)

    setMaxNumDir = staticmethod(setMaxNumDir)

    def getMaxNumDir(*args) -> "casadi_int":
        """


        ::

          getMaxNumDir() -> int



        """
        return _casadi.GlobalOptions_getMaxNumDir(*args)

    getMaxNumDir = staticmethod(getMaxNumDir)

    def setCopyElisionMinSize(*args) -> "void":
        """


        ::

          setCopyElisionMinSize(int sz)



        """
        return _casadi.GlobalOptions_setCopyElisionMinSize(*args)

    setCopyElisionMinSize = staticmethod(setCopyElisionMinSize)

    def getCopyElisionMinSize(*args) -> "casadi_int":
        """


        ::

          getCopyElisionMinSize() -> int



        """
        return _casadi.GlobalOptions_getCopyElisionMinSize(*args)

    getCopyElisionMinSize = staticmethod(getCopyElisionMinSize)

    def __init__(self, *args):
        """


        ::

          GlobalOptions(GlobalOptions other)



        """
        this = _casadi.new_GlobalOptions(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_GlobalOptions
GlobalOptions_swigregister = _casadi.GlobalOptions_swigregister
GlobalOptions_swigregister(GlobalOptions)

def GlobalOptions_setSimplificationOnTheFly(*args) -> "void":
    """


    ::

      setSimplificationOnTheFly(bool flag)



    """
    return _casadi.GlobalOptions_setSimplificationOnTheFly(*args)

def GlobalOptions_getSimplificationOnTheFly(*args) -> "bool":
    """


    ::

      getSimplificationOnTheFly() -> bool



    """
    return _casadi.GlobalOptions_getSimplificationOnTheFly(*args)

def GlobalOptions_setHierarchicalSparsity(*args) -> "void":
    """


    ::

      setHierarchicalSparsity(bool flag)



    """
    return _casadi.GlobalOptions_setHierarchicalSparsity(*args)

def GlobalOptions_getHierarchicalSparsity(*args) -> "bool":
    """


    ::

      getHierarchicalSparsity() -> bool



    """
    return _casadi.GlobalOptions_getHierarchicalSparsity(*args)

def GlobalOptions_setCasadiPath(*args) -> "void":
    """


    ::

      setCasadiPath(str path)



    """
    return _casadi.GlobalOptions_setCasadiPath(*args)

def GlobalOptions_getCasadiPath(*args) -> "std::string":
    """


    ::

      getCasadiPath() -> str



    """
    return _casadi.GlobalOptions_getCasadiPath(*args)

def GlobalOptions_setCasadiIncludePath(*args) -> "void":
    """


    ::

      setCasadiIncludePath(str path)



    """
    return _casadi.GlobalOptions_setCasadiIncludePath(*args)

def GlobalOptions_getCasadiIncludePath(*args) -> "std::string":
    """


    ::

      getCasadiIncludePath() -> str



    """
    return _casadi.GlobalOptions_getCasadiIncludePath(*args)

def GlobalOptions_setMaxNumDir(*args) -> "void":
    """


    ::

      setMaxNumDir(int ndir)



    """
    return _casadi.GlobalOptions_setMaxNumDir(*args)

def GlobalOptions_getMaxNumDir(*args) -> "casadi_int":
    """


    ::

      getMaxNumDir() -> int



    """
    return _casadi.GlobalOptions_getMaxNumDir(*args)

def GlobalOptions_setCopyElisionMinSize(*args) -> "void":
    """


    ::

      setCopyElisionMinSize(int sz)



    """
    return _casadi.GlobalOptions_setCopyElisionMinSize(*args)

def GlobalOptions_getCopyElisionMinSize(*args) -> "casadi_int":
    """


    ::

      getCopyElisionMinSize() -> int



    """
    return _casadi.GlobalOptions_getCopyElisionMinSize(*args)

class CasadiMeta(_object):
    """
      [INTERNAL] 

    ::


    Collects global CasADi meta information.

    Joris Gillis

    Extra doc: https://github.com/casadi/casadi/wiki/L_23k

    C++ includes: casadi_meta.hpp



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, CasadiMeta, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, CasadiMeta, name)
    __repr__ = _swig_repr

    def version(*args) -> "char const *":
        """


        ::

          version() -> char const *



        """
        return _casadi.CasadiMeta_version(*args)

    version = staticmethod(version)

    def git_revision(*args) -> "char const *":
        """


        ::

          git_revision() -> char const *



        """
        return _casadi.CasadiMeta_git_revision(*args)

    git_revision = staticmethod(git_revision)

    def git_describe(*args) -> "char const *":
        """


        ::

          git_describe() -> char const *



        """
        return _casadi.CasadiMeta_git_describe(*args)

    git_describe = staticmethod(git_describe)

    def feature_list(*args) -> "char const *":
        """


        ::

          feature_list() -> char const *



        """
        return _casadi.CasadiMeta_feature_list(*args)

    feature_list = staticmethod(feature_list)

    def build_type(*args) -> "char const *":
        """


        ::

          build_type() -> char const *



        """
        return _casadi.CasadiMeta_build_type(*args)

    build_type = staticmethod(build_type)

    def compiler_id(*args) -> "char const *":
        """


        ::

          compiler_id() -> char const *



        """
        return _casadi.CasadiMeta_compiler_id(*args)

    compiler_id = staticmethod(compiler_id)

    def compiler(*args) -> "char const *":
        """


        ::

          compiler() -> char const *



        """
        return _casadi.CasadiMeta_compiler(*args)

    compiler = staticmethod(compiler)

    def compiler_flags(*args) -> "char const *":
        """


        ::

          compiler_flags() -> char const *



        """
        return _casadi.CasadiMeta_compiler_flags(*args)

    compiler_flags = staticmethod(compiler_flags)

    def modules(*args) -> "char const *":
        """


        ::

          modules() -> char const *



        """
        return _casadi.CasadiMeta_modules(*args)

    modules = staticmethod(modules)

    def plugins(*args) -> "char const *":
        """


        ::

          plugins() -> char const *



        """
        return _casadi.CasadiMeta_plugins(*args)

    plugins = staticmethod(plugins)

    def install_prefix(*args) -> "char const *":
        """


        ::

          install_prefix() -> char const *



        """
        return _casadi.CasadiMeta_install_prefix(*args)

    install_prefix = staticmethod(install_prefix)

    def shared_library_prefix(*args) -> "char const *":
        """


        ::

          shared_library_prefix() -> char const *



        """
        return _casadi.CasadiMeta_shared_library_prefix(*args)

    shared_library_prefix = staticmethod(shared_library_prefix)

    def shared_library_suffix(*args) -> "char const *":
        """


        ::

          shared_library_suffix() -> char const *



        """
        return _casadi.CasadiMeta_shared_library_suffix(*args)

    shared_library_suffix = staticmethod(shared_library_suffix)

    def object_file_suffix(*args) -> "char const *":
        """


        ::

          object_file_suffix() -> char const *



        """
        return _casadi.CasadiMeta_object_file_suffix(*args)

    object_file_suffix = staticmethod(object_file_suffix)

    def swig_flags(*args) -> "char const *":
        """


        ::

          swig_flags() -> char const *



        """
        return _casadi.CasadiMeta_swig_flags(*args)

    swig_flags = staticmethod(swig_flags)

    def __init__(self, *args):
        """


        ::

          CasadiMeta(CasadiMeta other)



        """
        this = _casadi.new_CasadiMeta(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_CasadiMeta
CasadiMeta_swigregister = _casadi.CasadiMeta_swigregister
CasadiMeta_swigregister(CasadiMeta)

def CasadiMeta_version(*args) -> "char const *":
    """


    ::

      version() -> char const *



    """
    return _casadi.CasadiMeta_version(*args)

def CasadiMeta_git_revision(*args) -> "char const *":
    """


    ::

      git_revision() -> char const *



    """
    return _casadi.CasadiMeta_git_revision(*args)

def CasadiMeta_git_describe(*args) -> "char const *":
    """


    ::

      git_describe() -> char const *



    """
    return _casadi.CasadiMeta_git_describe(*args)

def CasadiMeta_feature_list(*args) -> "char const *":
    """


    ::

      feature_list() -> char const *



    """
    return _casadi.CasadiMeta_feature_list(*args)

def CasadiMeta_build_type(*args) -> "char const *":
    """


    ::

      build_type() -> char const *



    """
    return _casadi.CasadiMeta_build_type(*args)

def CasadiMeta_compiler_id(*args) -> "char const *":
    """


    ::

      compiler_id() -> char const *



    """
    return _casadi.CasadiMeta_compiler_id(*args)

def CasadiMeta_compiler(*args) -> "char const *":
    """


    ::

      compiler() -> char const *



    """
    return _casadi.CasadiMeta_compiler(*args)

def CasadiMeta_compiler_flags(*args) -> "char const *":
    """


    ::

      compiler_flags() -> char const *



    """
    return _casadi.CasadiMeta_compiler_flags(*args)

def CasadiMeta_modules(*args) -> "char const *":
    """


    ::

      modules() -> char const *



    """
    return _casadi.CasadiMeta_modules(*args)

def CasadiMeta_plugins(*args) -> "char const *":
    """


    ::

      plugins() -> char const *



    """
    return _casadi.CasadiMeta_plugins(*args)

def CasadiMeta_install_prefix(*args) -> "char const *":
    """


    ::

      install_prefix() -> char const *



    """
    return _casadi.CasadiMeta_install_prefix(*args)

def CasadiMeta_shared_library_prefix(*args) -> "char const *":
    """


    ::

      shared_library_prefix() -> char const *



    """
    return _casadi.CasadiMeta_shared_library_prefix(*args)

def CasadiMeta_shared_library_suffix(*args) -> "char const *":
    """


    ::

      shared_library_suffix() -> char const *



    """
    return _casadi.CasadiMeta_shared_library_suffix(*args)

def CasadiMeta_object_file_suffix(*args) -> "char const *":
    """


    ::

      object_file_suffix() -> char const *



    """
    return _casadi.CasadiMeta_object_file_suffix(*args)

def CasadiMeta_swig_flags(*args) -> "char const *":
    """


    ::

      swig_flags() -> char const *



    """
    return _casadi.CasadiMeta_swig_flags(*args)


def collocation_points(*args) -> "std::vector< double,std::allocator< double > >":
    """
      [INTERNAL] 

    ::

      collocation_points(int order, str scheme) -> [float]

    Obtain collocation points of specific order and scheme.

    Parameters:
    -----------

    order: 
    Which order (1 to 9 supported)

    scheme: 
    'radau' or 'legendre'

    Extra doc: https://github.com/casadi/casadi/wiki/L_1so

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L120

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L120-L122




    """
    return _casadi.collocation_points(*args)

def collocation_interpolators(*args) -> "std::vector< std::vector< double > > &, std::vector< double > &":
    """
      [INTERNAL] 

    ::

      collocation_interpolators([float] tau) -> ([[float]] OUTPUT, [float] OUTPUT)

    Obtain collocation interpolating matrices.

    A collocation method poses a polynomial Pi that interpolates exactly 

    through an initial state (0,X_0) and helper states at collocation 
    points 
    (tau_j,X:collPoint(j)).

    This function computes the linear mapping between dPi/dt and 
    coefficients 
    Z=[X_0 X:collPoints].

    Parameters:
    -----------

    tau: 
    location of collocation points, as obtained from collocation_points

    C: 
    interpolating coefficients to obtain derivatives. Length: order+1, 

    order+1



    ::

    dPi/dt @Z_j = (1/h) Sum_i C[j][i]*Z_i,



    with h the length of the integration interval.

    Parameters:
    -----------

    D: 
    interpolating coefficients to obtain end state. Length: order+1



    ::

    Pi @X_f = Sum_i D[i]*Z_i



    Extra doc: https://github.com/casadi/casadi/wiki/L_1sp

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L189

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L189-L231




    """
    return _casadi.collocation_interpolators(*args)

def collocation_coeff(*args) -> "casadi::Matrix< double > &, casadi::Matrix< double > &, casadi::Matrix< double > &":
    """
      [INTERNAL] 

    ::

      collocation_coeff([float] tau) -> (DM OUTPUT, DM OUTPUT, DM OUTPUT)

    Obtain collocation interpolating matrices.

    A collocation method poses a polynomial Pi that interpolates exactly 

    through an initial state (0,X_0) and helper states at collocation 
    points 
    (tau_j,Xc_j) with j=1..degree.

    This function computes the linear mapping between dPi/dt and 
    coefficients 
    Z=[X_0 Xc].

    Parameters:
    -----------

    tau: 
    location of collocation points (length: degree), as obtained from 

    collocation_points

    C: 
    interpolating coefficients to obtain derivatives. Size: (degree+1)-by-

    degree

    You may find the slopes of Pi at the collocation points as

    ::

    dPi/dt @ Xc = (1/h) Z*C,



    with h the length of the integration interval.

    Parameters:
    -----------

    D: 
    interpolating coefficients to obtain end state. Size: (degree+1)-by-1

    You may find the end point of Pi as

    ::

    Pi @X_f = Z*D



    Parameters:
    -----------

    B: 
    quadrature coefficients Size: degree-by-1

    Given quadrature righ-hand-sides 'quad' evaluated at the collocation 

    points, you may find the integrated quadratures as

    ::

    q = quad*B*h



    Extra doc: https://github.com/casadi/casadi/wiki/L_1sq

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L233

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L233-L287




    """
    return _casadi.collocation_coeff(*args)
LEGENDRE = _casadi.LEGENDRE
RADAU = _casadi.RADAU

def simpleRK(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      simpleRK(Function f, int N, int order) -> Function

    Construct an explicit Runge-Kutta integrator.

    The constructed function has three inputs, corresponding to initial 
    state 
    (x0), parameter (p) and integration time (h) and one output, 
    corresponding 
    to final state (xf).

    Parameters:
    -----------

    f: 
    ODE function with two inputs (x and p) and one output (xdot)

    N: 
    Number of integrator steps

    order: 
    Order of interpolating polynomials

    Extra doc: https://github.com/casadi/casadi/wiki/L_1sr

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L128

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L128-L187




    """
    return _casadi.simpleRK(*args)

def simpleIRK(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      simpleIRK(Function f, int N, int order, str scheme, str solver, dict solver_options) -> Function

    Construct an implicit Runge-Kutta integrator using a collocation

    scheme.

    The constructed function has three inputs, corresponding to initial 
    state 
    (x0), parameter (p) and integration time (h) and one output, 
    corresponding 
    to final state (xf).

    Parameters:
    -----------

    f: 
    ODE function with two inputs (x and p) and one output (xdot)

    N: 
    Number of integrator steps

    order: 
    Order of interpolating polynomials

    scheme: 
     Collocation scheme, as excepted by collocationPoints function.

    solver: 
    Solver plugin

    solver_options: 
    Options to be passed to the solver plugin

    Extra doc: https://github.com/casadi/casadi/wiki/L_1ss

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L289

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L289-L354




    """
    return _casadi.simpleIRK(*args)

def simpleIntegrator(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      simpleIntegrator(Function f, str integrator, dict integrator_options) -> Function

    Simplified wrapper for the  Integrator class.

    Extra doc: https://github.com/casadi/casadi/wiki/L_1st

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L356

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L356-L395




    """
    return _casadi.simpleIntegrator(*args)

def dae_reduce_index(*args) -> "std::map< std::string,casadi::GenericType > &":
    """
      [INTERNAL] 

    ::

      dae_reduce_index(dict:SX dae, dict opts) -> (dict:SX , dict OUTPUT)
      dae_reduce_index(dict:MX dae, dict opts) -> (dict:MX , dict OUTPUT)

    Reduce index.

    Index reduction leads to a new set of variables and equations.

    In the process, a set of constraints (algebraic equations or 
    derivatives) 
    a.k.a invariants is constructed that are invariant to the
     problem: whenever
     an initial point satisfies these constraints, the 
    boundary-value-problem 
    outcome will keep satisfying those constraints 
    automatically, even though 
    they are  not part of the reduced DAE.

    For any practical numerical integration method, there will be 
    numerical 
    drift away from satisfaction of those constraints. In other 
    words, you will
     see the value of invariants slowly moving away from 
    original zero.

    A classic mitigation technique is Baumgarte stabilization: you add 
    these 
    invariants to the reduced DAE as a correction term that acts in 
    a way to 
    make small (numerical) perturbations to the invariants decay 
    to the origin 
    as a dampened linear system.

    in which a certain set of constraints (algebraic equations or 
    derivatives) 
    has been dropped in favour of

    Parameters:
    -----------

    dae: 
    Expression dictionary describing the DAE

    Each value must be a dense column vector.

    keys:
    x_impl: symbol for implicit differential states

    dx_impl: symbol for implicit differential state derivatives

    z: symbol for algebraic variables

    alg: expression for algebraic equations

    t: symbol for time

    p: symbol for parameters

    Parameters:
    -----------

    opts: 
    Option dictionary

    'baumgarte_pole': double Poles (inverse time constants) of the 
    Baumgarte 
    invariant correction term. Must be <0 to dampen out 
    perturbations 0 
    (default) amounts to no correction. Corresponds to 
    -gamma of equation (1.5)
     in Ascher, Uri M., Hongsheng Chin, and 
    Sebastian Reich. "Stabilization of
     DAEs and invariant manifolds." 
    Numerische Mathematik 67.2 (1994): 
    131-149.

    Parameters:
    -----------

    stats: 
    Statistics

    Expression dictionary describing the reduced DAE

    In addition the fields allowed in the input DAE, the following keys 
    occur:

    x: symbol for explicit differential states

    ode: expression for right-hand-side of explicit differential states

    I: expression for invariants

    Extra doc: https://github.com/casadi/casadi/wiki/L_23h

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L1071

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L1071-L1073



    .......

    ::

      dae_reduce_index(dict:SX dae, dict opts)



    [INTERNAL] 
    Reduce index.

    Index reduction leads to a new set of variables and equations.

    In the process, a set of constraints (algebraic equations or 
    derivatives) 
    a.k.a invariants is constructed that are invariant to the
     problem: whenever
     an initial point satisfies these constraints, the 
    boundary-value-problem 
    outcome will keep satisfying those constraints 
    automatically, even though 
    they are  not part of the reduced DAE.

    For any practical numerical integration method, there will be 
    numerical 
    drift away from satisfaction of those constraints. In other 
    words, you will
     see the value of invariants slowly moving away from 
    original zero.

    A classic mitigation technique is Baumgarte stabilization: you add 
    these 
    invariants to the reduced DAE as a correction term that acts in 
    a way to 
    make small (numerical) perturbations to the invariants decay 
    to the origin 
    as a dampened linear system.

    in which a certain set of constraints (algebraic equations or 
    derivatives) 
    has been dropped in favour of

    Parameters:
    -----------

    dae: 
    Expression dictionary describing the DAE

    Each value must be a dense column vector.

    keys:
    x_impl: symbol for implicit differential states

    dx_impl: symbol for implicit differential state derivatives

    z: symbol for algebraic variables

    alg: expression for algebraic equations

    t: symbol for time

    p: symbol for parameters

    Parameters:
    -----------

    opts: 
    Option dictionary

    'baumgarte_pole': double Poles (inverse time constants) of the 
    Baumgarte 
    invariant correction term. Must be <0 to dampen out 
    perturbations 0 
    (default) amounts to no correction. Corresponds to 
    -gamma of equation (1.5)
     in Ascher, Uri M., Hongsheng Chin, and 
    Sebastian Reich. "Stabilization of
     DAEs and invariant manifolds." 
    Numerische Mathematik 67.2 (1994): 
    131-149.

    Parameters:
    -----------

    stats: 
    Statistics

    Expression dictionary describing the reduced DAE

    In addition the fields allowed in the input DAE, the following keys 
    occur:

    x: symbol for explicit differential states

    ode: expression for right-hand-side of explicit differential states

    I: expression for invariants

    Extra doc: https://github.com/casadi/casadi/wiki/L_23h

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L1071

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L1071-L1073



    .............


    .......

    ::

      dae_reduce_index(dict:MX dae, dict opts)



    [INTERNAL] 
    Reduce index.

    Index reduction leads to a new set of variables and equations.

    In the process, a set of constraints (algebraic equations or 
    derivatives) 
    a.k.a invariants is constructed that are invariant to the
     problem: whenever
     an initial point satisfies these constraints, the 
    boundary-value-problem 
    outcome will keep satisfying those constraints 
    automatically, even though 
    they are  not part of the reduced DAE.

    For any practical numerical integration method, there will be 
    numerical 
    drift away from satisfaction of those constraints. In other 
    words, you will
     see the value of invariants slowly moving away from 
    original zero.

    A classic mitigation technique is Baumgarte stabilization: you add 
    these 
    invariants to the reduced DAE as a correction term that acts in 
    a way to 
    make small (numerical) perturbations to the invariants decay 
    to the origin 
    as a dampened linear system.

    in which a certain set of constraints (algebraic equations or 
    derivatives) 
    has been dropped in favour of

    Parameters:
    -----------

    dae: 
    Expression dictionary describing the DAE

    Each value must be a dense column vector.

    keys:
    x_impl: symbol for implicit differential states

    dx_impl: symbol for implicit differential state derivatives

    z: symbol for algebraic variables

    alg: expression for algebraic equations

    t: symbol for time

    p: symbol for parameters

    Parameters:
    -----------

    opts: 
    Option dictionary

    'baumgarte_pole': double Poles (inverse time constants) of the 
    Baumgarte 
    invariant correction term. Must be <0 to dampen out 
    perturbations 0 
    (default) amounts to no correction. Corresponds to 
    -gamma of equation (1.5)
     in Ascher, Uri M., Hongsheng Chin, and 
    Sebastian Reich. "Stabilization of
     DAEs and invariant manifolds." 
    Numerische Mathematik 67.2 (1994): 
    131-149.

    Parameters:
    -----------

    stats: 
    Statistics

    Expression dictionary describing the reduced DAE

    In addition the fields allowed in the input DAE, the following keys 
    occur:

    x: symbol for explicit differential states

    ode: expression for right-hand-side of explicit differential states

    I: expression for invariants

    Extra doc: https://github.com/casadi/casadi/wiki/L_23h

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L1067

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L1067-L1069



    .............



    """
    return _casadi.dae_reduce_index(*args)

def dae_map_semi_expl(*args) -> "casadi::Function &, casadi::Function &":
    """
      [INTERNAL] 

    ::

      dae_map_semi_expl(dict:SX dae, dict:SX dae_red) -> (dict:SX , Function OUTPUT, Function OUTPUT)
      dae_map_semi_expl(dict:MX dae, dict:MX dae_red) -> (dict:MX , Function OUTPUT, Function OUTPUT)

    Turn a reduced DAE into a semi explicit form suitable for CasADi

    integrator.

    Parameters:
    -----------

    dae: 
    Original (unreduced) DAE structure

    dae_red: 
    Reduced DAE (see dae_reduce_index)

    state_to_orig: 
    A mapping of integrator (semi explicit) states to states of 
    the 
    original DAE

    phi: 
    A function to compute the invariants of the reduced DAE Inputs:
    x and 
    z: (semi explicit) integrator states; typically integrator 
    outputs xf and 
    zf

    p: parameters

    t: time

    Semi explicit DAE dictionary, suitable to pass to a CasADi integrator

    See: 
     dae_reduce_index

    Extra doc: https://github.com/casadi/casadi/wiki/L_1su

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L1216

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L1216-L1219



    .......

    ::

      dae_map_semi_expl(dict:SX dae, dict:SX dae_red)



    [INTERNAL] 
    Turn a reduced DAE into a semi explicit form suitable for CasADi

    integrator.

    Parameters:
    -----------

    dae: 
    Original (unreduced) DAE structure

    dae_red: 
    Reduced DAE (see dae_reduce_index)

    state_to_orig: 
    A mapping of integrator (semi explicit) states to states of 
    the 
    original DAE

    phi: 
    A function to compute the invariants of the reduced DAE Inputs:
    x and 
    z: (semi explicit) integrator states; typically integrator 
    outputs xf and 
    zf

    p: parameters

    t: time

    Semi explicit DAE dictionary, suitable to pass to a CasADi integrator

    See: 
     dae_reduce_index

    Extra doc: https://github.com/casadi/casadi/wiki/L_1su

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L1216

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L1216-L1219



    .............


    .......

    ::

      dae_map_semi_expl(dict:MX dae, dict:MX dae_red)



    [INTERNAL] 
    Turn a reduced DAE into a semi explicit form suitable for CasADi

    integrator.

    Parameters:
    -----------

    dae: 
    Original (unreduced) DAE structure

    dae_red: 
    Reduced DAE (see dae_reduce_index)

    state_to_orig: 
    A mapping of integrator (semi explicit) states to states of 
    the 
    original DAE

    phi: 
    A function to compute the invariants of the reduced DAE Inputs:
    x and 
    z: (semi explicit) integrator states; typically integrator 
    outputs xf and 
    zf

    p: parameters

    t: time

    Semi explicit DAE dictionary, suitable to pass to a CasADi integrator

    See: 
     dae_reduce_index

    Extra doc: https://github.com/casadi/casadi/wiki/L_1su

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L1211

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L1211-L1214



    .............



    """
    return _casadi.dae_map_semi_expl(*args)

def dae_init_gen(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      dae_init_gen(dict:SX dae, dict:SX dae_red, str init_solver, dict:DM init_strength, dict init_solver_options) -> Function
      dae_init_gen(dict:MX dae, dict:MX dae_red, str init_solver, dict:DM init_strength, dict init_solver_options) -> Function

    Obtain a generator  Function for producing consistent initial 
    guesses of a reduced DAE.

    Parameters:
    -----------

    dae: 
    Original (unreduced) DAE structure

    dae_red: 
    Reduced DAE (see dae_reduce_index)

    init_solver: 
    NLP solver plugin name for nlpsol used to construct an initial
     guess

    init_strength: 
    Influence the nature of the NLP Structure with keys x_impl, 
    dx_impl, z
     corresponding to inputs of init_gen Each key maps to a DM that 
    should
     match the variable size corresponding to that key. For each variable

    the meaning of the corresponding DM value is as follows: When >=0, 

    indicates that the provided initial guess is used in a quadratic 
    penalty 
    (value used as weight) When -1, indicates that the provided 
    initial guess 
    must be observed (simple bound on variable)

    init_solver_options: 
    NLP solver options to be passed to nlpsol

    init_gen A function to generate a consistent initial guess that can be
     used
     to pass to an integrator constructed from a semi explict reduced
     DAE 
    Inputs:
    x_impl, dx_impl, z: initial guesses in the original DAE space

    p: parameters

    t: time Outputs:

    x0, z0: (semi explicit) integrator states and algebraic variables; 

    typically used as input for integrators

    See: 
     dae_reduce_index

    Extra doc: https://github.com/casadi/casadi/wiki/L_1sv

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L1226

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L1226-L1229



    .......

    ::

      dae_init_gen(dict:SX dae, dict:SX dae_red, str init_solver, dict:DM init_strength, dict init_solver_options)



    [INTERNAL] 
    Obtain a generator  Function for producing consistent initial 
    guesses of a reduced DAE.

    Parameters:
    -----------

    dae: 
    Original (unreduced) DAE structure

    dae_red: 
    Reduced DAE (see dae_reduce_index)

    init_solver: 
    NLP solver plugin name for nlpsol used to construct an initial
     guess

    init_strength: 
    Influence the nature of the NLP Structure with keys x_impl, 
    dx_impl, z
     corresponding to inputs of init_gen Each key maps to a DM that 
    should
     match the variable size corresponding to that key. For each variable

    the meaning of the corresponding DM value is as follows: When >=0, 

    indicates that the provided initial guess is used in a quadratic 
    penalty 
    (value used as weight) When -1, indicates that the provided 
    initial guess 
    must be observed (simple bound on variable)

    init_solver_options: 
    NLP solver options to be passed to nlpsol

    init_gen A function to generate a consistent initial guess that can be
     used
     to pass to an integrator constructed from a semi explict reduced
     DAE 
    Inputs:
    x_impl, dx_impl, z: initial guesses in the original DAE space

    p: parameters

    t: time Outputs:

    x0, z0: (semi explicit) integrator states and algebraic variables; 

    typically used as input for integrators

    See: 
     dae_reduce_index

    Extra doc: https://github.com/casadi/casadi/wiki/L_1sv

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L1226

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L1226-L1229



    .............


    .......

    ::

      dae_init_gen(dict:MX dae, dict:MX dae_red, str init_solver, dict:DM init_strength, dict init_solver_options)



    [INTERNAL] 
    Obtain a generator  Function for producing consistent initial 
    guesses of a reduced DAE.

    Parameters:
    -----------

    dae: 
    Original (unreduced) DAE structure

    dae_red: 
    Reduced DAE (see dae_reduce_index)

    init_solver: 
    NLP solver plugin name for nlpsol used to construct an initial
     guess

    init_strength: 
    Influence the nature of the NLP Structure with keys x_impl, 
    dx_impl, z
     corresponding to inputs of init_gen Each key maps to a DM that 
    should
     match the variable size corresponding to that key. For each variable

    the meaning of the corresponding DM value is as follows: When >=0, 

    indicates that the provided initial guess is used in a quadratic 
    penalty 
    (value used as weight) When -1, indicates that the provided 
    initial guess 
    must be observed (simple bound on variable)

    init_solver_options: 
    NLP solver options to be passed to nlpsol

    init_gen A function to generate a consistent initial guess that can be
     used
     to pass to an integrator constructed from a semi explict reduced
     DAE 
    Inputs:
    x_impl, dx_impl, z: initial guesses in the original DAE space

    p: parameters

    t: time Outputs:

    x0, z0: (semi explicit) integrator states and algebraic variables; 

    typically used as input for integrators

    See: 
     dae_reduce_index

    Extra doc: https://github.com/casadi/casadi/wiki/L_1sv

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.hpp#L1221

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/integration_tools.cpp#L1221-L1224



    .............



    """
    return _casadi.dae_init_gen(*args)

def detect_simple_bounds(*args) -> "std::vector< casadi_int > &, casadi::MX &, casadi::MX &, casadi::Function &, casadi::Function &":
    """
      [INTERNAL] 

    ::

      detect_simple_bounds(SX xX, SX p, SX g, SX lbg, SX ubg) -> ([int] OUTPUT, SX OUTPUT, SX OUTPUT, Function OUTPUT, Function OUTPUT)
      detect_simple_bounds(MX xX, MX p, MX g, MX lbg, MX ubg) -> ([int] OUTPUT, MX OUTPUT, MX OUTPUT, Function OUTPUT, Function OUTPUT)


    .......

    ::

      detect_simple_bounds(SX xX, SX p, SX g, SX lbg, SX ubg)



    [INTERNAL] 
    Detect simple bounds from general constraints.

    Given parametric constraints:

    ::

      *   subject to lbg(p) <= g(x,p) <= ubg(p)
      * 



    Returns an equivalent set

    ::

      *   subject to  lbg(p)(gi) <= g(x,p)(gi) <= ubg(p)(gi)
      *               lbx(p) <= x                 <= ubx(p)
      * 



    Parameters:
    -----------

    lam_forward: 
    (lam_g,p)->(lam_sg,lam_x)

    lam_backward: 
    (lam_sg,lam_x,p)->(lam_g)

    Extra doc: https://github.com/casadi/casadi/wiki/L_1sw

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlp_tools.hpp#L217

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/nlp_tools.cpp#L217-L225



    .............


    .......

    ::

      detect_simple_bounds(MX xX, MX p, MX g, MX lbg, MX ubg)



    [INTERNAL] 

    .............



    """
    return _casadi.detect_simple_bounds(*args)

def external_transform(*args) -> "casadi::Function":
    """
      [INTERNAL] 

    ::

      external_transform(str name, str op, Function f, dict opts) -> Function

    Apply a transformation defined externally.

    Parameters:
    -----------

    name: 
    Name of the shared library

    op: 
    Name of the operation

    f: 
     Function to transform

    opts: 
    Options

    ::

      Extra doc: https://github.com/casadi/casadi/wiki/L_27i 




    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/tools.hpp#L45

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/tools.cpp#L45-L77



    """
    return _casadi.external_transform(*args)
class NlpBuilder(PrintableCommon):
    """
      [INTERNAL] 

    ::


    A symbolic NLP representation.

    Joel Andersson

    ::

      Extra doc: https://github.com/casadi/casadi/wiki/L_1e2 




    C++ includes: nlp_builder.hpp



    """

    __swig_setmethods__ = {}
    for _s in [PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, NlpBuilder, name, value)
    __swig_getmethods__ = {}
    for _s in [PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, NlpBuilder, name)
    __repr__ = _swig_repr
    __swig_getmethods__["x"] = _casadi.NlpBuilder_x_get
    if _newclass:
        x = _swig_property(_casadi.NlpBuilder_x_get)
    __swig_getmethods__["f"] = _casadi.NlpBuilder_f_get
    if _newclass:
        f = _swig_property(_casadi.NlpBuilder_f_get)
    __swig_getmethods__["g"] = _casadi.NlpBuilder_g_get
    if _newclass:
        g = _swig_property(_casadi.NlpBuilder_g_get)
    __swig_getmethods__["x_lb"] = _casadi.NlpBuilder_x_lb_get
    if _newclass:
        x_lb = _swig_property(_casadi.NlpBuilder_x_lb_get)
    __swig_getmethods__["x_ub"] = _casadi.NlpBuilder_x_ub_get
    if _newclass:
        x_ub = _swig_property(_casadi.NlpBuilder_x_ub_get)
    __swig_getmethods__["g_lb"] = _casadi.NlpBuilder_g_lb_get
    if _newclass:
        g_lb = _swig_property(_casadi.NlpBuilder_g_lb_get)
    __swig_getmethods__["g_ub"] = _casadi.NlpBuilder_g_ub_get
    if _newclass:
        g_ub = _swig_property(_casadi.NlpBuilder_g_ub_get)
    __swig_getmethods__["x_init"] = _casadi.NlpBuilder_x_init_get
    if _newclass:
        x_init = _swig_property(_casadi.NlpBuilder_x_init_get)
    __swig_getmethods__["lambda_init"] = _casadi.NlpBuilder_lambda_init_get
    if _newclass:
        lambda_init = _swig_property(_casadi.NlpBuilder_lambda_init_get)
    __swig_getmethods__["discrete"] = _casadi.NlpBuilder_discrete_get
    if _newclass:
        discrete = _swig_property(_casadi.NlpBuilder_discrete_get)

    def import_nl(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          import_nl(self, str filename, dict opts)

        Import an .nl file.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/nlp_builder.hpp#L74

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/nlp_builder.cpp#L32-L35




        """
        return _casadi.NlpBuilder_import_nl(self, *args)


    def type_name(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          type_name(self) -> str

        Readable name of the class.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/nlp_builder.hpp#L77

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/nlp_builder.hpp#L77-L77




        """
        return _casadi.NlpBuilder_type_name(self, *args)


    def disp(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          disp(self, bool more)

        Print a description of the object.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/nlp_builder.hpp#L80

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/nlp_builder.cpp#L37-L45




        """
        return _casadi.NlpBuilder_disp(self, *args)


    def str(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          str(self, bool more) -> str

        Get string representation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/nlp_builder.hpp#L83

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/nlp_builder.hpp#L83-L87




        """
        return _casadi.NlpBuilder_str(self, *args)


    def __init__(self, *args):
        """


        ::

          NlpBuilder()
          NlpBuilder(NlpBuilder other)



        """
        this = _casadi.new_NlpBuilder(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_NlpBuilder
NlpBuilder_swigregister = _casadi.NlpBuilder_swigregister
NlpBuilder_swigregister(NlpBuilder)

class DaeBuilder(SharedObject, PrintableCommon):
    """
      [INTERNAL] 

    ::


    A symbolic representation of a differential-algebraic equations 
    model.

    Variables:
    ==========





    ::

      t:      independent variable (usually time)
      c:      constants
      p:      parameters
      d:      dependent parameters (time independent)
      u:      controls
      w:      dependent variables  (time dependent)
      x:      differential states
      z:      algebraic variables
      q:      quadrature states
      y:      outputs




    Equations:
    ==========





    ::

      differential equations: \\dot{x} ==  ode(...)
      algebraic equations:          0 ==  alg(...)
      quadrature equations:   \\dot{q} == quad(...)
      dependent parameters:         d == ddef(d_prev,p)
      dependent variables:          w == wdef(w_prev,x,z,u,p,t)
      output equations:             y == ydef(...)
      initial equations:     init_lhs == init_rhs(...)
      events:      when when_cond < 0: when_lhs := when_rhs




    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_5c

    C++ includes: dae_builder.hpp



    """

    __swig_setmethods__ = {}
    for _s in [SharedObject, PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, DaeBuilder, name, value)
    __swig_getmethods__ = {}
    for _s in [SharedObject, PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, DaeBuilder, name)
    __repr__ = _swig_repr

    def type_name(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          type_name(self) -> str

        Readable name of the class.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L74

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L74-L74




        """
        return _casadi.DaeBuilder_type_name(self, *args)


    def name(self, *args) -> "std::string const &":
        """
          [INTERNAL] 

        ::

          name(self) -> str

        Name of instance.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5d

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L86

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L59-L61




        """
        return _casadi.DaeBuilder_name(self, *args)


    def time(self, *args) -> "casadi::MX const &":
        """
          [INTERNAL] 

        ::

          time(self) -> MX

        Expression for independent variable (usually time)

        Extra doc: https://github.com/casadi/casadi/wiki/L_2by

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L93

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L63-L71




        """
        return _casadi.DaeBuilder_time(self, *args)


    def t_new(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          t_new(self) -> [str]

        Independent variable (usually time)

        Extra doc: https://github.com/casadi/casadi/wiki/L_2bz

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L98

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L98-L98




        """
        return _casadi.DaeBuilder_t_new(self, *args)


    def x(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          x(self) -> [str]

        Differential states.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5f

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L103

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L103-L103




        """
        return _casadi.DaeBuilder_x(self, *args)


    def y(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          y(self) -> [str]

        Outputs */.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L106

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L73-L80




        """
        return _casadi.DaeBuilder_y(self, *args)


    def ode(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          ode(self) -> [MX]

        Ordinary differential equations (ODE)

        Extra doc: https://github.com/casadi/casadi/wiki/L_5g

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L111

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L82-L89




        """
        return _casadi.DaeBuilder_ode(self, *args)


    def z(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          z(self) -> [str]

        Algebraic variables.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5h

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L116

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L116-L116




        """
        return _casadi.DaeBuilder_z(self, *args)


    def alg(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          alg(self) -> [MX]

        Algebraic equations.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5i

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L121

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L91-L98




        """
        return _casadi.DaeBuilder_alg(self, *args)


    def q(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          q(self) -> [str]

        Quadrature states.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5j

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L126

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L126-L126




        """
        return _casadi.DaeBuilder_q(self, *args)


    def quad(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          quad(self) -> [MX]

        Quadrature equations.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5k

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L131

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L100-L107




        """
        return _casadi.DaeBuilder_quad(self, *args)


    def zero(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          zero(self) -> [MX]

        Zero-crossing functions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2b0

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L136

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L109-L115




        """
        return _casadi.DaeBuilder_zero(self, *args)


    def ydef(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          ydef(self) -> [MX]

        Definitions of output variables.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5m

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L141

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L117-L124




        """
        return _casadi.DaeBuilder_ydef(self, *args)


    def set_y(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_y(self, [str] name)

        Set all output variables.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2db

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L146

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L126-L160




        """
        return _casadi.DaeBuilder_set_y(self, *args)


    def rate(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          rate(self) -> [str]

        Get all rate variables.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2dc

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L151

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L162-L169




        """
        return _casadi.DaeBuilder_rate(self, *args)


    def set_rate(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_rate(self, [str] name)

        Set rate variables.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2dd

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L156

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L171-L178




        """
        return _casadi.DaeBuilder_set_rate(self, *args)


    def u(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          u(self) -> [str]

        Free controls.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5n

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L161

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L161-L161




        """
        return _casadi.DaeBuilder_u(self, *args)


    def p(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          p(self) -> [str]

        Parameters.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5o

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L166

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L166-L166




        """
        return _casadi.DaeBuilder_p(self, *args)


    def c(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          c(self) -> [str]

        Named constants.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5p

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L171

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L171-L171




        """
        return _casadi.DaeBuilder_c(self, *args)


    def cdef(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          cdef(self) -> [MX]

        Definitions of named constants.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5q

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L176

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L180-L187




        """
        return _casadi.DaeBuilder_cdef(self, *args)


    def d(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          d(self) -> [str]

        Dependent parameters.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5r

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L181

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L181-L181




        """
        return _casadi.DaeBuilder_d(self, *args)


    def ddef(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          ddef(self) -> [MX]

        Definitions of dependent parameters.

        Interdependencies are allowed but must be non-cyclic.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5s

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L188

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L189-L196




        """
        return _casadi.DaeBuilder_ddef(self, *args)


    def w(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          w(self) -> [str]

        Dependent variables.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5t

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L193

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L193-L193




        """
        return _casadi.DaeBuilder_w(self, *args)


    def wdef(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          wdef(self) -> [MX]

        Dependent variables and corresponding definitions.

        Interdependencies are allowed but must be non-cyclic.

        Extra doc: https://github.com/casadi/casadi/wiki/L_5u

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L200

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L198-L205




        """
        return _casadi.DaeBuilder_wdef(self, *args)


    def init_lhs(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          init_lhs(self) -> [MX]

        Initial conditions, left-hand-side.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2b1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L205

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L207-L209




        """
        return _casadi.DaeBuilder_init_lhs(self, *args)


    def init_rhs(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          init_rhs(self) -> [MX]

        Initial conditions, right-hand-side.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2b2

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L210

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L211-L213




        """
        return _casadi.DaeBuilder_init_rhs(self, *args)


    def outputs(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          outputs(self) -> [str]

        Model structure: outputs.

        Extra doc: https://github.com/casadi/casadi/wiki/L_61

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L215

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L215-L222




        """
        return _casadi.DaeBuilder_outputs(self, *args)


    def derivatives(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          derivatives(self) -> [str]

        Model structure: derivatives.

        Extra doc: https://github.com/casadi/casadi/wiki/L_62

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L220

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L224-L231




        """
        return _casadi.DaeBuilder_derivatives(self, *args)


    def initial_unknowns(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          initial_unknowns(self) -> [str]

        Model structure: initial unknowns.

        Extra doc: https://github.com/casadi/casadi/wiki/L_63

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L225

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L233-L240




        """
        return _casadi.DaeBuilder_initial_unknowns(self, *args)


    def has_t(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_t(self) -> bool

        Is there a time variable?

        Extra doc: https://github.com/casadi/casadi/wiki/L_64

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L233

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L242-L249




        """
        return _casadi.DaeBuilder_has_t(self, *args)


    def has_rate(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_rate(self) -> bool

        Is there a rate output?

        Extra doc: https://github.com/casadi/casadi/wiki/L_2dg

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L238

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L251-L258




        """
        return _casadi.DaeBuilder_has_rate(self, *args)


    def nx(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nx(self) -> int

        Differential states.

        Extra doc: https://github.com/casadi/casadi/wiki/L_65

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L243

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L260-L262




        """
        return _casadi.DaeBuilder_nx(self, *args)


    def nz(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nz(self) -> int

        Algebraic variables.

        Extra doc: https://github.com/casadi/casadi/wiki/L_66

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L248

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L264-L266




        """
        return _casadi.DaeBuilder_nz(self, *args)


    def nq(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nq(self) -> int

        Quadrature states.

        Extra doc: https://github.com/casadi/casadi/wiki/L_67

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L253

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L268-L270




        """
        return _casadi.DaeBuilder_nq(self, *args)


    def nzero(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nzero(self) -> int

        Zero-crossing functions.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2cb

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L258

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L272-L274




        """
        return _casadi.DaeBuilder_nzero(self, *args)


    def ny(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          ny(self) -> int

         Output variables.

        Extra doc: https://github.com/casadi/casadi/wiki/L_68

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L263

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L276-L278




        """
        return _casadi.DaeBuilder_ny(self, *args)


    def nu(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nu(self) -> int

        Free controls.

        Extra doc: https://github.com/casadi/casadi/wiki/L_69

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L268

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L280-L282




        """
        return _casadi.DaeBuilder_nu(self, *args)


    def np(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          np(self) -> int

        Parameters.

        Extra doc: https://github.com/casadi/casadi/wiki/L_6a

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L273

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L284-L286




        """
        return _casadi.DaeBuilder_np(self, *args)


    def nc(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nc(self) -> int

        Named constants.

        Extra doc: https://github.com/casadi/casadi/wiki/L_6b

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L278

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L288-L290




        """
        return _casadi.DaeBuilder_nc(self, *args)


    def nd(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nd(self) -> int

        Dependent parameters.

        Extra doc: https://github.com/casadi/casadi/wiki/L_6c

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L283

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L292-L294




        """
        return _casadi.DaeBuilder_nd(self, *args)


    def nw(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          nw(self) -> int

        Dependent variables.

        Extra doc: https://github.com/casadi/casadi/wiki/L_6d

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L288

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L296-L298




        """
        return _casadi.DaeBuilder_nw(self, *args)


    def add(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          add(self, str name, dict opts) -> MX
          add(self, str name, str causality, dict opts) -> MX
          add(self, str name, str causality, str variability, dict opts) -> MX
          add(self, str name, str causality, str variability, MX expr, dict opts)

        Add a new model variable, symbolic expression already available.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L312

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L659-L672



        .......

        ::

          add(self, str name, str causality, str variability, MX expr, dict opts)



        [INTERNAL] 
        Add a new model variable, symbolic expression already available.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L312

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L659-L672



        .............


        .......

        ::

          add(self, str name, str causality, str variability, dict opts)



        [INTERNAL] 
        Add a new model variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L297

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L630-L639



        .............


        .......

        ::

          add(self, str name, dict opts)



        [INTERNAL] 
        Add a new model variable, default variability and causality.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L308

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L650-L657



        .............


        .......

        ::

          add(self, str name, str causality, dict opts)



        [INTERNAL] 
        Add a new model variable, default variability.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L303

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L641-L648



        .............



        """
        return _casadi.DaeBuilder_add(self, *args)


    def t(self, *args) -> "casadi::MX const &":
        """
          [DEPRECATED] Renamed "time"

        ::

          t(self) -> MX


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L320

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L320-L320




        """
        return _casadi.DaeBuilder_t(self, *args)


    def add_t(self, *args) -> "casadi::MX":
        """
          [DEPRECATED] Replaced by add

        ::

          add_t(self, str name) -> MX


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L323

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L675-L677




        """
        return _casadi.DaeBuilder_add_t(self, *args)


    def add_p(self, *args) -> "casadi::MX":
        """
          [DEPRECATED] Replaced by add

        ::

          add_p(self, str name) -> MX


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L326

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L679-L682




        """
        return _casadi.DaeBuilder_add_p(self, *args)


    def add_u(self, *args) -> "casadi::MX":
        """
          [DEPRECATED] Replaced by add

        ::

          add_u(self, str name) -> MX


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L329

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L684-L687




        """
        return _casadi.DaeBuilder_add_u(self, *args)


    def add_x(self, *args) -> "casadi::MX":
        """
          [DEPRECATED] Replaced by add

        ::

          add_x(self, str name) -> MX


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L332

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L689-L692




        """
        return _casadi.DaeBuilder_add_x(self, *args)


    def add_z(self, *args) -> "casadi::MX":
        """
          [DEPRECATED] Replaced by add

        ::

          add_z(self, str name) -> MX


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L335

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L694-L697




        """
        return _casadi.DaeBuilder_add_z(self, *args)


    def add_q(self, *args) -> "casadi::MX":
        """
          [DEPRECATED] Replaced by add

        ::

          add_q(self, str name) -> MX


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L338

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L699-L702




        """
        return _casadi.DaeBuilder_add_q(self, *args)


    def add_c(self, *args) -> "casadi::MX":
        """
          [DEPRECATED] Replaced by add and eq

        ::

          add_c(self, str name, MX new_cdef) -> MX


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L341

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L704-L708




        """
        return _casadi.DaeBuilder_add_c(self, *args)


    def add_d(self, *args) -> "casadi::MX":
        """
          [DEPRECATED] Replaced by add and eq

        ::

          add_d(self, str name, MX new_ddef) -> MX


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L344

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L710-L714




        """
        return _casadi.DaeBuilder_add_d(self, *args)


    def add_w(self, *args) -> "casadi::MX":
        """
          [DEPRECATED] Replaced by add and eq

        ::

          add_w(self, str name, MX new_wdef) -> MX


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L347

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L716-L720




        """
        return _casadi.DaeBuilder_add_w(self, *args)


    def add_y(self, *args) -> "casadi::MX":
        """
          [DEPRECATED] Replaced by add and eq

        ::

          add_y(self, str name, MX new_ydef) -> MX


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L350

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L722-L726




        """
        return _casadi.DaeBuilder_add_y(self, *args)


    def set_beq(self, *args) -> "void":
        """
          [DEPRECATED] Replaced by eq

        ::

          set_beq(self, str name, MX val)


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L353

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L728-L734




        """
        return _casadi.DaeBuilder_set_beq(self, *args)


    def eq(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          eq(self, MX lhs, MX rhs, dict opts)

        Add a simple equation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L358

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L738-L744




        """
        return _casadi.DaeBuilder_eq(self, *args)


    def when(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          when(self, MX cond, [str] eqs, dict opts)

        Add when equations.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L361

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L746-L752




        """
        return _casadi.DaeBuilder_when(self, *args)


    def assign(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          assign(self, str name, MX val) -> str

        Assignment inside a when-equation or if-else equation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L364

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L754-L761




        """
        return _casadi.DaeBuilder_assign(self, *args)


    def reinit(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          reinit(self, str name, MX val) -> str

        Reinitialize a state inside when-equations.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L367

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L763-L770




        """
        return _casadi.DaeBuilder_reinit(self, *args)


    def set_init(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_init(self, str name, MX init_rhs)

        Specify the initial equation for a variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L370

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L772-L778




        """
        return _casadi.DaeBuilder_set_init(self, *args)


    def set_ode(self, *args) -> "void":
        """
          [DEPRECATED] Replaced by eq

        ::

          set_ode(self, str name, MX ode_rhs)


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L374

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L374-L376




        """
        return _casadi.DaeBuilder_set_ode(self, *args)


    def set_alg(self, *args) -> "void":
        """
          [DEPRECATED] Replaced by eq

        ::

          set_alg(self, str name, MX alg_rhs)


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L379

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L379-L382




        """
        return _casadi.DaeBuilder_set_alg(self, *args)


    def add_init(self, *args) -> "void":
        """
          [DEPRECATED] Replaced by set_init

        ::

          add_init(self, MX lhs, MX rhs)


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L385

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L385-L387




        """
        return _casadi.DaeBuilder_add_init(self, *args)


    def ne(self, *args) -> "casadi_int":
        """
          [DEPRECATED] Replaced by  nzero()

        ::

          ne(self) -> int


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L390

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L390-L390




        """
        return _casadi.DaeBuilder_ne(self, *args)


    def e(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [DEPRECATED] Use all("zero") */

        ::

          e(self) -> [str]


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L393

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L393-L393




        """
        return _casadi.DaeBuilder_e(self, *args)


    def sanity_check(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          sanity_check(self)

        Check if dimensions match.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L398

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L780-L786




        """
        return _casadi.DaeBuilder_sanity_check(self, *args)


    def reorder(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          reorder(self, str cat, [str] v)

        Reorder variables in a category.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L402

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L615-L628




        """
        return _casadi.DaeBuilder_reorder(self, *args)


    def clear_all(self, *args) -> "void":
        """
          [DEPRECATED] Use set_variability, set_causality or set_category to 

        ::

          clear_all(self, str v)

        change 
        variable category

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L406

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L590-L597




        """
        return _casadi.DaeBuilder_clear_all(self, *args)


    def set_all(self, *args) -> "void":
        """
          [DEPRECATED] Use set_variability, set_causality, set_category and/or 

        ::

          set_all(self, str v, [str] name)


        reorder

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L409

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L599-L611




        """
        return _casadi.DaeBuilder_set_all(self, *args)


    def register_t(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          register_t(self, str name)



        """
        return _casadi.DaeBuilder_register_t(self, *args)


    def register_p(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          register_p(self, str name)



        """
        return _casadi.DaeBuilder_register_p(self, *args)


    def register_u(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          register_u(self, str name)



        """
        return _casadi.DaeBuilder_register_u(self, *args)


    def register_x(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          register_x(self, str name)



        """
        return _casadi.DaeBuilder_register_x(self, *args)


    def register_z(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          register_z(self, str name)



        """
        return _casadi.DaeBuilder_register_z(self, *args)


    def register_q(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          register_q(self, str name)



        """
        return _casadi.DaeBuilder_register_q(self, *args)


    def register_c(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          register_c(self, str name)



        """
        return _casadi.DaeBuilder_register_c(self, *args)


    def register_d(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          register_d(self, str name)



        """
        return _casadi.DaeBuilder_register_d(self, *args)


    def register_w(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          register_w(self, str name)



        """
        return _casadi.DaeBuilder_register_w(self, *args)


    def register_y(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          register_y(self, str name)



        """
        return _casadi.DaeBuilder_register_y(self, *args)


    def register_e(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          register_e(self, str name)



        """
        return _casadi.DaeBuilder_register_e(self, *args)


    def eliminate_d(self, *args) -> "void":
        """
          [DEPRECATED] Use eliminate("d")

        ::

          eliminate_d(self)


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L427

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L542-L548




        """
        return _casadi.DaeBuilder_eliminate_d(self, *args)


    def eliminate_w(self, *args) -> "void":
        """
          [DEPRECATED] Use eliminate("w")

        ::

          eliminate_w(self)


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L430

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L550-L556




        """
        return _casadi.DaeBuilder_eliminate_w(self, *args)


    def eliminate_quad(self, *args) -> "void":
        """
          [DEPRECATED] Use eliminate("q")

        ::

          eliminate_quad(self)


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L433

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L558-L564




        """
        return _casadi.DaeBuilder_eliminate_quad(self, *args)


    def sort_d(self, *args) -> "void":
        """
          [DEPRECATED] Use sort("d")

        ::

          sort_d(self)


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L436

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L566-L572




        """
        return _casadi.DaeBuilder_sort_d(self, *args)


    def sort_w(self, *args) -> "void":
        """
          [DEPRECATED] Use sort("w")

        ::

          sort_w(self)


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L439

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L574-L580




        """
        return _casadi.DaeBuilder_sort_w(self, *args)


    def sort_z(self, *args) -> "void":
        """
          [DEPRECATED] Use reorder("z", new_order)

        ::

          sort_z(self, [str] z_order)


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L442

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L582-L588




        """
        return _casadi.DaeBuilder_sort_z(self, *args)


    def eliminate(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          eliminate(self, str cat)

        Eliminate all dependent parameters.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L453

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L883-L889




        """
        return _casadi.DaeBuilder_eliminate(self, *args)


    def sort(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          sort(self, str cat)

        Sort dependent parameters.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L456

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L891-L897




        """
        return _casadi.DaeBuilder_sort(self, *args)


    def lift(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          lift(self, bool lift_shared, bool lift_calls)

        Lift problem formulation by extracting shared subexpressions.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L459

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L899-L905




        """
        return _casadi.DaeBuilder_lift(self, *args)


    def prune(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          prune(self, bool prune_p, bool prune_u)

        Prune unused controls.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L462

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L326-L332




        """
        return _casadi.DaeBuilder_prune(self, *args)


    def tear(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          tear(self)

        Identify iteration variables and residual equations using naming

        convention.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L465

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L334-L340




        """
        return _casadi.DaeBuilder_tear(self, *args)


    def add_fun(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          add_fun(self, Function f) -> Function
          add_fun(self, str name, Importer compiler, dict opts) -> Function
          add_fun(self, str name, [str] arg, [str] res, dict opts) -> Function

        Add an external function.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L482

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1153-L1156



        .......

        ::

          add_fun(self, Function f)



        [INTERNAL] 
        Add an already existing function.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L479

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1134-L1141



        .............


        .......

        ::

          add_fun(self, str name, [str] arg, [str] res, dict opts)



        [INTERNAL] 
        Add a function from loaded expressions.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L474

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1143-L1151



        .............


        .......

        ::

          add_fun(self, str name, Importer compiler, dict opts)



        [INTERNAL] 
        Add an external function.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L482

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1153-L1156



        .............



        """
        return _casadi.DaeBuilder_add_fun(self, *args)


    def has_fun(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_fun(self, str name) -> bool

        Does a particular function already exist?

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L486

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1158-L1165




        """
        return _casadi.DaeBuilder_has_fun(self, *args)


    def fun(self, *args) -> "std::vector< casadi::Function,std::allocator< casadi::Function > >":
        """
          [INTERNAL] 

        ::

          fun(self) -> [Function]
          fun(self, str name) -> Function

        Get all functions.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L492

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1197-L1199



        .......

        ::

          fun(self, str name)



        [INTERNAL] 
        Get function by name.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L489

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1167-L1174



        .............


        .......

        ::

          fun(self)



        [INTERNAL] 
        Get all functions.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L492

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1197-L1199



        .............



        """
        return _casadi.DaeBuilder_fun(self, *args)


    def gather_fun(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          gather_fun(self, int max_depth)

        Collect embedded functions from the expression graph.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L495

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1176-L1195




        """
        return _casadi.DaeBuilder_gather_fun(self, *args)


    def parse_fmi(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          parse_fmi(self, str filename)

        Import existing problem from FMI/XML

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L502

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L502-L502




        """
        return _casadi.DaeBuilder_parse_fmi(self, *args)


    def provides_directional_derivatives(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          provides_directional_derivatives(self) -> bool

        Does the FMU provide support for analytic derivatives.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L505

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L308-L316




        """
        return _casadi.DaeBuilder_provides_directional_derivatives(self, *args)


    def provides_directional_derivative(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          provides_directional_derivative(self) -> bool

        Does the FMU provide support for analytic derivatives (FMI 2 
        naming)

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L508

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L508-L508




        """
        return _casadi.DaeBuilder_provides_directional_derivative(self, *args)


    def load_fmi_description(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          load_fmi_description(self, str filename)

        Import problem description from FMI or XML.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L511

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L300-L306




        """
        return _casadi.DaeBuilder_load_fmi_description(self, *args)


    def export_fmu(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          export_fmu(self, dict opts) -> [str]

        Export instance into an FMU.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L514

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L318-L324




        """
        return _casadi.DaeBuilder_export_fmu(self, *args)


    def add_lc(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          add_lc(self, str name, [str] f_out)

        Add a named linear combination of output expressions.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L517

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1094-L1101




        """
        return _casadi.DaeBuilder_add_lc(self, *args)


    def create(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          create(self) -> Function
          create(self, str fname, dict opts) -> Function
          create(self, str name, [str] name_in, [str] name_out, dict opts) -> Function
          create(self, str fname, [str] name_in, [str] name_out, bool sx, bool lifted_calls) -> Function

        Create a function with standard integrator DAE signature, 
        default 
        naming.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2c1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L549

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L549-L549



        .......

        ::

          create(self, str name, [str] name_in, [str] name_out, dict opts)



        [INTERNAL] 
        Construct a function object, names provided.

        Parameters:
        -----------

        name: 
        Name assigned to the resulting function object

        name_in: 
        Names of all the inputs

        name_out: 
        Names of all the outputs

        opts: 
        Optional settings

        Extra doc: https://github.com/casadi/casadi/wiki/L_6e

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L532

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1114-L1123



        .............


        .......

        ::

          create(self, str fname, [str] name_in, [str] name_out, bool sx, bool lifted_calls)



        [INTERNAL] 
        Construct a function object, legacy syntax.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L520

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1103-L1112



        .............


        .......

        ::

          create(self)



        [INTERNAL] 
        Create a function with standard integrator DAE signature, 
        default 
        naming.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2c1

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L549

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L549-L549



        .............


        .......

        ::

          create(self, str fname, dict opts)



        [INTERNAL] 
        Create a function with standard integrator DAE signature.

        Parameters:
        -----------

        name: 
        Name assigned to the resulting function object

        opts: 
        Optional settings

        Extra doc: https://github.com/casadi/casadi/wiki/L_2c0

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L544

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1125-L1132



        .............



        """
        return _casadi.DaeBuilder_create(self, *args)


    def dependent_fun(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          dependent_fun(self, str fname, [str] s_in, [str] s_out) -> Function

        Construct a function for evaluating dependent parameters.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L552

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1210-L1219




        """
        return _casadi.DaeBuilder_dependent_fun(self, *args)


    def transition(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          transition(self) -> Function
          transition(self, str fname) -> Function
          transition(self, str fname, int index) -> Function

        Construct an event transition function, default naming.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L563

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L563-L563



        .......

        ::

          transition(self)



        [INTERNAL] 
        Construct an event transition function, default naming.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L563

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L563-L563



        .............


        .......

        ::

          transition(self, str fname)



        [INTERNAL] 
        Construct a function describing transition at any events.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L560

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1230-L1237



        .............


        .......

        ::

          transition(self, str fname, int index)



        [INTERNAL] 
        Construct a function describing transition at a specific events.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L557

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1221-L1228



        .............



        """
        return _casadi.DaeBuilder_transition(self, *args)


    def var(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          var(self, str name) -> MX

        Get variable expression by name

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L567

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L788-L795




        """
        return _casadi.DaeBuilder_var(self, *args)


    def __call__(self, *args) -> "casadi::MX":
        """


        ::

          __call__(self, str name) -> MX



        """
        return _casadi.DaeBuilder___call__(self, *args)


    def has_beq(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has_beq(self, str name) -> bool

        Does a variable have a binding equation?

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L587

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L864-L871




        """
        return _casadi.DaeBuilder_has_beq(self, *args)


    def beq(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          beq(self, str name) -> MX

        Get the binding equation for a variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L590

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L873-L881




        """
        return _casadi.DaeBuilder_beq(self, *args)


    def value_reference(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          value_reference(self, str name) -> int

        Get/set value reference

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L594

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L907-L909




        """
        return _casadi.DaeBuilder_value_reference(self, *args)


    def set_value_reference(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_value_reference(self, str name, int val)

        Get/set value reference

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L595

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L911-L913




        """
        return _casadi.DaeBuilder_set_value_reference(self, *args)


    def description(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          description(self, str name) -> str

        Get/set description

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L600

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L915-L917




        """
        return _casadi.DaeBuilder_description(self, *args)


    def set_description(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_description(self, str name, str val)

        Get/set description

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L601

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L919-L921




        """
        return _casadi.DaeBuilder_set_description(self, *args)


    def type(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          type(self, str name, int fmi_version) -> str

        Get/set the type

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L606

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L923-L932




        """
        return _casadi.DaeBuilder_type(self, *args)


    def set_type(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_type(self, str name, str val)

        Get/set the type

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L607

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L934-L941




        """
        return _casadi.DaeBuilder_set_type(self, *args)


    def causality(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          causality(self, str name) -> str

        Get the causality.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L611

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L943-L950




        """
        return _casadi.DaeBuilder_causality(self, *args)


    def set_causality(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_causality(self, str name, str val)

        Set the causality, if permitted.

        The following changes are permitted: For controls 'u' (variability 

        'continuous', causality 'input'), free parameters 'p' (variability 

        'tunable', causality 'parameter') and fixed parameters 'c' 
        (variability 
        'fixed', causality 'parameter'), causality can only be 
        changed indirectly, 
        by updating the variability Add or remove an 
        output 'y' by setting the 
        causality to 'output' or 'local', 
        respectively

        No other changes are permitted.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2c2

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L626

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L952-L958




        """
        return _casadi.DaeBuilder_set_causality(self, *args)


    def variability(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          variability(self, str name) -> str

        Get the variability.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L629

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L960-L967




        """
        return _casadi.DaeBuilder_variability(self, *args)


    def set_variability(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_variability(self, str name, str val)

        Set the variability, if permitted.

        For controls 'u' (variability 'continuous', causality 'input'), free 

        parameters 'p' (variability 'tunable', causality 'parameter') and 
        fixed 
        parameters 'c' (variability 'fixed', causality 'parameter'), 
        update 
        variability in order to change the category. Causality is 
        updated 
        accordingly.

        Other changes are not permitted

        ::

          Extra doc: https://github.com/casadi/casadi/wiki/L_2c3 




        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L641

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L969-L975




        """
        return _casadi.DaeBuilder_set_variability(self, *args)


    def category(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          category(self, str name) -> str

        Get the variable category.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L644

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L977-L984




        """
        return _casadi.DaeBuilder_category(self, *args)


    def set_category(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_category(self, str name, str val)

        Set the variable category, if permitted.

        The following changes are permitted: Controls 'u' can be changed 
        to/from 
        tunable parameters 'p' or fixed parameters 'c' Differential 
        states that do 
        not appear in the right-hand-sides can be changed 
        between regular states 
        'x' and quadrature states 'q'

        Other changes are not permitted. Causality and variability is updated 

        accordingly.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2c4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L656

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L986-L992




        """
        return _casadi.DaeBuilder_set_category(self, *args)


    def initial(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          initial(self, str name) -> str

        Get/set the initial property

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L660

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L994-L996




        """
        return _casadi.DaeBuilder_initial(self, *args)


    def set_initial(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_initial(self, str name, str val)

        Get/set the initial property

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L661

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L998-L1000




        """
        return _casadi.DaeBuilder_set_initial(self, *args)


    def unit(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          unit(self, str name) -> str

        Get/set the unit

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L666

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1002-L1004




        """
        return _casadi.DaeBuilder_unit(self, *args)


    def set_unit(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_unit(self, str name, str val)

        Get/set the unit

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L667

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1006-L1008




        """
        return _casadi.DaeBuilder_set_unit(self, *args)


    def display_unit(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          display_unit(self, str name) -> str

        Get/set the display unit

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L672

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1010-L1012




        """
        return _casadi.DaeBuilder_display_unit(self, *args)


    def set_display_unit(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_display_unit(self, str name, str val)

        Get/set the display unit

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L673

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1014-L1016




        """
        return _casadi.DaeBuilder_set_display_unit(self, *args)


    def numel(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          numel(self, str name) -> int

        Get the number of elements of a variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L677

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1018-L1020




        """
        return _casadi.DaeBuilder_numel(self, *args)


    def dimension(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """
          [INTERNAL] 

        ::

          dimension(self, str name) -> [int]

        Get the dimensions of a variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L680

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1022-L1024




        """
        return _casadi.DaeBuilder_dimension(self, *args)


    def start_time(self, *args) -> "double":
        """
          [INTERNAL] 

        ::

          start_time(self) -> float

        Get the start time.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L683

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1026-L1033




        """
        return _casadi.DaeBuilder_start_time(self, *args)


    def set_start_time(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_start_time(self, float val)

        Set the start time.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L686

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1035-L1041




        """
        return _casadi.DaeBuilder_set_start_time(self, *args)


    def stop_time(self, *args) -> "double":
        """
          [INTERNAL] 

        ::

          stop_time(self) -> float

        Get the stop time.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L689

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1043-L1050




        """
        return _casadi.DaeBuilder_stop_time(self, *args)


    def set_stop_time(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_stop_time(self, float val)

        Set the stop time.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L692

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1052-L1058




        """
        return _casadi.DaeBuilder_set_stop_time(self, *args)


    def tolerance(self, *args) -> "double":
        """
          [INTERNAL] 

        ::

          tolerance(self) -> float

        Get the tolerance.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L695

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1060-L1067




        """
        return _casadi.DaeBuilder_tolerance(self, *args)


    def set_tolerance(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_tolerance(self, float val)

        Set the tolerance.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L698

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1069-L1075




        """
        return _casadi.DaeBuilder_set_tolerance(self, *args)


    def step_size(self, *args) -> "double":
        """
          [INTERNAL] 

        ::

          step_size(self) -> float

        Get the step size.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L701

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1077-L1084




        """
        return _casadi.DaeBuilder_step_size(self, *args)


    def set_step_size(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_step_size(self, float val)

        Set the step size.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L704

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1086-L1092




        """
        return _casadi.DaeBuilder_set_step_size(self, *args)


    def der(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          der(self, [str] name) -> [str]
          der(self, MX v) -> MX
          der(self, MX v) -> MX
          der(self, str name) -> str

        Get the time derivative of model variables, single variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L710

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L797-L810



        .......

        ::

          der(self, [str] name)



        [INTERNAL] 
        Get the time derivative of model variables.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L572

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L842-L851



        .............


        .......

        ::

          der(self, str name)



        [INTERNAL] 
        Get the time derivative of model variables, single variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L710

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L797-L810



        .............


        .......

        ::

          der(self, MX v)



        [INTERNAL] 
        Differentiate an expression with respect to time

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L577

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1260-L1267



        .............


        .......

        ::

          der(self, MX v)



        [INTERNAL] 
        Differentiate an expression with respect to time

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L576

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1251-L1258



        .............



        """
        return _casadi.DaeBuilder_der(self, *args)


    def pre(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          pre(self, [str] name) -> [str]
          pre(self, MX v) -> MX
          pre(self, str name) -> str

        Get the pre-variables of model variables.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L713

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L812-L825



        .......

        ::

          pre(self, MX v)



        [INTERNAL] 
        Get the pre-expression given variable expression.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L584

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L827-L840



        .............


        .......

        ::

          pre(self, [str] name)



        [INTERNAL] 
        Get the pre-variables of model variables.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L581

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L853-L862



        .............


        .......

        ::

          pre(self, str name)



        [INTERNAL] 
        Get the pre-variables of model variables.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L713

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L812-L825



        .............



        """
        return _casadi.DaeBuilder_pre(self, *args)


    def reset(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          reset(self)



        """
        return _casadi.DaeBuilder_reset(self, *args)


    def attribute(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          attribute(self, str a, [str] name) -> [float]
          attribute(self, str a, str name) -> float

        Get an attribute.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L763

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1278-L1286



        .......

        ::

          attribute(self, str a, str name)



        [INTERNAL] 
        Get an attribute, single variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L716

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1269-L1276



        .............


        .......

        ::

          attribute(self, str a, [str] name)



        [INTERNAL] 
        Get an attribute.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L763

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1278-L1286



        .............



        """
        return _casadi.DaeBuilder_attribute(self, *args)


    def set_attribute(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_attribute(self, str a, [str] name, [float] val)
          set_attribute(self, str a, str name, float val)

        Set an attribute.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L766

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1296-L1303



        .......

        ::

          set_attribute(self, str a, str name, float val)



        [INTERNAL] 
        Set an attribute, single variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L719

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1288-L1294



        .............


        .......

        ::

          set_attribute(self, str a, [str] name, [float] val)



        [INTERNAL] 
        Set an attribute.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L766

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1296-L1303



        .............



        """
        return _casadi.DaeBuilder_set_attribute(self, *args)


    def min(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          min(self, [str] name) -> [float]
          min(self, str name) -> float

        Get the lower bound.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L770

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1314-L1321



        .......

        ::

          min(self, str name)



        [INTERNAL] 
        Get the lower bound, single variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L722

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1305-L1312



        .............


        .......

        ::

          min(self, [str] name)



        [INTERNAL] 
        Get the lower bound.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L770

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1314-L1321



        .............



        """
        return _casadi.DaeBuilder_min(self, *args)


    def set_min(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_min(self, [str] name, [float] val)
          set_min(self, str name, float val)

        Set the lower bound.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L773

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1331-L1337



        .......

        ::

          set_min(self, str name, float val)



        [INTERNAL] 
        Set the lower bound, single variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L725

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1323-L1329



        .............


        .......

        ::

          set_min(self, [str] name, [float] val)



        [INTERNAL] 
        Set the lower bound.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L773

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1331-L1337



        .............



        """
        return _casadi.DaeBuilder_set_min(self, *args)


    def max(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          max(self, [str] name) -> [float]
          max(self, str name) -> float

        Get the upper bound.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L776

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1348-L1355



        .......

        ::

          max(self, str name)



        [INTERNAL] 
        Get the upper bound, single variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L728

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1339-L1346



        .............


        .......

        ::

          max(self, [str] name)



        [INTERNAL] 
        Get the upper bound.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L776

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1348-L1355



        .............



        """
        return _casadi.DaeBuilder_max(self, *args)


    def set_max(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_max(self, [str] name, [float] val)
          set_max(self, str name, float val)

        Set the upper bound.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L779

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1365-L1371



        .......

        ::

          set_max(self, str name, float val)



        [INTERNAL] 
        Set the upper bound, single variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L731

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1357-L1363



        .............


        .......

        ::

          set_max(self, [str] name, [float] val)



        [INTERNAL] 
        Set the upper bound.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L779

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1365-L1371



        .............



        """
        return _casadi.DaeBuilder_set_max(self, *args)


    def nominal(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          nominal(self, [str] name) -> [float]
          nominal(self, str name) -> float

        Get the nominal value.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L782

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1382-L1389



        .......

        ::

          nominal(self, str name)



        [INTERNAL] 
        Get the nominal value, single variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L734

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1373-L1380



        .............


        .......

        ::

          nominal(self, [str] name)



        [INTERNAL] 
        Get the nominal value.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L782

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1382-L1389



        .............



        """
        return _casadi.DaeBuilder_nominal(self, *args)


    def set_nominal(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_nominal(self, [str] name, [float] val)
          set_nominal(self, str name, float val)

        Set the nominal value.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L785

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1399-L1405



        .......

        ::

          set_nominal(self, str name, float val)



        [INTERNAL] 
        Set the nominal value, single variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L737

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1391-L1397



        .............


        .......

        ::

          set_nominal(self, [str] name, [float] val)



        [INTERNAL] 
        Set the nominal value.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L785

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1399-L1405



        .............



        """
        return _casadi.DaeBuilder_set_nominal(self, *args)


    def start(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          start(self, [str] name) -> [float]
          start(self, str name) -> [float]

        Get the start attribute.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L788

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1416-L1423



        .......

        ::

          start(self, [str] name)



        [INTERNAL] 
        Get the start attribute.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L788

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1416-L1423



        .............


        .......

        ::

          start(self, str name)



        [INTERNAL] 
        Get the start attribute, single variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L740

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1407-L1414



        .............



        """
        return _casadi.DaeBuilder_start(self, *args)


    def set_start(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_start(self, [str] name, [float] val)
          set_start(self, str name, [float] val)
          set_start(self, str name, float val)

        Set the start attribute.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L791

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1441-L1447



        .......

        ::

          set_start(self, [str] name, [float] val)



        [INTERNAL] 
        Set the start attribute.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L791

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1441-L1447



        .............


        .......

        ::

          set_start(self, str name, [float] val)



        [INTERNAL] 
        Set the start attribute, vector argument.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L746

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1433-L1439



        .............


        .......

        ::

          set_start(self, str name, float val)



        [INTERNAL] 
        Set the start attribute, single variable.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L743

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1425-L1431



        .............



        """
        return _casadi.DaeBuilder_set_start(self, *args)


    def set(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set(self, [str] name, [float] val)
          set(self, [str] name, [str] val)
          set(self, str name, float val)
          set(self, str name, str val)

        Set the current value (string)

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L797

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1481-L1488



        .......

        ::

          set(self, [str] name, [str] val)



        [INTERNAL] 
        Set the current value (string)

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L797

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1481-L1488



        .............


        .......

        ::

          set(self, str name, float val)
          set(self, str name, str val)



        [INTERNAL] 

        .............


        .......

        ::

          set(self, [str] name, [float] val)



        [INTERNAL] 
        Set the current value.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L794

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1473-L1479



        .............



        """
        return _casadi.DaeBuilder_set(self, *args)


    def get(self, *args) -> "std::vector< casadi::GenericType,std::allocator< casadi::GenericType > >":
        """
          [INTERNAL] 

        ::

          get(self, [str] name) -> [GenericType]
          get(self, str name) -> GenericType

        Evaluate the values for a set of variables at the initial time.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L800

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1494-L1511



        .......

        ::

          get(self, [str] name)



        [INTERNAL] 
        Evaluate the values for a set of variables at the initial time.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L800

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1494-L1511



        .............


        .......

        ::

          get(self, str name)



        [INTERNAL] 
        Evaluate the values for a set of variables at the initial time, 
        single
         value.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L758

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1490-L1492



        .............



        """
        return _casadi.DaeBuilder_get(self, *args)


    def has(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          has(self, str name) -> bool

        Check if a particular variable exists.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L803

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L342-L349




        """
        return _casadi.DaeBuilder_has(self, *args)


    def all(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          all(self) -> [str]
          all(self, str cat) -> [str]

        Get a list of all variables of a particular category.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L809

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L360-L367



        .......

        ::

          all(self)



        [INTERNAL] 
        Get a list of all variables.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L806

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L351-L358



        .............


        .......

        ::

          all(self, str cat)



        [INTERNAL] 
        Get a list of all variables of a particular category.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L809

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L360-L367



        .............



        """
        return _casadi.DaeBuilder_all(self, *args)


    def add_variable(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          add_variable(self, MX new_v)
          add_variable(self, str name, int n) -> MX
          add_variable(self, str name, Sparsity sp) -> MX

        Add a new variable from symbolic expressions.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L819

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L475-L478



        .......

        ::

          add_variable(self, MX new_v)



        [INTERNAL] 
        Add a new variable from symbolic expressions.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L819

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L475-L478



        .............


        .......

        ::

          add_variable(self, str name, int n)



        [DEPRECATED] Use add

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L813

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L465-L467



        .............


        .......

        ::

          add_variable(self, str name, Sparsity sp)



        [DEPRECATED] Use add

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L816

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L469-L473



        .............



        """
        return _casadi.DaeBuilder_add_variable(self, *args)


    def add_variable_new(self, *args) -> "size_t":
        """
          [DEPRECATED] Use add

        ::

          add_variable_new(self, MX new_v) -> size_t
          add_variable_new(self, str name, int n) -> size_t
          add_variable_new(self, str name, Sparsity sp) -> size_t


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L828

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L490-L494



        .......

        ::

          add_variable_new(self, MX new_v)



        [DEPRECATED] Use add

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L828

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L490-L494



        .............


        .......

        ::

          add_variable_new(self, str name, int n)



        [DEPRECATED] Use add

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L822

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L480-L482



        .............


        .......

        ::

          add_variable_new(self, str name, Sparsity sp)



        [DEPRECATED] Use add

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L825

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L484-L488



        .............



        """
        return _casadi.DaeBuilder_add_variable_new(self, *args)


    def has_variable(self, *args) -> "bool":
        """
          [DEPRECATED] Ranamed "has"

        ::

          has_variable(self, str name) -> bool


        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L831

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L831-L831




        """
        return _casadi.DaeBuilder_has_variable(self, *args)


    def all_variables(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          all_variables(self) -> [str]

        Get a list of all variables.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L834

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L834-L834




        """
        return _casadi.DaeBuilder_all_variables(self, *args)


    def oracle(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          oracle(self, bool sx, bool elim_w, bool lifted_calls) -> Function

        Get the (cached) oracle, SX or  MX.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L838

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1201-L1208




        """
        return _casadi.DaeBuilder_oracle(self, *args)


    def jac_sparsity(self, *args) -> "casadi::Sparsity":
        """
          [INTERNAL] 

        ::

          jac_sparsity(self, [str] onames, [str] inames) -> Sparsity

        Get Jacobian sparsity.

        Extra doc: https://github.com/casadi/casadi/wiki/L_6g

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L843

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L1513-L1521




        """
        return _casadi.DaeBuilder_jac_sparsity(self, *args)


    def __init__(self, *args):
        """


        ::

          DaeBuilder()
          DaeBuilder(DaeBuilder other)
          DaeBuilder(str name, str path, dict opts)


        .......

        ::

          DaeBuilder(DaeBuilder other)



        .............


        .......

        ::

          DaeBuilder(str name, str path, dict opts)



        [INTERNAL] 
        Construct a  DaeBuilder instance.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L80

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L54-L57



        .............


        .......

        ::

          DaeBuilder()



        [INTERNAL] 
        Default constructor.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.hpp#L77

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/dae_builder.cpp#L51-L52



        .............



        """
        this = _casadi.new_DaeBuilder(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_DaeBuilder
DaeBuilder_swigregister = _casadi.DaeBuilder_swigregister
DaeBuilder_swigregister(DaeBuilder)

class XmlFile(SharedObject, PrintableCommon):
    """
      [INTERNAL] 

    ::


    XML parser.

    Can be used for parsing XML files into CasADi data structures.

    Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_7k

    C++ includes: xml_file.hpp



    """

    __swig_setmethods__ = {}
    for _s in [SharedObject, PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, XmlFile, name, value)
    __swig_getmethods__ = {}
    for _s in [SharedObject, PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, XmlFile, name)
    __repr__ = _swig_repr

    def type_name(*args) -> "std::string":
        """


        ::

          type_name() -> str



        """
        return _casadi.XmlFile_type_name(*args)

    type_name = staticmethod(type_name)
    __swig_destroy__ = _casadi.delete_XmlFile

    def load_plugin(*args) -> "void":
        """


        ::

          load_plugin(str name)



        """
        return _casadi.XmlFile_load_plugin(*args)

    load_plugin = staticmethod(load_plugin)

    def doc(*args) -> "std::string":
        """


        ::

          doc(str name) -> str



        """
        return _casadi.XmlFile_doc(*args)

    doc = staticmethod(doc)

    def __init__(self, *args):
        """


        ::

          XmlFile()
          XmlFile(XmlFile other)
          XmlFile(str name)


        .......

        ::

          XmlFile(XmlFile other)



        .............


        .......

        ::

          XmlFile()
          XmlFile(str name)



        [INTERNAL] 

        .............



        """
        this = _casadi.new_XmlFile(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
XmlFile_swigregister = _casadi.XmlFile_swigregister
XmlFile_swigregister(XmlFile)

def XmlFile_type_name(*args) -> "std::string":
    """


    ::

      type_name() -> str



    """
    return _casadi.XmlFile_type_name(*args)

def XmlFile_load_plugin(*args) -> "void":
    """


    ::

      load_plugin(str name)



    """
    return _casadi.XmlFile_load_plugin(*args)

def XmlFile_doc(*args) -> "std::string":
    """


    ::

      doc(str name) -> str



    """
    return _casadi.XmlFile_doc(*args)


def has_archiver(*args) -> "bool":
    """
      [INTERNAL] 

    ::

      has_archiver(str name) -> bool

    Check if a particular plugin is available.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/archiver.hpp#L38

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/archiver.cpp#L38-L40




    """
    return _casadi.has_archiver(*args)

def load_archiver(*args) -> "void":
    """
      [INTERNAL] 

    ::

      load_archiver(str name)

    Explicitly load a plugin dynamically.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/archiver.hpp#L42

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/archiver.cpp#L42-L44




    """
    return _casadi.load_archiver(*args)

def doc_archiver(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      doc_archiver(str name) -> str

    Get the documentation string for a plugin.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/archiver.hpp#L46

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/archiver.cpp#L46-L48




    """
    return _casadi.doc_archiver(*args)

def has_filesystem(*args) -> "bool":
    """
      [INTERNAL] 

    ::

      has_filesystem(str name) -> bool

    Check if a particular plugin is available.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/filesystem.hpp#L92

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/filesystem.cpp#L92-L94




    """
    return _casadi.has_filesystem(*args)

def load_filesystem(*args) -> "void":
    """
      [INTERNAL] 

    ::

      load_filesystem(str name)

    Explicitly load a plugin dynamically.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/filesystem.hpp#L96

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/filesystem.cpp#L96-L98




    """
    return _casadi.load_filesystem(*args)

def doc_filesystem(*args) -> "std::string":
    """
      [INTERNAL] 

    ::

      doc_filesystem(str name) -> str

    Get the documentation string for a plugin.

    Doc source: 
    https://github.com/casadi/casadi/blob/main/casadi/core/filesystem.hpp#L100

    Implementation: 
    https://github.com/casadi/casadi/blob/main/casadi/core/filesystem.cpp#L100-L102




    """
    return _casadi.doc_filesystem(*args)
class Options(_object):
    """


    ::

      Options() -> 



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, Options, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, Options, name)
    __repr__ = _swig_repr

    def all(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """


        ::

          all(self) -> [str]



        """
        return _casadi.Options_all(self, *args)


    def type(self, *args) -> "std::string":
        """


        ::

          type(self, str name) -> str



        """
        return _casadi.Options_type(self, *args)


    def info(self, *args) -> "std::string":
        """


        ::

          info(self, str name) -> str



        """
        return _casadi.Options_info(self, *args)


    def word_distance(*args) -> "double":
        """


        ::

          word_distance(str a, str b) -> float



        """
        return _casadi.Options_word_distance(*args)

    word_distance = staticmethod(word_distance)

    def suggestions(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """


        ::

          suggestions(self, str word, int amount) -> [str]



        """
        return _casadi.Options_suggestions(self, *args)


    def best_matches(self, *args) -> "void":
        """


        ::

          best_matches(self, str word, std::vector< std::pair< double,std::string >,std::allocator< std::pair< double,std::string > > > & best)



        """
        return _casadi.Options_best_matches(self, *args)


    def has_dot(*args) -> "bool":
        """


        ::

          has_dot(dict opts) -> bool



        """
        return _casadi.Options_has_dot(*args)

    has_dot = staticmethod(has_dot)

    def has_null(*args) -> "bool":
        """


        ::

          has_null(dict opts) -> bool



        """
        return _casadi.Options_has_null(*args)

    has_null = staticmethod(has_null)

    def is_sane(*args) -> "bool":
        """


        ::

          is_sane(dict opts) -> bool



        """
        return _casadi.Options_is_sane(*args)

    is_sane = staticmethod(is_sane)

    def sanitize(*args) -> "casadi::Dict":
        """


        ::

          sanitize(dict opts, bool top_level) -> dict



        """
        return _casadi.Options_sanitize(*args)

    sanitize = staticmethod(sanitize)

    def check(self, *args) -> "void":
        """


        ::

          check(self, dict opts)



        """
        return _casadi.Options_check(self, *args)


    def print_all(self, *args) -> "void":
        """


        ::

          print_all(self)



        """
        return _casadi.Options_print_all(self, *args)


    def print_one(self, *args) -> "void":
        """


        ::

          print_one(self, str name)



        """
        return _casadi.Options_print_one(self, *args)


    def __init__(self, *args):
        """


        ::

          Options()
          Options(Options other)



        """
        this = _casadi.new_Options(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_Options
Options_swigregister = _casadi.Options_swigregister
Options_swigregister(Options)

def Options_word_distance(*args) -> "double":
    """


    ::

      word_distance(str a, str b) -> float



    """
    return _casadi.Options_word_distance(*args)

def Options_has_dot(*args) -> "bool":
    """


    ::

      has_dot(dict opts) -> bool



    """
    return _casadi.Options_has_dot(*args)

def Options_has_null(*args) -> "bool":
    """


    ::

      has_null(dict opts) -> bool



    """
    return _casadi.Options_has_null(*args)

def Options_is_sane(*args) -> "bool":
    """


    ::

      is_sane(dict opts) -> bool



    """
    return _casadi.Options_is_sane(*args)

def Options_sanitize(*args) -> "casadi::Dict":
    """


    ::

      sanitize(dict opts, bool top_level) -> dict



    """
    return _casadi.Options_sanitize(*args)

class SerializerBase(_object):
    """
      [INTERNAL] C++ includes: serializer.hpp

    ::





    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, SerializerBase, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, SerializerBase, name)

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined")
    __repr__ = _swig_repr
    __swig_destroy__ = _casadi.delete_SerializerBase

    def pack(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          pack(self, Linsol e)
          pack(self, std::vector< casadi::Linsol,std::allocator< casadi::Linsol > > const & e)
          pack(self, int e)
          pack(self, float e)
          pack(self, [Sparsity] e)
          pack(self, Sparsity e)
          pack(self, [float] e)
          pack(self, [int] e)
          pack(self, [str] e)
          pack(self, DM e)
          pack(self, [DM] e)
          pack(self, SX e)
          pack(self, [SX] e)
          pack(self, MX e)
          pack(self, [MX] e)
          pack(self, str e)
          pack(self, [Function] e)
          pack(self, Function e)
          pack(self, [GenericType] e)
          pack(self, GenericType e)


        .......

        ::

          pack(self, DM e)
          pack(self, [DM] e)
          pack(self, SX e)
          pack(self, [SX] e)



        .............


        .......

        ::

          pack(self, Linsol e)
          pack(self, std::vector< casadi::Linsol,std::allocator< casadi::Linsol > > const & e)
          pack(self, int e)
          pack(self, float e)
          pack(self, [Sparsity] e)
          pack(self, Sparsity e)
          pack(self, [float] e)
          pack(self, [int] e)
          pack(self, [str] e)
          pack(self, MX e)
          pack(self, [MX] e)
          pack(self, str e)
          pack(self, [Function] e)
          pack(self, Function e)
          pack(self, [GenericType] e)
          pack(self, GenericType e)



        [INTERNAL] 

        .............



        """
        return _casadi.SerializerBase_pack(self, *args)

    _SERIALIZED_SPARSITY = _casadi.SerializerBase__SERIALIZED_SPARSITY
    _SERIALIZED_MX_v1 = _casadi.SerializerBase__SERIALIZED_MX_v1
    _SERIALIZED_DM = _casadi.SerializerBase__SERIALIZED_DM
    _SERIALIZED_SX_v1 = _casadi.SerializerBase__SERIALIZED_SX_v1
    _SERIALIZED_LINSOL = _casadi.SerializerBase__SERIALIZED_LINSOL
    _SERIALIZED_FUNCTION = _casadi.SerializerBase__SERIALIZED_FUNCTION
    _SERIALIZED_GENERICTYPE = _casadi.SerializerBase__SERIALIZED_GENERICTYPE
    _SERIALIZED_INT = _casadi.SerializerBase__SERIALIZED_INT
    _SERIALIZED_DOUBLE = _casadi.SerializerBase__SERIALIZED_DOUBLE
    _SERIALIZED_STRING = _casadi.SerializerBase__SERIALIZED_STRING
    _SERIALIZED_SPARSITY_VECTOR = _casadi.SerializerBase__SERIALIZED_SPARSITY_VECTOR
    _SERIALIZED_MX_VECTOR_v1 = _casadi.SerializerBase__SERIALIZED_MX_VECTOR_v1
    _SERIALIZED_DM_VECTOR = _casadi.SerializerBase__SERIALIZED_DM_VECTOR
    _SERIALIZED_SX_VECTOR_v1 = _casadi.SerializerBase__SERIALIZED_SX_VECTOR_v1
    _SERIALIZED_LINSOL_VECTOR = _casadi.SerializerBase__SERIALIZED_LINSOL_VECTOR
    _SERIALIZED_FUNCTION_VECTOR = _casadi.SerializerBase__SERIALIZED_FUNCTION_VECTOR
    _SERIALIZED_GENERICTYPE_VECTOR = _casadi.SerializerBase__SERIALIZED_GENERICTYPE_VECTOR
    _SERIALIZED_INT_VECTOR = _casadi.SerializerBase__SERIALIZED_INT_VECTOR
    _SERIALIZED_DOUBLE_VECTOR = _casadi.SerializerBase__SERIALIZED_DOUBLE_VECTOR
    _SERIALIZED_STRING_VECTOR = _casadi.SerializerBase__SERIALIZED_STRING_VECTOR
    _SERIALIZED_MX = _casadi.SerializerBase__SERIALIZED_MX
    _SERIALIZED_SX = _casadi.SerializerBase__SERIALIZED_SX
    _SERIALIZED_MX_VECTOR = _casadi.SerializerBase__SERIALIZED_MX_VECTOR
    _SERIALIZED_SX_VECTOR = _casadi.SerializerBase__SERIALIZED_SX_VECTOR

    def type_to_string(*args) -> "std::string":
        """


        ::

          type_to_string(casadi::SerializerBase::SerializationType type) -> str



        """
        return _casadi.SerializerBase_type_to_string(*args)

    type_to_string = staticmethod(type_to_string)

    def connect(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          connect(self, DeserializerBase s)



        """
        return _casadi.SerializerBase_connect(self, *args)


    def reset(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          reset(self)



        """
        return _casadi.SerializerBase_reset(self, *args)

SerializerBase_swigregister = _casadi.SerializerBase_swigregister
SerializerBase_swigregister(SerializerBase)

def SerializerBase_type_to_string(*args) -> "std::string":
    """


    ::

      type_to_string(casadi::SerializerBase::SerializationType type) -> str



    """
    return _casadi.SerializerBase_type_to_string(*args)

class DeserializerBase(_object):
    """
      [INTERNAL] C++ includes: serializer.hpp

    ::





    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, DeserializerBase, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, DeserializerBase, name)

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined")
    __repr__ = _swig_repr
    __swig_destroy__ = _casadi.delete_DeserializerBase

    def _pop_type(self, *args) -> "casadi::SerializerBase::SerializationType":
        """
          [INTERNAL] 

        ::

          _pop_type(self) -> casadi::SerializerBase::SerializationType



        """
        return _casadi.DeserializerBase__pop_type(self, *args)


    def blind_unpack_sparsity(self, *args) -> "casadi::Sparsity":
        """
          [INTERNAL] 

        ::

          blind_unpack_sparsity(self) -> Sparsity



        """
        return _casadi.DeserializerBase_blind_unpack_sparsity(self, *args)


    def blind_unpack_mx(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          blind_unpack_mx(self) -> MX



        """
        return _casadi.DeserializerBase_blind_unpack_mx(self, *args)


    def blind_unpack_mx_v1(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          blind_unpack_mx_v1(self) -> MX



        """
        return _casadi.DeserializerBase_blind_unpack_mx_v1(self, *args)


    def blind_unpack_dm(self, *args) -> "casadi::Matrix< double >":
        """
          [INTERNAL] 

        ::

          blind_unpack_dm(self) -> DM



        """
        return _casadi.DeserializerBase_blind_unpack_dm(self, *args)


    def blind_unpack_sx(self, *args) -> "casadi::Matrix< casadi::SXElem >":
        """
          [INTERNAL] 

        ::

          blind_unpack_sx(self) -> SX



        """
        return _casadi.DeserializerBase_blind_unpack_sx(self, *args)


    def blind_unpack_sx_v1(self, *args) -> "casadi::Matrix< casadi::SXElem >":
        """
          [INTERNAL] 

        ::

          blind_unpack_sx_v1(self) -> SX



        """
        return _casadi.DeserializerBase_blind_unpack_sx_v1(self, *args)


    def blind_unpack_linsol(self, *args) -> "casadi::Linsol":
        """
          [INTERNAL] 

        ::

          blind_unpack_linsol(self) -> Linsol



        """
        return _casadi.DeserializerBase_blind_unpack_linsol(self, *args)


    def blind_unpack_function(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          blind_unpack_function(self) -> Function



        """
        return _casadi.DeserializerBase_blind_unpack_function(self, *args)


    def blind_unpack_generictype(self, *args) -> "casadi::GenericType":
        """
          [INTERNAL] 

        ::

          blind_unpack_generictype(self) -> GenericType



        """
        return _casadi.DeserializerBase_blind_unpack_generictype(self, *args)


    def blind_unpack_int(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          blind_unpack_int(self) -> int



        """
        return _casadi.DeserializerBase_blind_unpack_int(self, *args)


    def blind_unpack_double(self, *args) -> "double":
        """
          [INTERNAL] 

        ::

          blind_unpack_double(self) -> float



        """
        return _casadi.DeserializerBase_blind_unpack_double(self, *args)


    def blind_unpack_string(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          blind_unpack_string(self) -> str



        """
        return _casadi.DeserializerBase_blind_unpack_string(self, *args)


    def blind_unpack_sparsity_vector(self, *args) -> "std::vector< casadi::Sparsity,std::allocator< casadi::Sparsity > >":
        """
          [INTERNAL] 

        ::

          blind_unpack_sparsity_vector(self) -> [Sparsity]



        """
        return _casadi.DeserializerBase_blind_unpack_sparsity_vector(self, *args)


    def blind_unpack_mx_vector(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          blind_unpack_mx_vector(self) -> [MX]



        """
        return _casadi.DeserializerBase_blind_unpack_mx_vector(self, *args)


    def blind_unpack_mx_vector_v1(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          blind_unpack_mx_vector_v1(self) -> [MX]



        """
        return _casadi.DeserializerBase_blind_unpack_mx_vector_v1(self, *args)


    def blind_unpack_dm_vector(self, *args) -> "std::vector< casadi::Matrix< double >,std::allocator< casadi::Matrix< double > > >":
        """
          [INTERNAL] 

        ::

          blind_unpack_dm_vector(self) -> [DM]



        """
        return _casadi.DeserializerBase_blind_unpack_dm_vector(self, *args)


    def blind_unpack_sx_vector(self, *args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
        """
          [INTERNAL] 

        ::

          blind_unpack_sx_vector(self) -> [SX]



        """
        return _casadi.DeserializerBase_blind_unpack_sx_vector(self, *args)


    def blind_unpack_sx_vector_v1(self, *args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
        """
          [INTERNAL] 

        ::

          blind_unpack_sx_vector_v1(self) -> [SX]



        """
        return _casadi.DeserializerBase_blind_unpack_sx_vector_v1(self, *args)


    def blind_unpack_linsol_vector(self, *args) -> "std::vector< casadi::Linsol,std::allocator< casadi::Linsol > >":
        """
          [INTERNAL] 

        ::

          blind_unpack_linsol_vector(self) -> std::vector< casadi::Linsol,std::allocator< casadi::Linsol > >



        """
        return _casadi.DeserializerBase_blind_unpack_linsol_vector(self, *args)


    def blind_unpack_function_vector(self, *args) -> "std::vector< casadi::Function,std::allocator< casadi::Function > >":
        """
          [INTERNAL] 

        ::

          blind_unpack_function_vector(self) -> [Function]



        """
        return _casadi.DeserializerBase_blind_unpack_function_vector(self, *args)


    def blind_unpack_generictype_vector(self, *args) -> "std::vector< casadi::GenericType,std::allocator< casadi::GenericType > >":
        """
          [INTERNAL] 

        ::

          blind_unpack_generictype_vector(self) -> [GenericType]



        """
        return _casadi.DeserializerBase_blind_unpack_generictype_vector(self, *args)


    def blind_unpack_int_vector(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """
          [INTERNAL] 

        ::

          blind_unpack_int_vector(self) -> [int]



        """
        return _casadi.DeserializerBase_blind_unpack_int_vector(self, *args)


    def blind_unpack_double_vector(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          blind_unpack_double_vector(self) -> [float]



        """
        return _casadi.DeserializerBase_blind_unpack_double_vector(self, *args)


    def blind_unpack_string_vector(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          blind_unpack_string_vector(self) -> [str]



        """
        return _casadi.DeserializerBase_blind_unpack_string_vector(self, *args)


    def unpack_sparsity(self, *args) -> "casadi::Sparsity":
        """
          [INTERNAL] 

        ::

          unpack_sparsity(self) -> Sparsity



        """
        return _casadi.DeserializerBase_unpack_sparsity(self, *args)


    def unpack_mx(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          unpack_mx(self) -> MX



        """
        return _casadi.DeserializerBase_unpack_mx(self, *args)


    def unpack_dm(self, *args) -> "casadi::Matrix< double >":
        """
          [INTERNAL] 

        ::

          unpack_dm(self) -> DM



        """
        return _casadi.DeserializerBase_unpack_dm(self, *args)


    def unpack_sx(self, *args) -> "casadi::Matrix< casadi::SXElem >":
        """
          [INTERNAL] 

        ::

          unpack_sx(self) -> SX



        """
        return _casadi.DeserializerBase_unpack_sx(self, *args)


    def unpack_linsol(self, *args) -> "casadi::Linsol":
        """
          [INTERNAL] 

        ::

          unpack_linsol(self) -> Linsol



        """
        return _casadi.DeserializerBase_unpack_linsol(self, *args)


    def unpack_function(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          unpack_function(self) -> Function



        """
        return _casadi.DeserializerBase_unpack_function(self, *args)


    def unpack_generictype(self, *args) -> "casadi::GenericType":
        """
          [INTERNAL] 

        ::

          unpack_generictype(self) -> GenericType



        """
        return _casadi.DeserializerBase_unpack_generictype(self, *args)


    def unpack_int(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          unpack_int(self) -> int



        """
        return _casadi.DeserializerBase_unpack_int(self, *args)


    def unpack_double(self, *args) -> "double":
        """
          [INTERNAL] 

        ::

          unpack_double(self) -> float



        """
        return _casadi.DeserializerBase_unpack_double(self, *args)


    def unpack_string(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          unpack_string(self) -> str



        """
        return _casadi.DeserializerBase_unpack_string(self, *args)


    def unpack_sparsity_vector(self, *args) -> "std::vector< casadi::Sparsity,std::allocator< casadi::Sparsity > >":
        """
          [INTERNAL] 

        ::

          unpack_sparsity_vector(self) -> [Sparsity]



        """
        return _casadi.DeserializerBase_unpack_sparsity_vector(self, *args)


    def unpack_mx_vector(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          unpack_mx_vector(self) -> [MX]



        """
        return _casadi.DeserializerBase_unpack_mx_vector(self, *args)


    def unpack_dm_vector(self, *args) -> "std::vector< casadi::Matrix< double >,std::allocator< casadi::Matrix< double > > >":
        """
          [INTERNAL] 

        ::

          unpack_dm_vector(self) -> [DM]



        """
        return _casadi.DeserializerBase_unpack_dm_vector(self, *args)


    def unpack_sx_vector(self, *args) -> "std::vector< casadi::Matrix< casadi::SXElem >,std::allocator< casadi::Matrix< casadi::SXElem > > >":
        """
          [INTERNAL] 

        ::

          unpack_sx_vector(self) -> [SX]



        """
        return _casadi.DeserializerBase_unpack_sx_vector(self, *args)


    def unpack_linsol_vector(self, *args) -> "std::vector< casadi::Linsol,std::allocator< casadi::Linsol > >":
        """
          [INTERNAL] 

        ::

          unpack_linsol_vector(self) -> std::vector< casadi::Linsol,std::allocator< casadi::Linsol > >



        """
        return _casadi.DeserializerBase_unpack_linsol_vector(self, *args)


    def unpack_function_vector(self, *args) -> "std::vector< casadi::Function,std::allocator< casadi::Function > >":
        """
          [INTERNAL] 

        ::

          unpack_function_vector(self) -> [Function]



        """
        return _casadi.DeserializerBase_unpack_function_vector(self, *args)


    def unpack_generictype_vector(self, *args) -> "std::vector< casadi::GenericType,std::allocator< casadi::GenericType > >":
        """
          [INTERNAL] 

        ::

          unpack_generictype_vector(self) -> [GenericType]



        """
        return _casadi.DeserializerBase_unpack_generictype_vector(self, *args)


    def unpack_int_vector(self, *args) -> "std::vector< casadi_int,std::allocator< casadi_int > >":
        """
          [INTERNAL] 

        ::

          unpack_int_vector(self) -> [int]



        """
        return _casadi.DeserializerBase_unpack_int_vector(self, *args)


    def unpack_double_vector(self, *args) -> "std::vector< double,std::allocator< double > >":
        """
          [INTERNAL] 

        ::

          unpack_double_vector(self) -> [float]



        """
        return _casadi.DeserializerBase_unpack_double_vector(self, *args)


    def unpack_string_vector(self, *args) -> "std::vector< std::string,std::allocator< std::string > >":
        """
          [INTERNAL] 

        ::

          unpack_string_vector(self) -> [str]



        """
        return _casadi.DeserializerBase_unpack_string_vector(self, *args)


    def connect(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          connect(self, SerializerBase s)



        """
        return _casadi.DeserializerBase_connect(self, *args)


    def reset(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          reset(self)



        """
        return _casadi.DeserializerBase_reset(self, *args)


    def unpack(self):
      type = SerializerBase.type_to_string(self._pop_type())
      f = getattr(self, "blind_unpack_"+type)
      return f()

DeserializerBase_swigregister = _casadi.DeserializerBase_swigregister
DeserializerBase_swigregister(DeserializerBase)

class StringSerializer(SerializerBase):
    """
      [INTERNAL] C++ includes: serializer.hpp

    ::





    """

    __swig_setmethods__ = {}
    for _s in [SerializerBase]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, StringSerializer, name, value)
    __swig_getmethods__ = {}
    for _s in [SerializerBase]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, StringSerializer, name)
    __repr__ = _swig_repr

    def __init__(self, *args):
        """
          [INTERNAL] 

        ::

          StringSerializer(dict opts)

        Advanced serialization of CasADi objects.

        This class is intended for advanced users that want to circumvent the 

        restrictions of standard pickling/matlab save load, ie no raw SX/MX 
        symbols
         allowed.



        ::

          x = SX.sym('x');
          s = StringSerializer();
          s.pack(x);
          s.pack(sin(x));

          data = s.encode();

          s = StringDeserializer(data);
          a = s.unpack();
          b = s.unpack();




        Note: Saving SX/MX objects individually has a substantial overhead 
        (both 
        time and length of encoded string). You are encouraged to use 
        the 
        vector/list variants of 'save' for SX/MX to reduce the overhead.

        See: 
         Function::save,  Function::serialize,  StringDeserializer,  
        FileSerializer

        Extra doc: https://github.com/casadi/casadi/wiki/L_7o

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/serializer.hpp#L211

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/serializer.cpp#L38-L40




        """
        this = _casadi.new_StringSerializer(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_StringSerializer

    def encode(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          encode(self) -> str

        Returns a string that holds the serialized objects.

        As a side effect, this method clears the internal buffer

        Extra doc: https://github.com/casadi/casadi/wiki/L_7p

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/serializer.hpp#L219

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/serializer.cpp#L87-L92




        """
        return _casadi.StringSerializer_encode(self, *args)

StringSerializer_swigregister = _casadi.StringSerializer_swigregister
StringSerializer_swigregister(StringSerializer)

class FileSerializer(SerializerBase):
    """
      [INTERNAL] C++ includes: serializer.hpp

    ::





    """

    __swig_setmethods__ = {}
    for _s in [SerializerBase]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, FileSerializer, name, value)
    __swig_getmethods__ = {}
    for _s in [SerializerBase]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, FileSerializer, name)
    __repr__ = _swig_repr

    def __init__(self, *args):
        """
          [INTERNAL] 

        ::

          FileSerializer(str fname, dict opts)

        Advanced serialization of CasADi objects.

        See: 
         StringSerializer,  FileDeserializer

        Extra doc: https://github.com/casadi/casadi/wiki/L_7q

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/serializer.hpp#L229

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/serializer.cpp#L42-L47




        """
        this = _casadi.new_FileSerializer(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_FileSerializer
FileSerializer_swigregister = _casadi.FileSerializer_swigregister
FileSerializer_swigregister(FileSerializer)

class StringDeserializer(DeserializerBase):
    """
      [INTERNAL] C++ includes: serializer.hpp

    ::





    """

    __swig_setmethods__ = {}
    for _s in [DeserializerBase]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, StringDeserializer, name, value)
    __swig_getmethods__ = {}
    for _s in [DeserializerBase]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, StringDeserializer, name)
    __repr__ = _swig_repr

    def __init__(self, *args):
        """
          [INTERNAL] 

        ::

          StringDeserializer(str string)

        Advanced deserialization of CasADi objects.

        See: 
         StringDeserializer

        Extra doc: https://github.com/casadi/casadi/wiki/L_7r

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/serializer.hpp#L241

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/serializer.cpp#L117-L120




        """
        this = _casadi.new_StringDeserializer(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_StringDeserializer

    def decode(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          decode(self, str string)

        Sets the string to deserialize objects from.

        Extra doc: https://github.com/casadi/casadi/wiki/L_7s

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/serializer.hpp#L248

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/serializer.cpp#L93-L99




        """
        return _casadi.StringDeserializer_decode(self, *args)

StringDeserializer_swigregister = _casadi.StringDeserializer_swigregister
StringDeserializer_swigregister(StringDeserializer)

class FileDeserializer(DeserializerBase):
    """
      [INTERNAL] C++ includes: serializer.hpp

    ::





    """

    __swig_setmethods__ = {}
    for _s in [DeserializerBase]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, FileDeserializer, name, value)
    __swig_getmethods__ = {}
    for _s in [DeserializerBase]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, FileDeserializer, name)
    __repr__ = _swig_repr

    def __init__(self, *args):
        """
          [INTERNAL] 

        ::

          FileDeserializer(str fname)

        Advanced deserialization of CasADi objects.

        See: 
         FileSerializer

        Extra doc: https://github.com/casadi/casadi/wiki/L_7t

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/serializer.hpp#L258

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/serializer.cpp#L109-L115




        """
        this = _casadi.new_FileDeserializer(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_FileDeserializer
FileDeserializer_swigregister = _casadi.FileDeserializer_swigregister
FileDeserializer_swigregister(FileDeserializer)



try:
  import threading
  _thread_local = threading.local()
except:
  threading_available = True
  _thread_local = globals()

def _current_pickle_context():
  return getattr(_thread_local, "casadi_pickle_ctx", None)

def _current_unpickle_context():
  return getattr(_thread_local, "casadi_unpickle_ctx", None)

class global_pickle_context:
    def __enter__(self):
        self.ctx = StringSerializer()
        _thread_local.casadi_pickle_ctx = self.ctx
        return self.ctx

    def __exit__(self, *args):
        _thread_local.casadi_pickle_ctx = None

class global_unpickle_context:
    def __enter__(self):
        self.ctx = StringDeserializer("")
        _thread_local.casadi_unpickle_ctx = self.ctx
        return self.ctx

    def __exit__(self, *args):
        _thread_local.casadi_unpickle_ctx = None  

class Opti(PrintableCommon, SharedObject):
    """
      [INTERNAL] 

    ::


    A simplified interface for NLP modeling/solving.

    This class offers a view with model description facilities The API is 

    guaranteed to be stable.

    Example NLP:

    ::

        opti = casadi.Opti();

        x = opti.variable();
        y = opti.variable();

        opti.minimize(  (y-x^2)^2   );
        opti.subject_to( x^2+y^2==1 );
        opti.subject_to(     x+y>=1 );

        opti.solver('ipopt');
        sol = opti.solve();

        sol.value(x)
        sol.value(y)



    Example parametric NLP:

    ::

        opti = casadi.Opti();

        x = opti.variable(2,1);
        p = opti.parameter();

        opti.minimize(  (p*x(2)-x(1)^2)^2   );
        opti.subject_to( 1<=sum(x)<=2 );

        opti.solver('ipopt');

        opti.set_value(p, 3);
        sol = opti.solve();
        sol.value(x)

        opti.set_value(p, 5);
        sol = opti.solve();
        sol.value(x)



    Joris Gillis, Erik Lambrechts, Joel Andersson

    Extra doc: https://github.com/casadi/casadi/wiki/L_16

    C++ includes: optistack.hpp



    """

    __swig_setmethods__ = {}
    for _s in [PrintableCommon, SharedObject]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, Opti, name, value)
    __swig_getmethods__ = {}
    for _s in [PrintableCommon, SharedObject]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, Opti, name)
    __repr__ = _swig_repr

    def _variable(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          _variable(self, int n, int m, str attribute) -> MX
          _variable(self, Sparsity sp, str attribute) -> MX
          _variable(self, MX symbol, str attribute) -> MX


        .......

        ::

          _variable(self, int n, int m, str attribute)



        [INTERNAL] 
        Create a decision variable (symbol)

        The order of creation matters. The order will be reflected in the 

        optimization problem. It is not required for decision variables to 
        actualy 
        appear in the optimization problem.

        Parameters:
        -----------

        n: 
        number of rows (default 1)

        m: 
        number of columnss (default 1)

        attribute: 
        'full' (default) or 'symmetric'

        Extra doc: https://github.com/casadi/casadi/wiki/L_18

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L112

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L51-L57



        .............


        .......

        ::

          _variable(self, Sparsity sp, str attribute)
          _variable(self, MX symbol, str attribute)



        [INTERNAL] 

        .............



        """
        return _casadi.Opti__variable(self, *args)


    def _parameter(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          _parameter(self, int n, int m, str attribute) -> MX
          _parameter(self, Sparsity sp, str attribute) -> MX
          _parameter(self, MX symbol, str attribute) -> MX


        .......

        ::

          _parameter(self, Sparsity sp, str attribute)
          _parameter(self, MX symbol, str attribute)



        [INTERNAL] 

        .............


        .......

        ::

          _parameter(self, int n, int m, str attribute)



        [INTERNAL] 
        Create a parameter (symbol); fixed during optimization.

        The order of creation does not matter. It is not required for 
        parameter to 
        actualy appear in the optimization problem. Parameters 
        that do appear, must
         be given a value before the problem can be 
        solved.

        Parameters:
        -----------

        n: 
        number of rows (default 1)

        m: 
        number of columnss (default 1)

        attribute: 
        'full' (default) or 'symmetric'

        Extra doc: https://github.com/casadi/casadi/wiki/L_19

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L127

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L90-L96



        .............



        """
        return _casadi.Opti__parameter(self, *args)


    def minimize(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          minimize(self, MX f, float linear_scale)

        Set objective.

        Objective must be a scalar. Default objective: 0 When method is called

        multiple times, the last call takes effect

        Extra doc: https://github.com/casadi/casadi/wiki/L_1a

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L137

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L114-L120




        """
        return _casadi.Opti_minimize(self, *args)


    def _subject_to(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          _subject_to(self)
          _subject_to(self, MX g, dict options)
          _subject_to(self, [MX] g, dict options)
          _subject_to(self, MX g, DM linear_scale, dict options)
          _subject_to(self, [MX] g, DM linear_scale, dict options)

        Clear constraints.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L172

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L146-L152



        .......

        ::

          _subject_to(self, MX g, dict options)



        [INTERNAL] 
        Add constraints.

        Examples:

        ::

          * \\begin{itemize}
          * opti.subject_to( sqrt(x+y) >= 1);
          * opti.subject_to( sqrt(x+y) > 1)}: same as above
          * opti.subject_to( 1<= sqrt(x+y) )}: same as above
          * opti.subject_to( 5*x+y==1 )}: equality
          *
          * Python
          * opti.subject_to([x*y>=1,x==3])
          * opti.subject_to(opti.bounded(0,x,1))
          *
          * MATLAB
          * opti.subject_to({x*y>=1,x==3})
          * opti.subject_to( 0<=x<=1 )
          * 



        Related functionalities:
        opti.lbg,opti.g,opti.ubg represent the vector of 
        flattened constraints

        opti.debug.show_infeasibilities() may be used to inspect which 
        constraints 
        are violated

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L165

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L122-L128



        .............


        .......

        ::

          _subject_to(self, [MX] g, dict options)



        [INTERNAL] 
        Add constraints.

        Examples:

        ::

          * \\begin{itemize}
          * opti.subject_to( sqrt(x+y) >= 1);
          * opti.subject_to( sqrt(x+y) > 1)}: same as above
          * opti.subject_to( 1<= sqrt(x+y) )}: same as above
          * opti.subject_to( 5*x+y==1 )}: equality
          *
          * Python
          * opti.subject_to([x*y>=1,x==3])
          * opti.subject_to(opti.bounded(0,x,1))
          *
          * MATLAB
          * opti.subject_to({x*y>=1,x==3})
          * opti.subject_to( 0<=x<=1 )
          * 



        Related functionalities:
        opti.lbg,opti.g,opti.ubg represent the vector of 
        flattened constraints

        opti.debug.show_infeasibilities() may be used to inspect which 
        constraints 
        are violated

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L166

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L130-L132



        .............


        .......

        ::

          _subject_to(self, MX g, DM linear_scale, dict options)



        [INTERNAL] 
        Add constraints.

        Examples:

        ::

          * \\begin{itemize}
          * opti.subject_to( sqrt(x+y) >= 1);
          * opti.subject_to( sqrt(x+y) > 1)}: same as above
          * opti.subject_to( 1<= sqrt(x+y) )}: same as above
          * opti.subject_to( 5*x+y==1 )}: equality
          *
          * Python
          * opti.subject_to([x*y>=1,x==3])
          * opti.subject_to(opti.bounded(0,x,1))
          *
          * MATLAB
          * opti.subject_to({x*y>=1,x==3})
          * opti.subject_to( 0<=x<=1 )
          * 



        Related functionalities:
        opti.lbg,opti.g,opti.ubg represent the vector of 
        flattened constraints

        opti.debug.show_infeasibilities() may be used to inspect which 
        constraints 
        are violated

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L167

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L134-L140



        .............


        .......

        ::

          _subject_to(self, [MX] g, DM linear_scale, dict options)



        [INTERNAL] 
        Add constraints.

        Examples:

        ::

          * \\begin{itemize}
          * opti.subject_to( sqrt(x+y) >= 1);
          * opti.subject_to( sqrt(x+y) > 1)}: same as above
          * opti.subject_to( 1<= sqrt(x+y) )}: same as above
          * opti.subject_to( 5*x+y==1 )}: equality
          *
          * Python
          * opti.subject_to([x*y>=1,x==3])
          * opti.subject_to(opti.bounded(0,x,1))
          *
          * MATLAB
          * opti.subject_to({x*y>=1,x==3})
          * opti.subject_to( 0<=x<=1 )
          * 



        Related functionalities:
        opti.lbg,opti.g,opti.ubg represent the vector of 
        flattened constraints

        opti.debug.show_infeasibilities() may be used to inspect which 
        constraints 
        are violated

        Extra doc: https://github.com/casadi/casadi/wiki/L_1b

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L168

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L142-L144



        .............


        .......

        ::

          _subject_to(self)



        [INTERNAL] 
        Clear constraints.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L172

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L146-L152



        .............



        """
        return _casadi.Opti__subject_to(self, *args)


    def solver(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          solver(self, str solver, dict plugin_options, dict solver_options)

        Set a solver.

        Parameters:
        -----------

        solver: 
        any of the nlpsol plugins can be used here In practice, not all 
        nlpsol
         plugins may be supported yet

        options: 
        passed on to nlpsol plugin No stability can be guaranteed about 
        this 
        part of the API

        options: 
        to be passed to nlpsol solver No stability can be guaranteed about

        this part of the API

        Extra doc: https://github.com/casadi/casadi/wiki/L_1c

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L184

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L155-L163




        """
        return _casadi.Opti_solver(self, *args)


    def set_initial(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_initial(self, [MX] assignments)
          set_initial(self, MX x, DM v)

        Set initial guess for decision variables

        ::

          * opti.set_initial(x, 2)
          * opti.set_initial(10*x(1), 2)
          * 



        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L196

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L172-L178



        .......

        ::

          set_initial(self, [MX] assignments)



        [INTERNAL] 
        Set initial guess for decision variables

        ::

          * opti.set_initial(x, 2)
          * opti.set_initial(10*x(1), 2)
          * 



        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L196

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L172-L178



        .............


        .......

        ::

          set_initial(self, MX x, DM v)



        [INTERNAL] 
        Set initial guess for decision variables

        ::

          * opti.set_initial(x, 2)
          * opti.set_initial(10*x(1), 2)
          * 



        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L195

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L165-L171



        .............



        """
        return _casadi.Opti_set_initial(self, *args)


    def set_value(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_value(self, [MX] assignments)
          set_value(self, MX x, DM v)

        Set value of parameter.

        Each parameter must be given a value before 'solve' can be called

        Extra doc: https://github.com/casadi/casadi/wiki/L_1d

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L206

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L205-L211



        .......

        ::

          set_value(self, [MX] assignments)



        [INTERNAL] 
        Set value of parameter.

        Each parameter must be given a value before 'solve' can be called

        Extra doc: https://github.com/casadi/casadi/wiki/L_1d

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L206

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L205-L211



        .............


        .......

        ::

          set_value(self, MX x, DM v)



        [INTERNAL] 
        Set value of parameter.

        Each parameter must be given a value before 'solve' can be called

        Extra doc: https://github.com/casadi/casadi/wiki/L_1d

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L205

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L181-L187



        .............



        """
        return _casadi.Opti_set_value(self, *args)


    def set_domain(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_domain(self, MX x, str domain)

        Set domain of a decision variable.

        Parameters:
        -----------

        x: 
        decision variable

        type: 
        'real', 'integer' (default: real)



        ::

          * opti.set_domain(x, "real")
          * opti.set_domain(x, "integer")
          * 



        Extra doc: https://github.com/casadi/casadi/wiki/L_27t

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L221

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L189-L195




        """
        return _casadi.Opti_set_domain(self, *args)


    def set_linear_scale(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_linear_scale(self, MX x, DM scale, DM offset)

        Set scale of a decision variable.

        (x-offset)/scale will be used in the optimization problem

        Parameters:
        -----------

        x: 
        decision variable

        scale: 
        scaling value (default: 1)

        offset: 
        scaling value (default: 0)



        ::

          * opti.set_linear_scale(x, 20)
          * opti.set_linear_scale(x, 20, 273.15)
          * 



        Extra doc: https://github.com/casadi/casadi/wiki/L_2bs

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L237

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L197-L203




        """
        return _casadi.Opti_set_linear_scale(self, *args)


    def solve(self, *args) -> "casadi::OptiSol":
        """
          [INTERNAL] 

        ::

          solve(self) -> OptiSol

        Crunch the numbers; solve the problem.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L240

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L213-L219




        """
        return _casadi.Opti_solve(self, *args)


    def solve_limited(self, *args) -> "casadi::OptiSol":
        """
          [INTERNAL] 

        ::

          solve_limited(self) -> OptiSol

        Crunch the numbers; solve the problem.

        Allows the solver to return without error when an iteration or time 
        limit 
        is reached

        Extra doc: https://github.com/casadi/casadi/wiki/L_1e

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L248

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L221-L227




        """
        return _casadi.Opti_solve_limited(self, *args)


    def value(self, *args) -> "casadi::native_DM":
        """
          [INTERNAL] 

        ::

          value(self, DM x, [MX] values) -> double
          value(self, SX x, [MX] values) -> double
          value(self, MX x, [MX] values) -> double

        Set domain of a decision variable.

        Parameters:
        -----------

        x: 
        decision variable

        type: 
        'real', 'integer' (default: real)



        ::

          * opti.set_domain(x, "real")
          * opti.set_domain(x, "integer")
          * 



        Extra doc: https://github.com/casadi/casadi/wiki/L_27t

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L261

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L246-L252



        .......

        ::

          value(self, DM x, [MX] values)



        [INTERNAL] 
        Set domain of a decision variable.

        Parameters:
        -----------

        x: 
        decision variable

        type: 
        'real', 'integer' (default: real)



        ::

          * opti.set_domain(x, "real")
          * opti.set_domain(x, "integer")
          * 



        Extra doc: https://github.com/casadi/casadi/wiki/L_27t

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L260

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L238-L244



        .............


        .......

        ::

          value(self, SX x, [MX] values)



        [INTERNAL] 
        Set domain of a decision variable.

        Parameters:
        -----------

        x: 
        decision variable

        type: 
        'real', 'integer' (default: real)



        ::

          * opti.set_domain(x, "real")
          * opti.set_domain(x, "integer")
          * 



        Extra doc: https://github.com/casadi/casadi/wiki/L_27t

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L261

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L246-L252



        .............


        .......

        ::

          value(self, MX x, [MX] values)



        [INTERNAL] 
        Obtain value of expression at the current value

        In regular mode, teh current value is the converged solution In debug 
        mode,
         the value can be non-converged

        Parameters:
        -----------

        values: 
        Optional assignment expressions (e.g. x==3) to overrule the current

        value

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L259

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L229-L235



        .............



        """
        return _casadi.Opti_value(self, *args)


    def stats(self, *args) -> "casadi::Dict":
        """
          [INTERNAL] 

        ::

          stats(self) -> dict

        Get statistics.

        nlpsol stats are passed as-is. No stability can be guaranteed about 
        this 
        part of the API

        Extra doc: https://github.com/casadi/casadi/wiki/L_1f

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L270

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L262-L268




        """
        return _casadi.Opti_stats(self, *args)


    def return_status(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          return_status(self) -> str

        Get return status of solver.



        ::

             passed as-is from nlpsol


        No stability can be guaranteed about this part of the API

        Extra doc: https://github.com/casadi/casadi/wiki/L_1g

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L278

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L270-L276




        """
        return _casadi.Opti_return_status(self, *args)


    def initial(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          initial(self) -> [MX]

        get assignment expressions for initial values

        Extra doc: https://github.com/casadi/casadi/wiki/L_266

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L283

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L278-L284




        """
        return _casadi.Opti_initial(self, *args)


    def value_variables(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          value_variables(self) -> [MX]

        get assignment expressions for latest values

        Extra doc: https://github.com/casadi/casadi/wiki/L_267

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L288

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L286-L292




        """
        return _casadi.Opti_value_variables(self, *args)


    def value_parameters(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          value_parameters(self) -> [MX]



        """
        return _casadi.Opti_value_parameters(self, *args)


    def scale_helper(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          scale_helper(self, Function h) -> Function

        Scale a helper function constructed via opti.x, opti.g, ...

        Extra doc: https://github.com/casadi/casadi/wiki/L_2ci

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L294

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L254-L260




        """
        return _casadi.Opti_scale_helper(self, *args)


    def dual(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          dual(self, MX m) -> MX

        get the dual variable

        m must be a constraint expression. The returned value is still a 
        symbolic 
        expression. Use  value on it to obtain the numerical value.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1h

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L303

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L302-L308




        """
        return _casadi.Opti_dual(self, *args)


    def _nx(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          _nx(self) -> int

        Number of (scalarised) decision variables.

        Extra doc: https://github.com/casadi/casadi/wiki/L_268

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L308

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L310-L316




        """
        return _casadi.Opti__nx(self, *args)


    def _np(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          _np(self) -> int

        Number of (scalarised) parameters.

        Extra doc: https://github.com/casadi/casadi/wiki/L_269

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L313

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L318-L324




        """
        return _casadi.Opti__np(self, *args)


    def _ng(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          _ng(self) -> int

        Number of (scalarised) constraints.

        Extra doc: https://github.com/casadi/casadi/wiki/L_26a

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L318

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L326-L332




        """
        return _casadi.Opti__ng(self, *args)


    def _x(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          _x(self) -> MX

        Get all (scalarised) decision variables as a symbolic column 
        vector.

        Extra doc: https://github.com/casadi/casadi/wiki/L_26b

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L323

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L334-L340




        """
        return _casadi.Opti__x(self, *args)


    def _p(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          _p(self) -> MX

        Get all (scalarised) parameters as a symbolic column vector.

        Extra doc: https://github.com/casadi/casadi/wiki/L_26c

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L328

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L342-L348




        """
        return _casadi.Opti__p(self, *args)


    def _g(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          _g(self) -> MX

        Get all (scalarised) constraint expressions as a column vector.

        Extra doc: https://github.com/casadi/casadi/wiki/L_26d

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L333

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L350-L356




        """
        return _casadi.Opti__g(self, *args)


    def _f(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          _f(self) -> MX

        Get objective expression.

        Extra doc: https://github.com/casadi/casadi/wiki/L_26e

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L338

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L358-L364




        """
        return _casadi.Opti__f(self, *args)


    def _lbg(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          _lbg(self) -> MX

        Get all (scalarised) bounds on constraints as a column vector.

        Extra doc: https://github.com/casadi/casadi/wiki/L_26f

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L343

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L366-L372




        """
        return _casadi.Opti__lbg(self, *args)


    def _ubg(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          _ubg(self) -> MX



        """
        return _casadi.Opti__ubg(self, *args)


    def _x_linear_scale(self, *args) -> "casadi::DM":
        """
          [INTERNAL] 

        ::

          _x_linear_scale(self) -> DM



        """
        return _casadi.Opti__x_linear_scale(self, *args)


    def _x_linear_scale_offset(self, *args) -> "casadi::DM":
        """
          [INTERNAL] 

        ::

          _x_linear_scale_offset(self) -> DM



        """
        return _casadi.Opti__x_linear_scale_offset(self, *args)


    def _g_linear_scale(self, *args) -> "casadi::DM":
        """
          [INTERNAL] 

        ::

          _g_linear_scale(self) -> DM



        """
        return _casadi.Opti__g_linear_scale(self, *args)


    def _f_linear_scale(self, *args) -> "double":
        """
          [INTERNAL] 

        ::

          _f_linear_scale(self) -> float



        """
        return _casadi.Opti__f_linear_scale(self, *args)


    def _lam_g(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          _lam_g(self) -> MX

        Get all (scalarised) dual variables as a symbolic column vector.

        Useful for obtaining the Lagrange Hessian:

        ::

          * sol.value(hessian(opti.f+opti.lam_g'*opti.g,opti.x)) % MATLAB
          * sol.value(hessian(opti.f+dot(opti.lam_g,opti.g),opti.x)[0]) # Python
          * 



        Extra doc: https://github.com/casadi/casadi/wiki/L_1i

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L360

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L383-L389




        """
        return _casadi.Opti__lam_g(self, *args)


    def to_function(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          to_function(self, str name, [MX] args, [MX] res, dict opts) -> Function
          to_function(self, str name, dict:MX dict, [str] name_in, [str] name_out, dict opts) -> Function
          to_function(self, str name, [MX] args, [MX] res, [str] name_in, [str] name_out, dict opts) -> Function

        Create a CasADi  Function from the  Opti solver.

        Parameters:
        -----------

        name: 
        Name of the resulting CasADi  Function

        args: 
        List of parameters and decision/dual variables (which can be given an

        initial guess) with the resulting  Function

        res: 
        List of expressions that will get evaluated at the optimal solution

        opts: 
        Standard CasADi Funcion options

        Extra doc: https://github.com/casadi/casadi/wiki/L_1j

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L382

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L441-L461



        .......

        ::

          to_function(self, str name, [MX] args, [MX] res, dict opts)



        [INTERNAL] 
        Create a CasADi  Function from the  Opti solver.

        Parameters:
        -----------

        name: 
        Name of the resulting CasADi  Function

        args: 
        List of parameters and decision/dual variables (which can be given an

        initial guess) with the resulting  Function

        res: 
        List of expressions that will get evaluated at the optimal solution

        opts: 
        Standard CasADi Funcion options

        Extra doc: https://github.com/casadi/casadi/wiki/L_1j

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L372

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L435-L439



        .............


        .......

        ::

          to_function(self, str name, dict:MX dict, [str] name_in, [str] name_out, dict opts)



        [INTERNAL] 
        Create a CasADi  Function from the  Opti solver.

        Parameters:
        -----------

        name: 
        Name of the resulting CasADi  Function

        args: 
        List of parameters and decision/dual variables (which can be given an

        initial guess) with the resulting  Function

        res: 
        List of expressions that will get evaluated at the optimal solution

        opts: 
        Standard CasADi Funcion options

        Extra doc: https://github.com/casadi/casadi/wiki/L_1j

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L382

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L441-L461



        .............


        .......

        ::

          to_function(self, str name, [MX] args, [MX] res, [str] name_in, [str] name_out, dict opts)



        [INTERNAL] 
        Create a CasADi  Function from the  Opti solver.

        Parameters:
        -----------

        name: 
        Name of the resulting CasADi  Function

        args: 
        List of parameters and decision/dual variables (which can be given an

        initial guess) with the resulting  Function

        res: 
        List of expressions that will get evaluated at the optimal solution

        opts: 
        Standard CasADi Funcion options

        Extra doc: https://github.com/casadi/casadi/wiki/L_1j

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L376

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L423-L433



        .............



        """
        return _casadi.Opti_to_function(self, *args)


    def bounded(*args) -> "casadi::MX":
        """


        ::

          bounded(MX lb, MX expr, MX ub) -> MX



        """
        return _casadi.Opti_bounded(*args)

    bounded = staticmethod(bounded)

    def _debug(self, *args) -> "casadi::OptiAdvanced":
        """
          [INTERNAL] 

        ::

          _debug(self) -> OptiAdvanced

        Get a copy with advanced functionality.

        You get access to more methods, but you have no guarantees about API 

        stability

        The copy is effectively a deep copy: Updating the state of the copy 
        does 
        not update the original.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1l

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L408

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L847-L849




        """
        return _casadi.Opti__debug(self, *args)


    def _advanced(self, *args) -> "casadi::OptiAdvanced":
        """
          [INTERNAL] 

        ::

          _advanced(self) -> OptiAdvanced

        Get a copy with advanced functionality.

        You get access to more methods, but you have no guarantees about API 

        stability

        The copy is effectively a deep copy: Updating the state of the copy 
        does 
        not update the original.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1m

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L418

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L850-L852




        """
        return _casadi.Opti__advanced(self, *args)


    def copy(self, *args) -> "casadi::Opti":
        """
          [INTERNAL] 

        ::

          copy(self) -> Opti

        Get a copy of the.

        The copy is effectively a deep copy: Updating the state of the copy 
        does 
        not update the original.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1n

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L426

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L853-L855




        """
        return _casadi.Opti_copy(self, *args)


    def update_user_dict(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          update_user_dict(self, MX m, dict meta)
          update_user_dict(self, [MX] m, dict meta)


        .......

        ::

          update_user_dict(self, MX m, dict meta)



        [INTERNAL] 
        add user data

        Add arbitrary data in the form of a dictionary to symbols or 
        constraints

        Extra doc: https://github.com/casadi/casadi/wiki/L_1o

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L434

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L479-L485



        .............


        .......

        ::

          update_user_dict(self, [MX] m, dict meta)



        [INTERNAL] 

        .............



        """
        return _casadi.Opti_update_user_dict(self, *args)


    def user_dict(self, *args) -> "casadi::Dict":
        """
          [INTERNAL] 

        ::

          user_dict(self, MX m) -> dict

        Get user data.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L437

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L492-L498




        """
        return _casadi.Opti_user_dict(self, *args)


    def type_name(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          type_name(self) -> str

        Readable name of the class.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L440

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L440-L440




        """
        return _casadi.Opti_type_name(self, *args)


    def disp(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          disp(self, bool more)

        Print representation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L443

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L750-L770




        """
        return _casadi.Opti_disp(self, *args)


    def str(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          str(self, bool more) -> str

        Get string representation.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L446

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L772-L776




        """
        return _casadi.Opti_str(self, *args)


    def callback_class(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          callback_class(self)
          callback_class(self, OptiCallback callback)

        Helper methods for callback()

        Do not use directly.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1p

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L455

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L471-L477



        .......

        ::

          callback_class(self)



        [INTERNAL] 
        Helper methods for callback()

        Do not use directly.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1p

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L455

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L471-L477



        .............


        .......

        ::

          callback_class(self, OptiCallback callback)



        [INTERNAL] 
        Helper methods for callback()

        Do not use directly.

        Extra doc: https://github.com/casadi/casadi/wiki/L_1p

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L454

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L463-L469



        .............



        """
        return _casadi.Opti_callback_class(self, *args)


    @property
    def debug(self):
      return self._debug()


    @property
    def advanced(self):
      return self._advanced()


    @property
    def f(self):
      return self._f()


    @property
    def g(self):
      return self._g()


    @property
    def x(self):
      return self._x()


    @property
    def p(self):
      return self._p()


    @property
    def lam_g(self):
      return self._lam_g()


    @property
    def lbg(self):
      return self._lbg()


    @property
    def ubg(self):
      return self._ubg()


    @property
    def nx(self):
      return self._nx()


    @property
    def np(self):
      return self._np()


    @property
    def ng(self):
      return self._ng()


    @property
    def x_linear_scale(self):
      return self._x_linear_scale()


    @property
    def x_linear_scale_offset(self):
      return self._x_linear_scale_offset()


    @property
    def g_linear_scale(self):
      return self._g_linear_scale()


    @property
    def f_linear_scale(self):
      return self._f_linear_scale()


    @property
    def casadi_solver(self):
      return self._casadi_solver()


    def parameter(self,*args):
      import sys
      import os
      try:
          frame = sys._getframe(1)
      except:
          frame = {}
      meta = {} if frame is None else {"stacktrace": [{"file":os.path.abspath(frame.f_code.co_filename),"line":frame.f_lineno,"name":frame.f_code.co_name}]}
      ret = self._parameter(*args)
      if len(meta)>0:
          self.update_user_dict(ret, meta)
      return ret

    def variable(self,*args):
      import sys
      import os
      try:
          frame = sys._getframe(1)
      except:
          frame = {}
      meta = {} if frame is None else {"stacktrace": [{"file":os.path.abspath(frame.f_code.co_filename),"line":frame.f_lineno,"name":frame.f_code.co_name}]}
      ret = self._variable(*args)
      if len(meta)>0:
          self.update_user_dict(ret, meta)
      return ret

    def subject_to(self,*args):
      if len(args)==0:
        return self._subject_to()
      import sys
      import os
      stacktrace = []
      for i in range(1,10000):
        try:
          frame = sys._getframe(i)
          stacktrace.append({"file":os.path.abspath(frame.f_code.co_filename),"line":frame.f_lineno,"name":frame.f_code.co_name})
        except Exception as e:
          break
      args = list(args)
      if len(args)==3 and isinstance(args[2],dict):
        args[2] = dict(args[2])
        if "stacktrace" not in args[2]:
          args[2]["stacktrace"] = stacktrace
      elif len(args)==2 and isinstance(args[1],dict):
        args[1] = dict(args[1])
        if "stacktrace" not in args[1]:
          args[1]["stacktrace"] = stacktrace
      elif len(args)==1:
        args = [args[0], {"stacktrace": stacktrace}]
      elif len(args)==2:
        args = [args[0], args[1], {"stacktrace": stacktrace}]
      ret = self._subject_to(*args)
      return ret



    @staticmethod
    def _callback(self,fh=None):
      if fh is None:
        self.callback_class();
        return
      class OptiCallbackHelper(OptiCallback):
          def __init__(self, callback):
            OptiCallback.__init__(self)
            self.callback = callback

          def call(self, i):
            self.callback(i)

      self._fh = fh
      self._cb = OptiCallbackHelper(fh);
      self.callback_class(self._cb);


    def callback(self,fh=None):
      self._callback(self,fh)




    def __init__(self, *args):
        """


        ::

          Opti(str problem_type)
          Opti(Opti other)


        .......

        ::

          Opti(Opti other)



        .............


        .......

        ::

          Opti(str problem_type)



        [INTERNAL] 
        Create  Opti Context.

        Parameters:
        -----------

        problem_type: 
        of optimization 'nlp' or 'conic' (default nlp)

        Extra doc: https://github.com/casadi/casadi/wiki/L_17

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L99

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L47-L49



        .............



        """
        this = _casadi.new_Opti(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_Opti
Opti_swigregister = _casadi.Opti_swigregister
Opti_swigregister(Opti)

def Opti_bounded(*args) -> "casadi::MX":
    """


    ::

      bounded(MX lb, MX expr, MX ub) -> MX



    """
    return _casadi.Opti_bounded(*args)

OPTI_GENERIC_EQUALITY = _casadi.OPTI_GENERIC_EQUALITY
OPTI_GENERIC_INEQUALITY = _casadi.OPTI_GENERIC_INEQUALITY
OPTI_EQUALITY = _casadi.OPTI_EQUALITY
OPTI_INEQUALITY = _casadi.OPTI_INEQUALITY
OPTI_DOUBLE_INEQUALITY = _casadi.OPTI_DOUBLE_INEQUALITY
OPTI_PSD = _casadi.OPTI_PSD
OPTI_UNKNOWN = _casadi.OPTI_UNKNOWN
OPTI_VAR = _casadi.OPTI_VAR
OPTI_PAR = _casadi.OPTI_PAR
OPTI_DUAL_G = _casadi.OPTI_DUAL_G
OPTI_DOMAIN_REAL = _casadi.OPTI_DOMAIN_REAL
OPTI_DOMAIN_INTEGER = _casadi.OPTI_DOMAIN_INTEGER
class IndexAbstraction(_object):
    """


    ::

      IndexAbstraction() -> 



    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, IndexAbstraction, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, IndexAbstraction, name)
    __repr__ = _swig_repr
    __swig_getmethods__["start"] = _casadi.IndexAbstraction_start_get
    if _newclass:
        start = _swig_property(_casadi.IndexAbstraction_start_get)
    __swig_getmethods__["stop"] = _casadi.IndexAbstraction_stop_get
    if _newclass:
        stop = _swig_property(_casadi.IndexAbstraction_stop_get)

    def __init__(self, *args):
        """


        ::

          IndexAbstraction()
          IndexAbstraction(IndexAbstraction other)



        """
        this = _casadi.new_IndexAbstraction(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_IndexAbstraction
IndexAbstraction_swigregister = _casadi.IndexAbstraction_swigregister
IndexAbstraction_swigregister(IndexAbstraction)

class MetaCon(IndexAbstraction):
    """


    ::

      MetaCon() -> 



    """

    __swig_setmethods__ = {}
    for _s in [IndexAbstraction]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, MetaCon, name, value)
    __swig_getmethods__ = {}
    for _s in [IndexAbstraction]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, MetaCon, name)
    __repr__ = _swig_repr
    __swig_getmethods__["original"] = _casadi.MetaCon_original_get
    if _newclass:
        original = _swig_property(_casadi.MetaCon_original_get)
    __swig_getmethods__["canon"] = _casadi.MetaCon_canon_get
    if _newclass:
        canon = _swig_property(_casadi.MetaCon_canon_get)
    __swig_getmethods__["type"] = _casadi.MetaCon_type_get
    if _newclass:
        type = _swig_property(_casadi.MetaCon_type_get)
    __swig_getmethods__["lb"] = _casadi.MetaCon_lb_get
    if _newclass:
        lb = _swig_property(_casadi.MetaCon_lb_get)
    __swig_getmethods__["ub"] = _casadi.MetaCon_ub_get
    if _newclass:
        ub = _swig_property(_casadi.MetaCon_ub_get)
    __swig_getmethods__["n"] = _casadi.MetaCon_n_get
    if _newclass:
        n = _swig_property(_casadi.MetaCon_n_get)
    __swig_getmethods__["flipped"] = _casadi.MetaCon_flipped_get
    if _newclass:
        flipped = _swig_property(_casadi.MetaCon_flipped_get)
    __swig_getmethods__["dual_canon"] = _casadi.MetaCon_dual_canon_get
    if _newclass:
        dual_canon = _swig_property(_casadi.MetaCon_dual_canon_get)
    __swig_getmethods__["dual"] = _casadi.MetaCon_dual_get
    if _newclass:
        dual = _swig_property(_casadi.MetaCon_dual_get)
    __swig_getmethods__["extra"] = _casadi.MetaCon_extra_get
    if _newclass:
        extra = _swig_property(_casadi.MetaCon_extra_get)
    __swig_getmethods__["linear_scale"] = _casadi.MetaCon_linear_scale_get
    if _newclass:
        linear_scale = _swig_property(_casadi.MetaCon_linear_scale_get)

    def __init__(self, *args):
        """


        ::

          MetaCon()
          MetaCon(MetaCon other)



        """
        this = _casadi.new_MetaCon(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_MetaCon
MetaCon_swigregister = _casadi.MetaCon_swigregister
MetaCon_swigregister(MetaCon)

class MetaVar(IndexAbstraction):
    """


    ::

      MetaVar() -> 



    """

    __swig_setmethods__ = {}
    for _s in [IndexAbstraction]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, MetaVar, name, value)
    __swig_getmethods__ = {}
    for _s in [IndexAbstraction]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, MetaVar, name)
    __repr__ = _swig_repr
    __swig_getmethods__["attribute"] = _casadi.MetaVar_attribute_get
    if _newclass:
        attribute = _swig_property(_casadi.MetaVar_attribute_get)
    __swig_getmethods__["n"] = _casadi.MetaVar_n_get
    if _newclass:
        n = _swig_property(_casadi.MetaVar_n_get)
    __swig_getmethods__["m"] = _casadi.MetaVar_m_get
    if _newclass:
        m = _swig_property(_casadi.MetaVar_m_get)
    __swig_getmethods__["type"] = _casadi.MetaVar_type_get
    if _newclass:
        type = _swig_property(_casadi.MetaVar_type_get)
    __swig_getmethods__["domain"] = _casadi.MetaVar_domain_get
    if _newclass:
        domain = _swig_property(_casadi.MetaVar_domain_get)
    __swig_getmethods__["count"] = _casadi.MetaVar_count_get
    if _newclass:
        count = _swig_property(_casadi.MetaVar_count_get)
    __swig_getmethods__["i"] = _casadi.MetaVar_i_get
    if _newclass:
        i = _swig_property(_casadi.MetaVar_i_get)
    __swig_getmethods__["active_i"] = _casadi.MetaVar_active_i_get
    if _newclass:
        active_i = _swig_property(_casadi.MetaVar_active_i_get)
    __swig_getmethods__["extra"] = _casadi.MetaVar_extra_get
    if _newclass:
        extra = _swig_property(_casadi.MetaVar_extra_get)

    def __init__(self, *args):
        """


        ::

          MetaVar()
          MetaVar(MetaVar other)



        """
        this = _casadi.new_MetaVar(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_MetaVar
MetaVar_swigregister = _casadi.MetaVar_swigregister
MetaVar_swigregister(MetaVar)

class OptiCallback(_object):
    """
      [INTERNAL] C++ includes: optistack.hpp

    ::





    """

    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, OptiCallback, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, OptiCallback, name)
    __repr__ = _swig_repr

    def __init__(self, *args):
        """
          [INTERNAL] 

        ::

          OptiCallback(self)
          OptiCallback(self, OptiCallback obj)



        """
        if self.__class__ == OptiCallback:
            _self = None
        else:
            _self = self
        this = _casadi.new_OptiCallback(_self, *args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this

    def call(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          call(self, int i)



        """
        return _casadi.OptiCallback_call(self, *args)

    __swig_destroy__ = _casadi.delete_OptiCallback
    def __disown__(self):
        self.this.disown()
        _casadi.disown_OptiCallback(self)
        return weakref_proxy(self)
OptiCallback_swigregister = _casadi.OptiCallback_swigregister
OptiCallback_swigregister(OptiCallback)

class OptiAdvanced(Opti):
    """
      [INTERNAL] C++ includes: optistack.hpp

    ::





    """

    __swig_setmethods__ = {}
    for _s in [Opti]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, OptiAdvanced, name, value)
    __swig_getmethods__ = {}
    for _s in [Opti]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, OptiAdvanced, name)
    __repr__ = _swig_repr
    __swig_destroy__ = _casadi.delete_OptiAdvanced

    def _casadi_solver(self, *args) -> "casadi::Function":
        """
          [INTERNAL] 

        ::

          _casadi_solver(self) -> Function

        Get the underlying CasADi solver of the  Opti stack.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L564

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L500-L506




        """
        return _casadi.OptiAdvanced__casadi_solver(self, *args)


    def is_parametric(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          is_parametric(self, MX expr) -> bool

        return true if expression is only dependant on  Opti parameters,
         not variables

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L567

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L508-L514




        """
        return _casadi.OptiAdvanced_is_parametric(self, *args)


    def symvar(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          symvar(self) -> [MX]
          symvar(self, MX expr) -> [MX]
          symvar(self, MX expr, casadi::VariableType type) -> [MX]

        Get symbols present in expression.

        Returned vector is ordered according to the order of  variable()/parameter()
         calls used to create the variables

        Extra doc: https://github.com/casadi/casadi/wiki/L_1u

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L578

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L532-L538



        .......

        ::

          symvar(self)



        [INTERNAL] 
        Get symbols present in expression.

        Returned vector is ordered according to the order of  variable()/parameter()
         calls used to create the variables

        Extra doc: https://github.com/casadi/casadi/wiki/L_1u

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L576

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L516-L522



        .............


        .......

        ::

          symvar(self, MX expr)



        [INTERNAL] 
        Get symbols present in expression.

        Returned vector is ordered according to the order of  variable()/parameter()
         calls used to create the variables

        Extra doc: https://github.com/casadi/casadi/wiki/L_1u

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L577

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L524-L530



        .............


        .......

        ::

          symvar(self, MX expr, casadi::VariableType type)



        [INTERNAL] 
        Get symbols present in expression.

        Returned vector is ordered according to the order of  variable()/parameter()
         calls used to create the variables

        Extra doc: https://github.com/casadi/casadi/wiki/L_1u

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L578

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L532-L538



        .............



        """
        return _casadi.OptiAdvanced_symvar(self, *args)


    def canon_expr(self, *args) -> "casadi::MetaCon":
        """
          [INTERNAL] 

        ::

          canon_expr(self, MX expr) -> MetaCon

        Interpret an expression (for internal use only)

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L582

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L540-L546




        """
        return _casadi.OptiAdvanced_canon_expr(self, *args)


    def get_meta(self, *args) -> "casadi::MetaVar":
        """
          [INTERNAL] 

        ::

          get_meta(self, MX m) -> MetaVar

        Get meta-data of symbol (for internal use only)

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L585

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L548-L554




        """
        return _casadi.OptiAdvanced_get_meta(self, *args)


    def get_meta_con(self, *args) -> "casadi::MetaCon":
        """
          [INTERNAL] 

        ::

          get_meta_con(self, MX m) -> MetaCon

        Get meta-data of symbol (for internal use only)

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L588

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L556-L562




        """
        return _casadi.OptiAdvanced_get_meta_con(self, *args)


    def set_meta(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_meta(self, MX m, MetaVar meta)

        Set meta-data of an expression.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L591

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L564-L570




        """
        return _casadi.OptiAdvanced_set_meta(self, *args)


    def set_meta_con(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          set_meta_con(self, MX m, MetaCon meta)

        Set meta-data of an expression.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L594

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L572-L578




        """
        return _casadi.OptiAdvanced_set_meta_con(self, *args)


    def assert_active_symbol(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          assert_active_symbol(self, MX m)



        """
        return _casadi.OptiAdvanced_assert_active_symbol(self, *args)


    def active_symvar(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          active_symvar(self, casadi::VariableType type) -> [MX]



        """
        return _casadi.OptiAdvanced_active_symvar(self, *args)


    def active_values(self, *args) -> "std::vector< casadi::DM,std::allocator< casadi::DM > >":
        """
          [INTERNAL] 

        ::

          active_values(self, casadi::VariableType type) -> [DM]



        """
        return _casadi.OptiAdvanced_active_values(self, *args)


    def x_lookup(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          x_lookup(self, int i) -> MX



        """
        return _casadi.OptiAdvanced_x_lookup(self, *args)


    def g_lookup(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          g_lookup(self, int i) -> MX



        """
        return _casadi.OptiAdvanced_g_lookup(self, *args)


    def g_index_reduce_g(self, *args) -> "casadi_index":
        """
          [INTERNAL] 

        ::

          g_index_reduce_g(self, int i) -> int



        """
        return _casadi.OptiAdvanced_g_index_reduce_g(self, *args)


    def g_index_reduce_x(self, *args) -> "casadi_index":
        """
          [INTERNAL] 

        ::

          g_index_reduce_x(self, int i) -> int



        """
        return _casadi.OptiAdvanced_g_index_reduce_x(self, *args)


    def g_index_unreduce_g(self, *args) -> "casadi_index":
        """
          [INTERNAL] 

        ::

          g_index_unreduce_g(self, int i) -> int



        """
        return _casadi.OptiAdvanced_g_index_unreduce_g(self, *args)


    def x_describe(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          x_describe(self, int i, dict opts) -> str



        """
        return _casadi.OptiAdvanced_x_describe(self, *args)


    def g_describe(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          g_describe(self, int i, dict opts) -> str



        """
        return _casadi.OptiAdvanced_g_describe(self, *args)


    def describe(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          describe(self, MX x, int indent, dict opts) -> str



        """
        return _casadi.OptiAdvanced_describe(self, *args)


    def show_infeasibilities(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          show_infeasibilities(self, float tol, dict opts)



        """
        return _casadi.OptiAdvanced_show_infeasibilities(self, *args)


    def solve_prepare(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          solve_prepare(self)



        """
        return _casadi.OptiAdvanced_solve_prepare(self, *args)


    def solve_actual(self, *args) -> "casadi::DMDict":
        """
          [INTERNAL] 

        ::

          solve_actual(self, dict:DM args) -> dict:DM



        """
        return _casadi.OptiAdvanced_solve_actual(self, *args)


    def arg(self, *args) -> "casadi::DMDict":
        """
          [INTERNAL] 

        ::

          arg(self) -> dict:DM



        """
        return _casadi.OptiAdvanced_arg(self, *args)


    def res(self, *args) -> "casadi::DMDict":
        """
          [INTERNAL] 

        ::

          res(self) -> dict:DM
          res(self, dict:DM res)



        """
        return _casadi.OptiAdvanced_res(self, *args)


    def constraints(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          constraints(self) -> [MX]



        """
        return _casadi.OptiAdvanced_constraints(self, *args)


    def objective(self, *args) -> "casadi::MX":
        """
          [INTERNAL] 

        ::

          objective(self) -> MX



        """
        return _casadi.OptiAdvanced_objective(self, *args)


    def baked_copy(self, *args) -> "casadi::OptiAdvanced":
        """
          [INTERNAL] 

        ::

          baked_copy(self) -> OptiAdvanced



        """
        return _casadi.OptiAdvanced_baked_copy(self, *args)


    def assert_empty(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          assert_empty(self)



        """
        return _casadi.OptiAdvanced_assert_empty(self, *args)


    def bake(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          bake(self)

        Fix the structure of the optimization problem.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L629

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L778-L784




        """
        return _casadi.OptiAdvanced_bake(self, *args)

    __swig_getmethods__["problem_dirty_"] = _casadi.OptiAdvanced_problem_dirty__get
    if _newclass:
        problem_dirty_ = _swig_property(_casadi.OptiAdvanced_problem_dirty__get)

    def mark_problem_dirty(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          mark_problem_dirty(self, bool flag)



        """
        return _casadi.OptiAdvanced_mark_problem_dirty(self, *args)


    def problem_dirty(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          problem_dirty(self) -> bool



        """
        return _casadi.OptiAdvanced_problem_dirty(self, *args)

    __swig_getmethods__["solver_dirty_"] = _casadi.OptiAdvanced_solver_dirty__get
    if _newclass:
        solver_dirty_ = _swig_property(_casadi.OptiAdvanced_solver_dirty__get)

    def mark_solver_dirty(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          mark_solver_dirty(self, bool flag)



        """
        return _casadi.OptiAdvanced_mark_solver_dirty(self, *args)


    def solver_dirty(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          solver_dirty(self) -> bool



        """
        return _casadi.OptiAdvanced_solver_dirty(self, *args)

    __swig_getmethods__["solved_"] = _casadi.OptiAdvanced_solved__get
    if _newclass:
        solved_ = _swig_property(_casadi.OptiAdvanced_solved__get)

    def mark_solved(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          mark_solved(self, bool flag)



        """
        return _casadi.OptiAdvanced_mark_solved(self, *args)


    def solved(self, *args) -> "bool":
        """
          [INTERNAL] 

        ::

          solved(self) -> bool



        """
        return _casadi.OptiAdvanced_solved(self, *args)


    def assert_solved(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          assert_solved(self)



        """
        return _casadi.OptiAdvanced_assert_solved(self, *args)


    def assert_baked(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          assert_baked(self)



        """
        return _casadi.OptiAdvanced_assert_baked(self, *args)


    def instance_number(self, *args) -> "casadi_int":
        """
          [INTERNAL] 

        ::

          instance_number(self) -> int



        """
        return _casadi.OptiAdvanced_instance_number(self, *args)


    def __init__(self, *args):
        """


        ::

          OptiAdvanced(OptiAdvanced other)
          OptiAdvanced(Opti x)


        .......

        ::

          OptiAdvanced(OptiAdvanced other)



        .............


        .......

        ::

          OptiAdvanced(Opti x)



        [INTERNAL] 

        .............



        """
        this = _casadi.new_OptiAdvanced(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
OptiAdvanced_swigregister = _casadi.OptiAdvanced_swigregister
OptiAdvanced_swigregister(OptiAdvanced)

class OptiSol(PrintableCommon):
    """
      [INTERNAL] 

    ::


    A simplified interface for NLP modeling/solving.

    This class offers a view with solution retrieval facilities The API is

    guaranteed to be stable.

    Joris Gillis, Erik Lambrechts

    Extra doc: https://github.com/casadi/casadi/wiki/L_1v

    C++ includes: optistack.hpp



    """

    __swig_setmethods__ = {}
    for _s in [PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, OptiSol, name, value)
    __swig_getmethods__ = {}
    for _s in [PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, OptiSol, name)
    __repr__ = _swig_repr

    def type_name(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          type_name(self) -> str



        """
        return _casadi.OptiSol_type_name(self, *args)


    def disp(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          disp(self, bool more)



        """
        return _casadi.OptiSol_disp(self, *args)


    def str(self, *args) -> "std::string":
        """
          [INTERNAL] 

        ::

          str(self, bool more) -> str



        """
        return _casadi.OptiSol_str(self, *args)


    def value(self, *args) -> "casadi::native_DM":
        """
          [INTERNAL] 

        ::

          value(self, DM x, [MX] values) -> double
          value(self, SX x, [MX] values) -> double
          value(self, MX x, [MX] values) -> double

        Obtain value of expression at the current value

        In regular mode, teh current value is the converged solution In debug 
        mode,
         the value can be non-converged

        Parameters:
        -----------

        values: 
        Optional assignment expressions (e.g. x==3) to overrule the current

        value

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L679

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L874-L876



        .......

        ::

          value(self, DM x, [MX] values)



        [INTERNAL] 
        Obtain value of expression at the current value

        In regular mode, teh current value is the converged solution In debug 
        mode,
         the value can be non-converged

        Parameters:
        -----------

        values: 
        Optional assignment expressions (e.g. x==3) to overrule the current

        value

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L678

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L871-L873



        .............


        .......

        ::

          value(self, SX x, [MX] values)



        [INTERNAL] 
        Obtain value of expression at the current value

        In regular mode, teh current value is the converged solution In debug 
        mode,
         the value can be non-converged

        Parameters:
        -----------

        values: 
        Optional assignment expressions (e.g. x==3) to overrule the current

        value

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L679

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L874-L876



        .............


        .......

        ::

          value(self, MX x, [MX] values)



        [INTERNAL] 
        Obtain value of expression at the current value

        In regular mode, teh current value is the converged solution In debug 
        mode,
         the value can be non-converged

        Parameters:
        -----------

        values: 
        Optional assignment expressions (e.g. x==3) to overrule the current

        value

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L677

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L868-L870



        .............



        """
        return _casadi.OptiSol_value(self, *args)


    def value_variables(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          value_variables(self) -> [MX]

        get assignment expressions for the optimal solution

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L683

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L878-L880




        """
        return _casadi.OptiSol_value_variables(self, *args)


    def value_parameters(self, *args) -> "std::vector< casadi::MX,std::allocator< casadi::MX > >":
        """
          [INTERNAL] 

        ::

          value_parameters(self) -> [MX]



        """
        return _casadi.OptiSol_value_parameters(self, *args)


    def stats(self, *args) -> "casadi::Dict":
        """
          [INTERNAL] 

        ::

          stats(self) -> dict

        Get statistics.

        nlpsol stats are passed as-is. No stability can be guaranteed about 
        this 
        part of the API

        Extra doc: https://github.com/casadi/casadi/wiki/L_1w

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.hpp#L692

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/optistack.cpp#L886-L888




        """
        return _casadi.OptiSol_stats(self, *args)


    def _opti(self, *args) -> "casadi::Opti":
        """
          [INTERNAL] 

        ::

          _opti(self) -> Opti



        """
        return _casadi.OptiSol__opti(self, *args)


    @property
    def opti(self):
      return self._opti()


    @property
    def debug(self):
      return self._debug()


    def __init__(self, *args):
        """


        ::

          OptiSol(OptiSol other)



        """
        this = _casadi.new_OptiSol(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_OptiSol
OptiSol_swigregister = _casadi.OptiSol_swigregister
OptiSol_swigregister(OptiSol)

class Resource(SharedObject, PrintableCommon):
    """
      [INTERNAL] 

    ::


    RAII class for reading from a zip file.

    Extra doc: https://github.com/casadi/casadi/wiki/L_2cn

    C++ includes: resource.hpp



    """

    __swig_setmethods__ = {}
    for _s in [SharedObject, PrintableCommon]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, Resource, name, value)
    __swig_getmethods__ = {}
    for _s in [SharedObject, PrintableCommon]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, Resource, name)
    __repr__ = _swig_repr

    def type_name(*args) -> "std::string":
        """


        ::

          type_name() -> str



        """
        return _casadi.Resource_type_name(*args)

    type_name = staticmethod(type_name)

    def test_cast(*args) -> "bool":
        """


        ::

          test_cast(casadi::SharedObjectInternal const * ptr) -> bool



        """
        return _casadi.Resource_test_cast(*args)

    test_cast = staticmethod(test_cast)

    def path(self, *args) -> "std::string const &":
        """
          [INTERNAL] 

        ::

          path(self) -> str

        Get path for a consumer.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/resource.hpp#L83

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/resource.cpp#L70-L72




        """
        return _casadi.Resource_path(self, *args)


    def serialize(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          serialize(self, casadi::SerializingStream & s)

        Serialize an object.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2cq

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/resource.hpp#L88

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/resource.cpp#L78-L80




        """
        return _casadi.Resource_serialize(self, *args)


    def change_option(self, *args) -> "void":
        """
          [INTERNAL] 

        ::

          change_option(self, str option_name, GenericType option_value)

        Change option after object creation for debugging.

        This is only possible for a selected number of options that do not 
        change 
        the numerical results of the comput

        Extra doc: https://github.com/casadi/casadi/wiki/L_2d4

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/resource.hpp#L96

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/resource.cpp#L74-L76




        """
        return _casadi.Resource_change_option(self, *args)


    def deserialize(*args) -> "casadi::Resource":
        """


        ::

          deserialize(casadi::DeserializingStream & s) -> Resource



        """
        return _casadi.Resource_deserialize(*args)

    deserialize = staticmethod(deserialize)

    def __init__(self, *args):
        """


        ::

          Resource()
          Resource(Resource other)
          Resource(str path)


        .......

        ::

          Resource(Resource other)



        .............


        .......

        ::

          Resource()



        [INTERNAL] 
        Default constructor.

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/resource.hpp#L56

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/resource.cpp#L32-L33



        .............


        .......

        ::

          Resource(str path)



        [INTERNAL] 
        Initialize with a path.

        If the path is a directory or empty, the path is passed through to the

        consumer. Otherwise, the zip file is extracted to a temporary 
        directory.

        Upon destruction, the temporary directory is removed.

        Extra doc: https://github.com/casadi/casadi/wiki/L_2co

        Doc source: 
        https://github.com/casadi/casadi/blob/main/casadi/core/resource.hpp#L54

        Implementation: 
        https://github.com/casadi/casadi/blob/main/casadi/core/resource.cpp#L35-L42



        .............



        """
        this = _casadi.new_Resource(*args)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this
    __swig_destroy__ = _casadi.delete_Resource
Resource_swigregister = _casadi.Resource_swigregister
Resource_swigregister(Resource)

def Resource_type_name(*args) -> "std::string":
    """


    ::

      type_name() -> str



    """
    return _casadi.Resource_type_name(*args)

def Resource_test_cast(*args) -> "bool":
    """


    ::

      test_cast(casadi::SharedObjectInternal const * ptr) -> bool



    """
    return _casadi.Resource_test_cast(*args)

def Resource_deserialize(*args) -> "casadi::Resource":
    """


    ::

      deserialize(casadi::DeserializingStream & s) -> Resource



    """
    return _casadi.Resource_deserialize(*args)

# This file is compatible with both classic and new-style classes.


