regarding random number generation in matlab

Status
Not open for further replies.

singhji0000

Junior Member level 3
Joined
Apr 1, 2011
Messages
27
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,464
i wanted to use normrnd(mu,sigma,m,n) in order to generate random numbers from normal distribution with mean mu =0 and some standard deviation say sigma. this sigma will be used to study the effect of Kt/C noise but my matlab doesnt support statistical toolbox.

Another possibilty i look is to use randn(m,n) which has mean =0 and standard deviation equal to 1 and this is normal matlab functionality.

Please tell me how i can use randn function with some standard devation value = sigma (say) instead of 1??

thanks in advance
 

You want mean mu and standard deviation sigma. Make like this (with appropriate m and n):

randn(m,n) * sigma + mu;

Regards

Z
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…