comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Random number generation
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Random number generation [message #92674 is a reply to message #92667] Thu, 04 February 2016 12:04 Go to previous message
Craig Markwardt is currently offline  Craig Markwardt
Messages: 1869
Registered: November 1996
Senior Member
On Thursday, February 4, 2016 at 7:39:21 AM UTC-5, dave poreh wrote:
> On Thursday, February 4, 2016 at 4:08:07 AM UTC+3:30, Craig Markwardt wrote:
>> On Wednesday, February 3, 2016 at 11:51:13 AM UTC-5, dave poreh wrote:
>>> Folks,
>>> Hi,
>>> I am working on some simulation problems, that I need to generate random numbers. When I use>
>>> print, mean(randomu(seed, 100000))
>>> 0.498516
>>> print, mean(randomn(seed, 100000))
>>> 0.00100909
>>> 1-the randomn is much better than randomu. why is that?
>>> 2-I am expecting very small number for mean of this random numbers, but as you see they are quite big (i am expecting in order of 10e-7).
>>> Is there any other way that i can use?
>>> Thanks for anykind of helps...
>>> Cheers,
>>> Dave
>>
>> What kind of random numbers do you need? There are many kinds of random number distributions.
>>
>> Alx is right, the average of a random sample will have some variance from the true average. They would not be random otherwise!
>
> Hi Guys,
> I am using Fortran for a radar data simulation...
> The problem is: mean of these random numbers is increasing during the run (with changing of parameters), so the order of mean with different run is different. And that made me a problem...
> BUT anyhow Alx is right, this is the nature of randomness...


But you have to know what kind of random number distribution is required! RANDOMU() produces uniform deviates. RANDOMN() produces gaussian deviates. They are completely different.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: IDLWAVE Maintainer Wanted
Next Topic: exelisvis.com is now harrisgeospatial.com

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 15:55:48 PDT 2025

Total time taken to generate the page: 0.00214 seconds