def _u0Eq(logu,delta,pot,E,Lz22):
    """The equation that needs to be minimized to find u0"""
    u= numpy.exp(logu)
    sinh2u= numpy.sinh(u)**2.
    cosh2u= numpy.cosh(u)**2.
    dU= cosh2u*actionAngleStaeckel.potentialStaeckel(u,numpy.pi/2.,pot,delta)
    return -(E*sinh2u-dU-Lz22/delta**2./sinh2u)
def _u0Eq ( logu , delta , pot , E , Lz22 ) : u = numpy . exp ( logu ) sinh2u = numpy . sinh ( u ) ** 2. cosh2u = numpy . cosh ( u ) ** 2. dU = cosh2u * actionAngleStaeckel . potentialStaeckel ( u , numpy . pi / 2. , pot , delta ) return - ( E * sinh2u - dU - Lz22 / delta ** 2. / sinh2u )
The equation that needs to be minimized to find u0