[Scipy-svn] r2219 - in trunk/Lib: integrate interpolate optimize

scipy-svn at scipy.org scipy-svn at scipy.org
Sat Sep 23 17:56:54 EDT 2006


Author: rkern
Date: 2006-09-23 16:56:21 -0500 (Sat, 23 Sep 2006)
New Revision: 2219

Modified:
   trunk/Lib/integrate/ode.py
   trunk/Lib/integrate/odepack.py
   trunk/Lib/integrate/quadpack.py
   trunk/Lib/integrate/quadrature.py
   trunk/Lib/interpolate/fitpack.py
   trunk/Lib/interpolate/fitpack2.py
   trunk/Lib/interpolate/info.py
   trunk/Lib/optimize/anneal.py
   trunk/Lib/optimize/cobyla.py
   trunk/Lib/optimize/lbfgsb.py
   trunk/Lib/optimize/minpack.py
   trunk/Lib/optimize/optimize.py
   trunk/Lib/optimize/tnc.py
   trunk/Lib/optimize/zeros.py
Log:
Add cross-reference information to docstrings.

Modified: trunk/Lib/integrate/ode.py
===================================================================
--- trunk/Lib/integrate/ode.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/integrate/ode.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -118,6 +118,10 @@
         return <f(t,y)>
     def jac(t,y[,arg1,..]):
         return <df/dy(t,y)>
+
+See also:
+    odeint - an integrator with a simpler interface based on lsoda from ODEPACK
+    quad - for finding the area under a curve
     """
 
     def __init__(self,f,jac=None):

Modified: trunk/Lib/integrate/odepack.py
===================================================================
--- trunk/Lib/integrate/odepack.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/integrate/odepack.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -108,6 +108,9 @@
       mxordn -- maximum order to be allowed for the nonstiff (Adams) method.
       mxords -- maximum order to be allowed for the stiff (BDF) method.
 
+    See also:
+      ode - a more object-oriented integrator based on VODE
+      quad - for finding the area under a curve
     """
 
     if ml is None:

Modified: trunk/Lib/integrate/quadpack.py
===================================================================
--- trunk/Lib/integrate/quadpack.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/integrate/quadpack.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -174,6 +174,13 @@
     wopts -- Optional input for reusing Chebyshev moments.
     maxp1 -- An upper bound on the number of Chebyshev moments.
 
+    See also:
+      dblquad, tplquad - double and triple integrals
+      fixed_quad - fixed-order Gaussian quadrature
+      quadrature - adaptive Gaussian quadrature
+      odeint, ode - ODE integrators
+      simps, trapz, romb - integrators for sampled data
+      scipy.special - for coefficients and roots of orthogonal polynomials
     """
     if type(args) != type(()): args = (args,)
     if (weight is None):
@@ -332,6 +339,14 @@
     y -- the resultant integral.
     abserr -- an estimate of the error.
 
+    See also:
+      quad - single integral
+      tplquad - triple integral
+      fixed_quad - fixed-order Gaussian quadrature
+      quadrature - adaptive Gaussian quadrature
+      odeint, ode - ODE integrators
+      simps, trapz, romb - integrators for sampled data
+      scipy.special - for coefficients and roots of orthogonal polynomials
     """
     return quad(_infunc,a,b,(func,gfun,hfun,args),epsabs=epsabs,epsrel=epsrel)
 
@@ -372,5 +387,13 @@
     y -- the resultant integral.
     abserr -- an estimate of the error.
 
+  See also:
+    quad - single integral
+    dblquad - double integral
+    fixed_quad - fixed-order Gaussian quadrature
+    quadrature - adaptive Gaussian quadrature
+    odeint, ode - ODE integrators
+    simps, trapz, romb - integrators for sampled data
+    scipy.special - for coefficients and roots of orthogonal polynomials
     """
     return dblquad(_infunc2,a,b,gfun,hfun,(func,qfun,rfun,args),epsabs=epsabs,epsrel=epsrel)

Modified: trunk/Lib/integrate/quadrature.py
===================================================================
--- trunk/Lib/integrate/quadrature.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/integrate/quadrature.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -29,11 +29,19 @@
 
     val -- Gaussian quadrature approximation to the integral.
 
+  See also:
+    
+    quad - adaptive quadrature using QUADPACK
+    dblquad, tplquad - double and triple integrals
+    romberg - adaptive Romberg quadrature
+    quadrature - adaptive Gaussian quadrature
+    romb, simps, trapz - integrators for sampled data
+    cumtrapz - cumulative integration for sampled data
+    ode, odeint - ODE integrators
     """
     [x,w] = p_roots(n)
     x = real(x)
