The present code is a Matlab function that provides a generation of noise signal with arbitrary amplitude spectral slope f^a. For instance:
1) White noise: a = 0;
2) Pink (flicker) noise: a = −1/2;
3) Red (Brown(ian)) noise: a = −1;
4) Blue noise: a = +1/2;
5) Violet (Purple) noise: a = +1.
An example is given in order to clarify the usage of the function. For convenience, the input and output arguments are given in the beginning of the function. The generated noise signal has unity standard deviation and zero mean value.
The code is based on the theory described in:
 H. Zhivomirov. A Method for Colored Noise Generation. Romanian Journal of Acoustics and Vibration, ISSN: 1584-7284, Vol. XV, No. 1, pp. 14-19, 2018. (http://rjav.sra.ro/index.php/rjav/article/view/40/29)
H. Zhivomirov. A Method for Colored Noise Generation. Romanian Journal of Acoustics and Vibration, ISSN: 1584-7284, Vol. XV, No. 1, pp. 14-19, 2018. (http://rjav.sra.ro/index.php/rjav/article/view/40/29)
Hristo Zhivomirov (2020). Arbitrary Spectral Slope Noise Generation with Matlab (https://www.mathworks.com/matlabcentral/fileexchange/48628-arbitrary-spectral-slope-noise-generation-with-matlab), MATLAB Central File Exchange. Retrieved .
A colored noise (or power-law noise) is any stochastic signal with a power spectral density (PSD) per unit of bandwidth (e.g., measured in Hz) proportional to the frequency by factor f^a. For instance, for a = 0 the PSD is flat (slope = 0 dB/decade), and the noise is termed as white. For a = - 1 the PSD falls off at a rate of -10 dB/decade, and the noise is termed as pink. If you want to read my paper, please write me an e-mail and I will send it to you, although the link is absolutely active.
I saw a comment like this "amplitudes is proportional to the frequency by factor f^a". Will you please explain it. in addition, cited paper is not available;
Perfect ... just what I wanted. Thank you!
A new reference literature has been added.
A new version of the code has been uploaded.