Standard deviation of Matlab 'randn' function

A quick and simple check (using code in MATLAB) shows that the numbers generated by MATLAB's randn function have a standard deviation that is one-fifth of the peak-peak variation.

MATLAB CODE: randn('state',0); rn = randn(100,1); (max(rn)-min(rn))/std(rn)

I have researched, and people have used this rule for practical purposes.

http://terpconnect.umd.edu/~toh/spectrum/SignalsAndNoise.html

http://www.princetonmeasurements.com/whichsys.htm

However, when I generate noise using MATLAB's randn function, and observe it by plotting the numbers, the variation (peak to peak for consecutive values) is 3 times the standard deviation, whereas the above articles use the max and min of the generated random values (which may not be consecutive)

I am not sure what the theory behind this is. (I do know that for Gaussian random variable, the values are within 3 std.)

Thanks!!

• It's not at all clear what you're asking. What's the question? Are you defining "peak-peak variation" as max(rn)-min(rn) for a given sample size? It looks like you're comparing real world noise to ideal Gaussian noise? What's meant by "generate noise"? Is this a noise process or do you just mean the output of randn? How do you calculate "variation (peak to peak for consecutive values)"? Also, unless you have a very old version of Matlab, you should never use randn('state',0)see this article. – horchler Oct 29 '13 at 20:01
• That is what I am confused about. 1. Is the peak-peak variation calculated as max(rn)-min(rn) 2. I mean the output of randn. – AAP Oct 29 '13 at 20:16