public class BrownNoiseGenerator extends Object
Constructor and Description |
---|
BrownNoiseGenerator()
Creates a brown noise generator with an output range of -1 to +1.
|
BrownNoiseGenerator(double minValue,
double maxValue)
Creates a brown noise generator with a specified output value range.
|
BrownNoiseGenerator(double minValue,
double maxValue,
double slope,
double hpFilter)
Creates a brown noise generator.
|
Modifier and Type | Method and Description |
---|---|
double |
getNext()
Returns the next output value of the noise generator.
|
public BrownNoiseGenerator()
public BrownNoiseGenerator(double minValue, double maxValue)
minValue
- Minimum output value.maxValue
- Maximum output value.public BrownNoiseGenerator(double minValue, double maxValue, double slope, double hpFilter)
minValue
- Minimum output value.maxValue
- Maximum output value.slope
- Maximum slope of the output signal.
This parameter defines the maximum difference between two consecutive output values.
It controls the amplitude of the output signal spectrum.
A reasonable value is (maxValue - minValue) / 20
.hpFilter
- High pass filter factor.
A simple first-order high pass filter is used to reduce DC drift of the output signal
and avoid frequent clipping.
A reasonable value is 0.02.
If this parameter is zero, the high pass filter is disabled.