help-glpk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-glpk] Random Number seeds


From: Jeffrey Kantor
Subject: Re: [Help-glpk] Random Number seeds
Date: Tue, 8 Dec 2009 15:51:25 -0500

This is very interesting. The use case I had in mind would be to prepare a model, 
then to have a shell script or something exercise that model repeatedly using
random seeds in order to gather performance statistics. That was why I thought
Andrew's idea of putting the seed in the command line made sense. 

I'd be very glad to be able to put solve inside a 'for' statement inside the model,
but that doesn't seem to be in the cards.  

Perhaps we need both, a command line *and* a seed function within the language.

Jeff


On Tue, Dec 8, 2009 at 1:43 PM, Meketon, Marc <address@hidden> wrote:
Ideally you would have the ability to have separate random number
streams, and the ability to set the seeds for these streams in the data
section.

For example, one stream would be for "demand" data, the other stream for
"supply" data.

Having different streams will easily allow the use of "common random
variates" to see the differences between, say, changing the supply but
holding the demand steady.  Common random variates reduce the variance
of the difference between means in the experiments.

Among the benefits of allowing the data set to set the random number
generator is that it provides the ability to document the experiment
better.  All is needed is to use a display or print statement in the
GMPL code to show which seed(s) were used.

If the seed is placed in the command line instead, then the user that
runs the experiments would need to keep track of one more item - what
command line was used - when trying to ensure repeatability.  Placing
the seed within the GMPL code -- especially as a parameter in the data
-- will make it easier to track the experiment.

-Marc

-----Original Message-----
From: help-glpk-bounces+marc.meketon=oliverwyman.com@gnu.org
[mailto:help-glpk-bounces+marc.meketon=oliverwyman.com@gnu.org] On
Behalf Of Andrew Makhorin
Sent: Tuesday, December 08, 2009 10:28 AM
To: Jeffrey Kantor
Cc: address@hidden
Subject: Re: [Help-glpk] Random Number seeds

> It would be nice to have a seed function :=)

I think it would be better to have a seed parameter passed to the
translator rather than the seed statement built into the language.
On the command-line level this could look like 'glpsol --seed 314159'.




_______________________________________________
Help-glpk mailing list
address@hidden
http://lists.gnu.org/mailman/listinfo/help-glpk
----------------------------------------------------------------------------
This e-mail and any attachments may be confidential or legally privileged.  If you received this message in error or are not the intended recipient, you should destroy the e-mail message and any attachments or copies, and you are prohibited from retaining, distributing, disclosing or using any information contained herein.  Please inform us of the erroneous delivery by return e-mail.

Thank you for your cooperation.
----------------------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]