I am trying to generate some narrow band noise. I have so far used
the rand object to generate white noise but am now unsure as to how
to go on from there. I eventually want to have a sample of sound to
use.
You might consider using the WGN or AWGN functions to generate your white
noise signals. For more info, type:
doc wgn
OR
doc awgn
at the command prompt.
Once you have your white noise signal, try passing it through a low-pass
filter to create narrowband noise.
"Matt Joseph" <still_feel_alive@yahoo.co.uk> wrote in message
news:ef5ca3f.-1@webcrossing.raydaftYaTP...
>I am trying to generate some narrow band noise. I have so far used
> the rand object to generate white noise but am now unsure as to how
> to go on from there. I eventually want to have a sample of sound to
> use.
>
> Thanks Matt
I don't seem to get any info when typing
doc wgn or doc awgn
Do you have to have a specific version of Matlab for this?
Matt
Rick Rosson wrote:
>
>
> You might consider using the WGN or AWGN functions to generate your
> white
> noise signals. For more info, type:
>
> doc wgn
>
> OR
>
> doc awgn
>
> at the command prompt.
>
> Once you have your white noise signal, try passing it through a
> low-pass
> filter to create narrowband noise.
>
>
>
>
> "Matt Joseph" <still_feel_alive@yahoo.co.uk> wrote in message
> news:ef5ca3f.-1@webcrossing.raydaftYaTP...
>>I am trying to generate some narrow band noise. I have so far
used
>> the rand object to generate white noise but am now unsure as to
> how
>> to go on from there. I eventually want to have a sample of
sound
> to
>> use.
>>
>> Thanks Matt
>
>
>
The function RANDN will generate a sequence of normally-distributed random
numbers, with mean 0 and variance 1. Try the following code:
% Parameters:
N = 2048; % Number of data points
mu = 0; % mean
sigma = 3; % standard deviation
% White gaussian noise sequence:
x = mu + sigma*randn(1,N);
% Autocorrelation:
R = xcorr(x);
plot(R);
This code will generate a WGN sequence with 2048 elements with mean 0 and
standard deviation 3, and then compute and plot the autocrrelation function.
Rick
"Matt Joseph" <still_feel_alive@yahoo.co.uk> wrote in message
news:ef5ca3f.3@webcrossing.raydaftYaTP...
>I do not have this toolbox installed and as it is not my Matlab I
> cannot install this...any one got any other ideas about how to tackle
> this problem?
>
> Matt
>
> Us wrote:
>
>> they are part of the <communications tbx>...
>>
>> us
Rick Rosson wrote:
> You might consider using the WGN or AWGN functions to generate your white
> noise signals. For more info, type:
>
> doc wgn
>
> OR
>
> doc awgn
>
> at the command prompt.
>
> Once you have your white noise signal, try passing it through a low-pass
> filter to create narrowband noise.
What's wrong with simply rand() passed through a band-pass filter?
That works too. The function RAND, however, generates a uniform
distribution, whereas RANDN generates a normal distrubution.
>
> <Steve.Amphlett@ricardo.com> wrote:
>
> What's wrong with simply rand() passed through a band-pass filter?
>
>>
>> Rick Rosson wrote:
>>
>> You might consider using the WGN or AWGN functions to generate your white
>> noise signals. For more info, type:
>>
>> doc wgn
>>
>> OR
>>
>> doc awgn
>>
>> at the command prompt.
>>
>> Once you have your white noise signal, try passing it through a low-pass
>> filter to create narrowband noise.
Public Submission Policy
NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for
all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content.
Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available
via MATLAB Central. Read the complete Disclaimer prior to use.