Numerical solution of stochastic differential equations using a variable time step
This is a source code for the numerical solution of nonlinear stochastic differential equations generating signals with 1/f noise. The equtions are described in Refs. [1-2]. The code can be adapted to solve various equations of this type.
The particular case of the equation with the known analytical expression for the power spectral density and the method of solution are described by the files in the directiory equations.
Before calculations the program 'spectrum' reads a FFTW plan from a file in the current directory with the name 'wisdom'. The wisdom file can be generated with the program 'makewisdom'
The program 'spectrum' outputs the sample signal into the file 'signal.dat', the steady-state probability distribution of the signal into the file 'distribution.dat' and the power spectral density into the file 'spectrum.dat'