[scilab-Users] Nelder-Mead optimization

paul.carrico at free.fr paul.carrico at free.fr
Mon Jul 16 19:25:39 CEST 2012


sorry for the request ... but it seems that some changes have been made in my solver as well ...

Paul

----- Mail original -----
De: "Paul Carrico" <paul.carrico at esterline.com>
À: users at lists.scilab.org
Envoyé: Lundi 16 Juillet 2012 16:22:52
Objet: [scilab-Users] Nelder-Mead optimization


Dear All, 

I would like to re-use an routine written more than a year ago ... but it failed ; 

I can understand thinks have been done in order to improve the function, but : 
- I don't remember what's optimbase_configure ... 
- what's wrong ? 

Any advice ? 

Regards 

Paul 




The main routine is something like : 
// 8 parameters lower_bounds = [ 0.22 2.337 18.72 14.859 19.05 14.5 1.85 0. ] ; upper_bounds = [ 0.28 2.388 18.771 15.0119 19.075 14.6 1.95 0.68 ] ; data = list ( lower_bounds , upper_bounds ) ; printf ( " \n  The initial parameters are the following :\n " ) ; thickness = 0.28 ; height = 2.380 ; D_ext = 18.771 ; D_int = 14.859 ; groove_ext_radius = 19.075 ; groove_int_radius = 14.50 ; housing_deepth = 1.85 ; COEF_FRICTION = 0.4 ; initial_parameters = [ thickness height D_ext D_int groove_ext_radius groove_int_radius housing_deepth COEF_FRICTION ] ; // CPU time : start time_start = tic ( ) ; // Nelder-mead optimization nm = neldermead_new ( ) ; nm = neldermead_configure ( nm , " -numberofvariables " , 8 ) ; // Number of variables nm = neldermead_configure ( nm , " -function " , optimization_nm ) ; nm = neldermead_configure ( nm , " -x0 " , initial_parameters ' ) ; // BE CAREFUL : nitial_parameters ' = transposed matrix nm = neldermead_configure ( nm , " -method " , " box " ) ; // box = > brackets are taken into account nm = neldermead_configure ( nm , " -maxiter " , 10000 ) ; nm = neldermead_configure ( nm , " -boundsmin " , lower_bounds ) ; nm = neldermead_configure ( nm , " -boundsmax " , upper_bounds ) ; nm = neldermead_configure ( nm , " -costfargument " , data ) ; nm = neldermead_configure ( nm , " -simplex0method " , " randbounds " ) ; [ nm , SSE ] = neldermead_function ( nm , initial_parameters ' ) ; nm = neldermead_search ( nm ) ; // start optimization process optimized_parameters = neldermead_get ( nm , " -xopt " ) ; // extract of the results nm = neldermead_destroy ( nm ) ; The error message is : AVERTISSEMENT : La fonctionnalité optimbase_configure est obsolète. 
AVERTISSEMENT : Veuillez utiliser -function à la place. 
AVERTISSEMENT : Cette fonctionnalité va être définitivement supprimée dans Scilab 5.4.1 ######################################################### 
* Iteration No : 1 
* thickness = 0.28 
* height = 2.38 
* D_ext = 18.771 
* D_int = 14.859 
* groove_ext_radius = 19.075 
* groove_int_radius = 14.5 
* housing_deepth = 1.85 
* COEF_FRICTION = 0.4 
!--error 58 
Nombre erroné d'arguments d'entrée.at line      73 of function __optimbase_f__ called by : 
at line      66 of function optimbase_function called by : 
at line       7 of function neldermead_function called by : 
[nm,SSE] = neldermead_function(nm,initial_parameters'); 
at line      65 of exec file called by : --------------------------------------------------------------------------------


Le présent mail et ses pièces jointes sont confidentiels et destinés à la personne ou aux personnes visée(s) ci-dessus. Si vous avez reçu cet e-mail par erreur, veuillez contacter immédiatement l'expéditeur et effacer le message de votre système. Toute divulgation, copie ou distribution de cet e-mail est strictement interdite.

This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error, please contact the sender and delete the email from your system. If you are not the named addressee you should not disseminate, distribute or copy this email.



More information about the users mailing list