Stock Market Cycles

Stock Market Cycles

Share this post

Stock Market Cycles
Stock Market Cycles
Goertzel Fourier Transform (DFT) Source Code
Copy link
Facebook
Email
Notes
More
Code, Scripts & Indicators

Goertzel Fourier Transform (DFT) Source Code

Cycle detection using discrete Goertzel Fourier transform (+ Video)

Lars von Thienen's avatar
Lars von Thienen
Nov 13, 2023
∙ Paid
1

Share this post

Stock Market Cycles
Stock Market Cycles
Goertzel Fourier Transform (DFT) Source Code
Copy link
Facebook
Email
Notes
More
Share

This article provides source code for the Goertzel algorithm to compute individual terms of the discrete Fourier transform. The first form provides the standard Goertzel loop. The second form provides a generalized version for the case of non-integer frequency values.

The Goertzel algorithm provides a flexible and improved way to apply cycle analysis to time series datasets. Please watch my cycles course for benefits and background using standard FFT, Goertzel and generalized Goertzel algorithms:

Show Video Course

Further reading & references:
» Reference to Goertzel algorithm: Wikipedia on Goertzel

» Sysel, P., Rajmic, P. Goertzel algorithm generalized to non-integer multiples of fundamental frequency. EURASIP J. Adv. Signal Process. 2012, 56 (2012). https://doi.org/10.1186/1687-6180-2012-56

Source code section

Code is provided in .NET C# language.

Keep reading with a 7-day free trial

Subscribe to Stock Market Cycles to keep reading this post and get 7 days of free access to the full post archives.

Already a paid subscriber? Sign in
© 2025 Lars von Thienen
Privacy ∙ Terms ∙ Collection notice
Start writingGet the app
Substack is the home for great culture

Share

Copy link
Facebook
Email
Notes
More