-    ainf, binf = map(isinf,(a,b))
-    if ainf or binf:
+    ainf, binf = map(isinf,(a,b)) if ainf or binf:
         raise ValueError, "Gaussian quadrature is only available for " \
               "finite limits."
     y = (b-a)*(x+1)/2.0 + a
@@ -83,6 +91,15 @@
     val -- Gaussian quadrature approximation (within tolerance) to integral.
     err -- Difference between last two estimates of the integral.
 
+  See also:
+    
+    romberg - adaptive Romberg quadrature
+    fixed_quad - fixed-order Gaussian quadrature
+    quad - adaptive quadrature using QUADPACK
+    dblquad, tplquad - double and triple integrals
+    romb, simps, trapz - integrators for sampled data
+    cumtrapz - cumulative integration for sampled data
+    ode, odeint - ODE integrators
     """
     err = 100.0
     val = err
@@ -108,6 +125,17 @@
     """Cumulatively integrate y(x) using samples along the given axis
     and the composite trapezoidal rule.  If x is None, spacing given by dx
     is assumed.
+
+    See also:
+    
+      quad - adaptive quadrature using QUADPACK
+      romberg - adaptive Romberg quadrature
+      quadrature - adaptive Gaussian quadrature
+      fixed_quad - fixed-order Gaussian quadrature
+      dblquad, tplquad - double and triple integrals
+      romb, trapz - integrators for sampled data
+      cumtrapz - cumulative integration for sampled data
+      ode, odeint - ODE integrators
     """
     y = asarray(y)
     if x is None:
@@ -172,6 +200,17 @@
         exact if the function is a polynomial of order 3 or less.  If
         the samples are not equally spaced, then the result is exact only
         if the function is a polynomial of order 2 or less.
+
+    See also:
+    
+      quad - adaptive quadrature using QUADPACK
+      romberg - adaptive Romberg quadrature
+      quadrature - adaptive Gaussian quadrature
+      fixed_quad - fixed-order Gaussian quadrature
+      dblquad, tplquad - double and triple integrals
+      romb, trapz - integrators for sampled data
+      cumtrapz - cumulative integration for sampled data
+      ode, odeint - ODE integrators
     """
     y = asarray(y)
     nd = len(y.shape)
@@ -231,6 +270,17 @@
     """Uses Romberg integration to integrate y(x) using N samples
     along the given axis which are assumed equally spaced with distance dx.
     The number of samples must be 1 + a non-negative power of two: N=2**k + 1
+
+    See also:
+    
+      quad - adaptive quadrature using QUADPACK
+      romberg - adaptive Romberg quadrature
+      quadrature - adaptive Gaussian quadrature
+      fixed_quad - fixed-order Gaussian quadrature
+      dblquad, tplquad - double and triple integrals
+      simps, trapz - integrators for sampled data
+      cumtrapz - cumulative integration for sampled data
+      ode, odeint - ODE integrators
     """
     y = asarray(y)
     nd = len(y.shape)
@@ -361,6 +411,16 @@
     the triangular array of the intermediate results will be printed.
     If |vec_func| is True (default is False), then |function| is
     assumed to support vector arguments.
+
+    See also:
+    
+      quad - adaptive quadrature using QUADPACK
+      quadrature - adaptive Gaussian quadrature
+      fixed_quad - fixed-order Gaussian quadrature
+      dblquad, tplquad - double and triple integrals
+      romb, simps, trapz - integrators for sampled data
+      cumtrapz - cumulative integration for sampled data
+      ode, odeint - ODE integrators
     """
     if isinf(a) or isinf(b):
         raise ValueError("Romberg integration only available for finite limits.")

Modified: trunk/Lib/interpolate/fitpack.py
===================================================================
--- trunk/Lib/interpolate/fitpack.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/interpolate/fitpack.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -1,8 +1,8 @@
 #!/usr/bin/env python
 """
 fitpack (dierckx in netlib) --- A Python-C wrapper to FITPACK (by P. Dierckx).
