This is the mail archive of the gsl-discuss@sources.redhat.com mailing list for the GSL project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: simplex minimization


On  1 Jan, Tim F wrote:
> On Wed, 1 Jan 2003, Brian Gough wrote:
> 
>>
>> Yes please send an example.  Thanks.
>> 
> 
> I hope this example isn't too terse... let me know if other information 
> will help.
> 
> 	Tim F
......deletion
> 
>   // set up solver
>   T = gsl_multimin_fminimizer_nmsimplex;
>   s = gsl_multimin_fminimizer_alloc(T, p);
>   ss = gsl_vector_alloc(p);
>   gsl_multimin_fminimizer_set(s, &f, &param.vector, ss);
> 
you did not initialize ss! ss should be initialized by a reasonable step
size for each of the parameters. this is needed to calculate n more
corners (n parameters) for the initial simplex. the elements of ss seem
to be all zero thus the initial size of the simplex is zero as well and
the minimizer stop right away
-- 
Dr. Ivo Alxneit
Laboratory for Solar Technology   phone: +41 56 310 4092
CH-5232 Villigen                    fax: +41 56 310 2624
Paul Scherrer Institute          http://solar.web.psi.ch
Switzerland                        gnupg key: 0x515E30C7

Attachment: msg00011/pgp00000.pgp
Description: PGP signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]