Ask Your Question
1

sage.numerical.optimize.minimize_constrained versus fmincon

asked 2011-10-11 06:08:11 -0500

Reinderien gravatar image

Matlab has this function: http://www.mathworks.com/help/toolbox...

And as far as I can tell, Sage's closest equivalent is this: http://www.sagemath.org/doc/reference...

I use the inequality feature of fmincon. I think that the cons lambdas can achieve the same thing, although: will the performance worsen? Since fmincon can run an interior-point method with knowledge of the boundary, will the convergence be better there than with minimize_constrained? Is there some implementation of an interior-point method that I'm not seeing in Sage?

Thanks.

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2011-10-11 15:43:31 -0500

niles gravatar image

When you browse the source, you can see exactly what algorithm is being used--perhaps this can help answer some of your performance questions? For minimize_constrained, Sage calls the multivariate constrained optimization functions from scipy.optimize: either fmin_tnc (truncated Newton's method) or fmin_cobyla (Constrained Optimization BY Linear) or, if requested, fmin_l_bfgs_b (L-BFGS-B algorithm).

If there are any other optimization methods, I would expect them to be in this same source file. Also, you might find some of the other functionality of scipy.optimize useful; in that case, the source here could be a template for how to use it.

edit flag offensive delete link more

Comments

It seems that `scipy.optimize.fmin_slsqp` is a good candidate.

Reinderien gravatar imageReinderien ( 2011-10-12 04:06:28 -0500 )edit

I don't see the SLSQP algorithm in that file. Is there a place where I could request that there be a Sage wrapper added for this function?

Reinderien gravatar imageReinderien ( 2011-10-12 04:08:40 -0500 )edit

It seems that someone is already using this, although I have to read more closely to see how it's done: http://www.sagenb.org/home/pub/1224/

Reinderien gravatar imageReinderien ( 2011-10-12 04:11:44 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

2 followers

Stats

Asked: 2011-10-11 06:08:11 -0500

Seen: 930 times

Last updated: Oct 11 '11