-        FITPACK is a collection of FORTRAN programs for CURVE and SURFACE
-        FITTING with SPLINES and TENSOR PRODUCT SPLINES.
+        FITPACK is a collection of FORTRAN programs for curve and surface
+        fitting with splines and tensor product splines.
 
 See
  http://www.cs.kuleuven.ac.be/cwis/research/nalag/research/topics/fitpack.html
@@ -28,8 +28,8 @@
     For bivariate splines: profil, regrid, parsur, surev
 """
 
-__all__ = ['splrep', 'splprep', 'splev', 'splint', 'sproot',
-                         'spalde', 'bisplrep', 'bisplev']
+__all__ = ['splrep', 'splprep', 'splev', 'splint', 'sproot', 'spalde',
+    'bisplrep', 'bisplev']
 __version__ = "$Revision$"[10:-1]
 import _fitpack
 from numpy import atleast_1d, array, ones, zeros, sqrt, ravel, transpose, \
@@ -166,6 +166,12 @@
     Remarks:
 
       SEE splev for evaluation of the spline and its derivatives.
+
+    See also:
+      splrep, splev, sproot, spalde, splint - evaluation, roots, integral
+      bisplrep, bisplev - bivariate splines
+      UnivariateSpline, BivariateSpline - an alternative wrapping 
+              of the FITPACK functions
     """
     if task<=0:
         _parcur_cache = {'t': array([],float), 'wrk': array([],float),
@@ -319,6 +325,11 @@
       y2 = splev(x2, tck)
       plot(x, y, 'o', x2, y2)
       
+    See also:
+      splprep, splev, sproot, spalde, splint - evaluation, roots, integral
+      bisplrep, bisplev - bivariate splines
+      UnivariateSpline, BivariateSpline - an alternative wrapping 
+              of the FITPACK functions
     """
     if task<=0:
         _curfit_cache = {}
@@ -414,6 +425,12 @@
       y -- an array of values representing the spline function or curve.
            If tck was returned from splrep, then this is a list of arrays
            representing the curve in N-dimensional space.
+
+    See also:
+      splprep, splrep, sproot, spalde, splint - evaluation, roots, integral
+      bisplrep, bisplev - bivariate splines
+      UnivariateSpline, BivariateSpline - an alternative wrapping 
+              of the FITPACK functions
     """
     t,c,k=tck
     try:
@@ -449,6 +466,12 @@
       wrk -- An array containing the integrals of the normalized B-splines defined
              on the set of knots.
 
+
+    See also:
+      splprep, splrep, sproot, spalde, splev - evaluation, roots, integral
+      bisplrep, bisplev - bivariate splines
+      UnivariateSpline, BivariateSpline - an alternative wrapping 
+              of the FITPACK functions
     """
     t,c,k=tck
     try: c[0][0];return _ntlist(map(lambda c,a=a,b=b,t=t,k=k:splint(a,b,[t,c,k]),c))
@@ -475,6 +498,12 @@
     Outputs: (zeros, )
 
       zeros -- An array giving the roots of the spline.
+
+    See also:
+      splprep, splrep, splint, spalde, splev - evaluation, roots, integral
+      bisplrep, bisplev - bivariate splines
+      UnivariateSpline, BivariateSpline - an alternative wrapping 
+              of the FITPACK functions
     """
     t,c,k=tck
     if k==4: t=t[1:-1]
@@ -510,6 +539,12 @@
 
       results -- An array (or a list of arrays) containing all derivatives
                  up to order k inclusive for each point x.
+
+    See also:
+      splprep, splrep, splint, sproot, splev - evaluation, roots, integral
+      bisplrep, bisplev - bivariate splines
+      UnivariateSpline, BivariateSpline - an alternative wrapping 
+              of the FITPACK functions
     """
     t,c,k=tck
     try:
@@ -588,6 +623,11 @@
 
       SEE bisplev to evaluate the value of the B-spline given its tck
       representation.
+
+    See also:
+      splprep, splrep, splint, sproot, splev - evaluation, roots, integral
+      UnivariateSpline, BivariateSpline - an alternative wrapping 
+              of the FITPACK functions
     """
     x,y,z=map(myasarray,[x,y,z])
     x,y,z=map(ravel,[x,y,z])  # ensure 1-d arrays.
@@ -686,6 +726,15 @@
 
       vals -- The B-pline or its derivative evaluated over the set formed by
               the cross-product of x and y.
+
+    Remarks:
+
+      SEE bisprep to generate the tck representation.
+
+    See also:
+      splprep, splrep, splint, sproot, splev - evaluation, roots, integral
+      UnivariateSpline, BivariateSpline - an alternative wrapping 
+              of the FITPACK functions
     """
     tx,ty,c,kx,ky=tck
     if not (0<=dx<kx): raise ValueError,"0<=dx=%d<kx=%d must hold"%(dx,kx)

Modified: trunk/Lib/interpolate/fitpack2.py
===================================================================
--- trunk/Lib/interpolate/fitpack2.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/interpolate/fitpack2.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -53,6 +53,13 @@
     """ Univariate spline s(x) of degree k on the interval
     [xb,xe] calculated from a given set of data points
     (x,y).
+
+    Can include least-squares fitting.
+
+    See also:
+
+    splrep, splev, sproot, spint, spalde - an older wrapping of FITPACK
+    BivariateSpline - a similar class for bivariate spline interpolation
     """
 
     def __init__(self, x, y, w=None, bbox = [None]*2, k=3, s=None):
@@ -195,7 +202,8 @@
         raise NotImplementedError,'finding roots unsupported for non-cubic splines'
 
 class InterpolatedUnivariateSpline(UnivariateSpline):
-    """ Interpolated univariate spline approximation."""
+    """ Interpolated univariate spline approximation. Identical to UnivariateSpline with less error checking."""
+
     def __init__(self, x, y, w=None, bbox = [None]*2, k=3):
         """
         Input:
@@ -215,7 +223,7 @@
         self._reset_class()
 
 class LSQUnivariateSpline(UnivariateSpline):
-    """ Weighted least-squares univariate spline approximation."""
+    """ Weighted least-squares univariate spline approximation. Appears to be identical to UnivariateSpline with more error checking."""
 
     def __init__(self, x, y, t, w=None, bbox = [None]*2, k=3):
         """
@@ -296,6 +304,15 @@
     """ Bivariate spline s(x,y) of degrees kx and ky on the rectangle
     [xb,xe] x [yb, ye] calculated from a given set of data points
     (x,y,z).
+
+    See also:
+
+    bisplrep, bisplev - an older wrapping of FITPACK
+    UnivariateSpline - a similar class for univariate spline interpolation
+    SmoothUnivariateSpline - to create a BivariateSpline through the 
+                             given points
+    LSQUnivariateSpline - to create a BivariateSpline using weighted
+                          least-squares fitting
     """
 
     def get_residual(self):
@@ -324,8 +341,16 @@
         raise NotImplementedError
 
 class SmoothBivariateSpline(BivariateSpline):
-    """ Smooth bivariate spline approximation."""
+    """ Smooth bivariate spline approximation.
 
+    See also:
+
+    bisplrep, bisplev - an older wrapping of FITPACK
+    UnivariateSpline - a similar class for univariate spline interpolation
+    LSQUnivariateSpline - to create a BivariateSpline using weighted
+                          least-squares fitting
+    """
+
     def __init__(self, x, y, z, w=None,
                  bbox = [None]*4, kx=3, ky=3, s=None, eps=None):
         """
@@ -364,7 +389,14 @@
 
 class LSQBivariateSpline(BivariateSpline):
     """ Weighted least-squares spline approximation.
+    See also:
+
+    bisplrep, bisplev - an older wrapping of FITPACK
+    UnivariateSpline - a similar class for univariate spline interpolation
+    SmoothUnivariateSpline - to create a BivariateSpline through the 
+                             given points
     """
+
     def __init__(self, x, y, z, tx, ty, w=None,
                  bbox = [None]*4,
                  kx=3, ky=3, eps=None):

Modified: trunk/Lib/interpolate/info.py
===================================================================
--- trunk/Lib/interpolate/info.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/interpolate/info.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -13,10 +13,23 @@
   bisplrep   -- find bivariate smoothing spline representation.
   bisplev   -- evaluate bivariate smoothing spline.
 
+  UnivariateSpline             -- A more recent, object-oriented wrapper;
+                                  finds a (possibly smoothed) interpolating
+				  spline.
+  InterpolatedUnivariateSpline
+  LSQUnivariateSpline
+  BivariateSpline              -- A more recent, object-oriented wrapper;
+                                  finds a interpolating spline for a 
+				  bivariate function.
+
+  SmoothBivariateSpline
+
 Interpolation Class
 
   interp1d -- Create a class whose instances can linearly interpolate
-               to compute unknown values.
+               to compute unknown values of a univariate function.
+  interp2d -- Create a class whose instances can interpolate
+               to compute unknown values of a bivariate function.
 """
 
 postpone_import = 1

Modified: trunk/Lib/optimize/anneal.py
===================================================================
--- trunk/Lib/optimize/anneal.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/optimize/anneal.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -181,6 +181,26 @@
     feval -- Number of function evaluations
     iters  -- Number of cooling iterations
     accept -- Number of tests accepted.
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
     """
     x0 = asarray(x0)
     lower = asarray(lower)

Modified: trunk/Lib/optimize/cobyla.py
===================================================================
--- trunk/Lib/optimize/cobyla.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/optimize/cobyla.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -45,6 +45,25 @@
 
     x -- the minimum
 
+    See also:
+
+	fmin, fmin_powell, fmin_cg, 
+	      fmin_bfgs, fmin_ncg -- multivariate local optimizers
+	leastsq -- nonlinear least squares minimizer
+
+	fmin_l_bfgs_b, fmin_tnc, 
+	      fmin_cobyla -- constrained multivariate optimizers
+
+	anneal, brute -- global optimizers
+
+	fminbound, brent, golden, bracket -- local scalar minimizers
+
+	fsolve -- n-dimenstional root-finding
+
+	brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+	fixed_point -- scalar fixed-point finder
+
     """
     err = "cons must be a sequence of callable functions or a single"\
               " callable function."

Modified: trunk/Lib/optimize/lbfgsb.py
===================================================================
--- trunk/Lib/optimize/lbfgsb.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/optimize/lbfgsb.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -117,6 +117,26 @@
      * C. Zhu, R. H. Byrd and J. Nocedal. L-BFGS-B: Algorithm 778: L-BFGS-B,
        FORTRAN routines for large scale bound constrained optimization (1997),
        ACM Transactions on Mathematical Software, Vol 23, Num. 4, pp. 550 - 560.
+
+    See also:
+
+        fmin, fmin_powell, fmin_cg,
+               fmin_bfgs, fmin_ncg -- multivariate local optimizers
+        leastsq -- nonlinear least squares minimizer
+
+        fmin_l_bfgs_b, fmin_tnc,
+               fmin_cobyla -- constrained multivariate optimizers
+
+        anneal, brute -- global optimizers
+
+        fminbound, brent, golden, bracket -- local scalar minimizers
+
+        fsolve -- n-dimenstional root-finding
+
+        brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+        fixed_point -- scalar fixed-point finder
+
     """
     n = len(x0)
 

Modified: trunk/Lib/optimize/minpack.py
===================================================================
--- trunk/Lib/optimize/minpack.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/optimize/minpack.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -86,6 +86,25 @@
 
     "fsolve" is a wrapper around MINPACK's hybrd and hybrj algorithms.
 
+  See also:
+
+      fmin, fmin_powell, fmin_cg,
+	     fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+  
+      fmin_l_bfgs_b, fmin_tnc,
+	     fmin_cobyla -- constrained multivariate optimizers
+  
+      anneal, brute -- global optimizers
+  
+      fminbound, brent, golden, bracket -- local scalar minimizers
+  
+      fsolve -- n-dimenstional root-finding
+  
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+  
+      fixed_point -- scalar fixed-point finder
+
     """
     x0 = atleast_1d(x0)
     n = len(x0)
@@ -188,8 +207,7 @@
                          magnitude. Column j of p is column ipvt(j)
                          of the identity matrix.
                 'qtf'  : the vector (transpose(q) * fvec).
-    mesg -- a string message giving information about the cause of
-            failure.
+    mesg -- a string message giving information about the cause of failure.
     ier -- an integer flag.  If it is equal to 1 the solution was
            found.  If it is not equal to 1, the solution was not
            found and the following message gives more information.
@@ -218,6 +236,25 @@
 
     "leastsq" is a wrapper around MINPACK's lmdif and lmder algorithms.
 
+  See also:
+
+      fmin, fmin_powell, fmin_cg,
+	     fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+  
+      fmin_l_bfgs_b, fmin_tnc,
+	     fmin_cobyla -- constrained multivariate optimizers
+  
+      anneal, brute -- global optimizers
+  
+      fminbound, brent, golden, bracket -- local scalar minimizers
+  
+      fsolve -- n-dimenstional root-finding
+  
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+  
+      fixed_point -- scalar fixed-point finder
+
     """
     x0 = atleast_1d(x0)
     n = len(x0)
@@ -313,6 +350,26 @@
 
     fprime is the derivative of the function.  If not given, the
     Secant method is used.
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+	     fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+  
+      fmin_l_bfgs_b, fmin_tnc,
+	     fmin_cobyla -- constrained multivariate optimizers
+  
+      anneal, brute -- global optimizers
+  
+      fminbound, brent, golden, bracket -- local scalar minimizers
+  
+      fsolve -- n-dimenstional root-finding
+  
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+  
+      fixed_point -- scalar fixed-point finder
+
     """
 
     if fprime is not None:
@@ -353,6 +410,26 @@
 def fixed_point(func, x0, args=(), xtol=1e-10, maxiter=500):
     """Given a function of one variable and a starting point, find a
     fixed-point of the function: i.e. where func(x)=x.
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+	     fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+  
+      fmin_l_bfgs_b, fmin_tnc,
+	     fmin_cobyla -- constrained multivariate optimizers
+  
+      anneal, brute -- global optimizers
+  
+      fminbound, brent, golden, bracket -- local scalar minimizers
+  
+      fsolve -- n-dimenstional root-finding
+  
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+  
+      fixed_point -- scalar fixed-point finder
+
     """
 
     p0 = x0
@@ -374,6 +451,26 @@
 def bisection(func, a, b, args=(), xtol=1e-10, maxiter=400):
     """Bisection root-finding method.  Given a function and an interval with
     func(a) * func(b) < 0, find the root between a and b.
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+	     fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+  
+      fmin_l_bfgs_b, fmin_tnc,
+	     fmin_cobyla -- constrained multivariate optimizers
+  
+      anneal, brute -- global optimizers
+  
+      fminbound, brent, golden, bracket -- local scalar minimizers
+  
+      fsolve -- n-dimenstional root-finding
+  
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+  
+      fixed_point -- scalar fixed-point finder
+
     """
     i = 1
     eva = func(a,*args)

Modified: trunk/Lib/optimize/optimize.py
===================================================================
--- trunk/Lib/optimize/optimize.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/optimize/optimize.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -134,6 +134,25 @@
       disp -- non-zero to print convergence messages.
       retall -- non-zero to return list of solutions at each iteration
 
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
       """
     fcalls, func = wrap_function(func, args)
     x0 = asfarray(x0)
@@ -613,6 +632,26 @@
                      and warnflag in addition to xopt.
       disp -- print convergence message if non-zero.
       retall -- return a list of results at each iteration if non-zero
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
       """
     x0 = asarray(x0)
     if maxiter is None:
@@ -757,6 +796,26 @@
                      and warnflag in addition to xopt.
       disp -- print convergence message if non-zero.
       retall -- return a list of results at each iteration if True
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
       """
     x0 = asarray(x0)
     if maxiter is None:
@@ -906,6 +965,25 @@
     provided, then the hessian product will be approximated using finite
     differences on fprime.
 
+  See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
     """
     x0 = asarray(x0)
     fcalls, f = wrap_function(f, args)
@@ -1043,6 +1121,26 @@
       ierr -- An error flag (0 if converged, 1 if maximum number of
               function calls reached).
       numfunc -- The number of function calls.
+
+  See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
     """
 
     if x1 > x2:
@@ -1169,6 +1267,26 @@
     Uses inverse parabolic interpolation when possible to speed up convergence
     of golden section method.
 
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
     """
     _mintol = 1.0e-11
     _cg = 0.3819660
@@ -1267,6 +1385,26 @@
     (see bracket)
 
     Uses analog of bisection method to decrease the bracketed interval.
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
     """
     if brack is None:
         xa,xb,xc,fa,fb,fc,funcalls = bracket(func, args=args)
@@ -1433,6 +1571,25 @@
       disp -- non-zero to print convergence messages.
       retall -- non-zero to return a list of the solution at each iteration
 
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
       """
     # we need to use a mutable object here that we can update in the
     # wrapper function
@@ -1557,6 +1714,26 @@
     grid        -- tuple with same length as x0 representing the
                     evaluation grid
     Jout        -- Function values over grid:  Jout = func(*grid)
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
     """
     N = len(ranges)
     if N > 40:

Modified: trunk/Lib/optimize/tnc.py
===================================================================
--- trunk/Lib/optimize/tnc.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/optimize/tnc.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -54,6 +54,7 @@
 }
 
 HUGE_VAL=1e500 # No standard representation of Infinity in Python 2.3.3
