trying to make a random number sequence similar to an MLS sequence
3 次查看(过去 30 天)
显示 更早的评论
I'm trying to create a random number sequence like this one: -
x = 2*rand(N,1)-1; % generate input noise signal
except instead of the numbers being at all different values between -1 and 1, I'd like them to be either -1 or 1 only.
Does anyone know how I might do this?
2 个评论
Daniel Shub
2012-4-4
This is nothing like an MLS sequence. What you are looking for is often called Bernoulli noise.
Matt Fig
2012-11-2
Tom's question
I'm trying to create a random number sequence like this one: -
x = 2*rand(N,1)-1; % generate input noise signal
except instead of the numbers being at all different values between -1 and 1, I'd like them to be either -1 or 1 only.
Does anyone know how I might do this?
采纳的回答
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Measurements and Spatial Audio 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!