How to implement white noise with a time component?

Hello, I want to try to implement white noise with a duration of 500 seconds and at the time step delta T every 10 ms the a value should be chosen from a gaussian distribution with mean 0 and variance 2.
I implemented it in the following way: n = 50000 %(I changed the seconds to ms and divided this value by 10ms) N = rand(0,2,n,1)
Howevery I am not sure about whether I correclty integrated the time aspect of the 10 ms correctly. I was also thinking about a for loop, but I am sure. Does anyone have further suggestions?
Thanks in advance!

回答 (2 件)

Andrei Bobrov
Andrei Bobrov 2011 年 5 月 14 日

0 投票

as well so? (EDIT)
n = 50000;
N = 0 + sqrt(2)*randn(n,1);
N = normrnd(0,sqrt(2),n,1)
Ann Brain
Ann Brain 2011 年 5 月 14 日

0 投票

Thanks for this reply. I actually used normrnd instead of rand.
However I am not sure if I implemented the delta T component correctly, would you have done it the same way?

カテゴリ

ヘルプ センター および File ExchangeDeep Learning Toolbox についてさらに検索

質問済み:

2011 年 5 月 14 日

Community Treasure Hunt

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

Start Hunting!

Translated by