+               # FIXME: can we use inf now that we have numpy and IEEE floats?
 
 EINVAL       = -2 # Invalid parameters (n<1)
 INFEASIBLE   = -1 # Infeasible (low > up)
@@ -149,6 +150,26 @@
         x         : the solution (a list of floats)
         nfeval    : the number of function evaluations
         rc        : return code (corresponding message in optimize.tnc.RCSTRINGS)
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
     """
 
     n = len(x0)

Modified: trunk/Lib/optimize/zeros.py
===================================================================
--- trunk/Lib/optimize/zeros.py	2006-09-23 11:47:47 UTC (rev 2218)
+++ trunk/Lib/optimize/zeros.py	2006-09-23 21:56:21 UTC (rev 2219)
@@ -70,6 +70,26 @@
     is the root, and r is a RootResults object containing information
     about the convergence. In particular, r.converged is True if the
     the routine converged.
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
     """
     if type(args) != type(()) :
         args = (args,)
@@ -113,6 +133,26 @@
     is the root, and r is a RootResults object containing information
     about the convergence. In particular, r.converged is True if the
     the routine converged.
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
     """
     if type(args) != type(()) :
         args = (args,)
@@ -157,6 +197,26 @@
     is the root, and r is a RootResults object containing information
     about the convergence. In particular, r.converged is True if the
     the routine converged.
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
     """
     if type(args) != type(()) :
         args = (args,)
@@ -201,6 +261,26 @@
     is the root, and r is a RootResults object containing information
     about the convergence. In particular, r.converged is True if the
     the routine converged.
+
+    See also:
+
+      fmin, fmin_powell, fmin_cg,
+             fmin_bfgs, fmin_ncg -- multivariate local optimizers
+      leastsq -- nonlinear least squares minimizer
+
+      fmin_l_bfgs_b, fmin_tnc,
+             fmin_cobyla -- constrained multivariate optimizers
+
+      anneal, brute -- global optimizers
+
+      fminbound, brent, golden, bracket -- local scalar minimizers
+
+      fsolve -- n-dimenstional root-finding
+
+      brentq, brenth, ridder, bisect, newton -- one-dimensional root-finding
+
+      fixed_point -- scalar fixed-point finder
+
     """
     if type(args) != type(()) :
         args = (args,)




More information about the Scipy-svn mailing list