#include <SigProc/SigProcNoise.h>
List of all members.
Static Protected Member Functions |
static double | DRanNormalTail (double dMin, int iNegative) |
Detailed Description
The tcSigProcNoise class provides utility methods for generating noise functions.
- See also:
- tcSigProcNoise Page
Member Function Documentation
float tcSigProcNoise::Gaussian |
( |
void |
| ) |
|
|
static |
This routine will generate a gaussian distributed number with standard deviation equal to 1.0 and mean of zero using the Box-Muller method.
- Warning:
- this method is not thread safe.
- Return values:
-
a | Gaussian random number with mean 0 and std=1.0 |
- Note:
- this function taken from Numerical Recipes in C, chapter 7.2
float tcSigProcNoise::Uniform |
( |
void |
| ) |
|
|
static |
This routine will generate a uniform distributed number from 0.0-1.0 exclusive of the endpoints (0.0 and 1.0 will not be returned).
- Return values:
-
a | uniform number between 0.0 and 1.0 (exclusive) |
void tcSigProcNoise::Seed |
( |
int |
seed = -1 | ) |
|
|
static |
This routine will seed the base random number generater provided by the BIOS.
- Parameters:
-
seed | if less than zero, the system local tick timer is used. |
void tcSigProcNoise::zigNorInit |
( |
void |
| ) |
|
|
static |
double tcSigProcNoise::DRanNormalZig |
( |
void |
| ) |
|
|
static |
Compute a gaussian random number for std = 1.0 and mean = 0.0 using the Ziggurat algorithm. Note: zigNorInit() must be called prior to using this routine the first time.
- Returns:
- gaussian randome number
double tcSigProcNoise::DRanNormalTail |
( |
double |
dMin, |
|
|
int |
iNegative |
|
) |
| |
|
staticprotected |
This method is used exclusively by DRanNormalZig.
- Parameters:
-
dMin | minimum point on curve |
iNegative | 0 if positive side of curve, non-zero otherwise |
- Returns:
- gaussian number on the tail of the PDF curve
Member Data Documentation
bool tcSigProcNoise::mbSeeded = false |
|
staticprotected |
when true, srand() has been called
double tcSigProcNoise::m_adZigX |
|
staticprotected |
m_adZigX holds coordinates, such that each rectangle has same area; m_adZigR holds m_adZigX[i + 1] / m_adZigX[i]
double tcSigProcNoise::m_adZigR |
|
staticprotected |