How to compute a gaussian random noise with Matlab R2010a ?

How to compute a gaussian random noise with Matlab R2010a ? I saw "normrnd" for Matlab 2013 but it des not exist in Matlab 2010. Another solution?

댓글 수: 2

What does "compute" mean?
I mean, I want to add noise to simulated data, hence I need to create a vector of length N with gaussianly-distributed data.

댓글을 달려면 로그인하십시오.

 채택된 답변

Iain
Iain 2013년 5월 30일

0 개 추천

If you mean generate random numbers in a gaussian distribution, whats wrong with randn()?

추가 답변 (2개)

Adrien
Adrien 2013년 5월 30일

0 개 추천

As far as a see randn() is centered around 0.5 (this is not a pproblem) but is limited between 0 and 1, isn't it: it never gives any negative or >1 numbers, hence randn() seems to be a "truncated gaussian". I would like a "non-truncated" one if it exists.

댓글 수: 1

You're looking at rand, which is top hat 0 to 1. randn is gaussian, with mean 0 and sigma of 1.

댓글을 달려면 로그인하십시오.

Adrien
Adrien 2013년 5월 30일

0 개 추천

Mea culpa I had written "rand" instead of "randn" (even if I had read "randn"), so thanks the problem seems to be solved ;)

카테고리

도움말 센터File Exchange에서 Creating and Concatenating Matrices에 대해 자세히 알아보기

태그

질문:

2013년 5월 30일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by