Nils
_______________________________________________
SciPy-user mailing list
SciPy...@scipy.org
http://projects.scipy.org/mailman/listinfo/scipy-user
For lower and upper bounda:
bounds = [(2000.,2100.),(1800.,1850.),(1600.,1630.)]
x_lbl,f,d = optimize.fmin_l_bfgs_b(func1, x0, fprime=None,
args=(), approx_grad=1, bounds=bounds)
scipy/scipy/optimize/lbfgsb
! -*- f90 -*-
python module _lbfgsb ! in
interface ! in :_lbfgsb
subroutine
setulb(n,m,x,l,u,nbd,f,g,factr,pgtol,wa,iwa,task,iprint,csave,lsave,isave,dsave)
! in :lbfsgb:routines.f
integer
intent(in),optional,check(len(x)>=n),depend(x) :: n=len(x)
integer intent(in) :: m
double precision dimension(n),intent(inout)
:: x
double precision
dimension(n),depend(n),intent(in) :: l
double precision
dimension(n),depend(n),intent(in) :: u
integer dimension(n),depend(n),intent(in) ::
nbd
double precision intent(inout) :: f
double precision
dimension(n),depend(n),intent(inout) :: g
double precision intent(in) :: factr
double precision intent(in) :: pgtol
double precision
dimension(2*m*n+4*n+12*m*m+12*m),depend(n,m),intent(inout)
:: wa
integer dimension(3 *
n),depend(n),intent(inout) :: iwa
character*60 intent(inout) :: task
integer intent(in) :: iprint
character*60 intent(inout) :: csave
logical dimension(4),intent(inout) :: lsave
integer dimension(44),intent(inout) :: isave
double precision dimension(29),intent(inout)
:: dsave
end subroutine setulb
end interface
end python module _lbfgsb
Nils
> There is no variable 'wa' in any of my functions, so I
>am not sure why this
> failing.
>
> Also, how do I setup the bounds, I am not clear on how
>to set it. I have a
> list of upper bounds (an array of 3 values) and a list
>of lower bounds Not
> sure how to set them.