Symbolic Fourier Transforms for Educational DSP

Hi!

I’m new to Julia and wondering if its the right tool for a educational project.

I would like to make a program that lets the user (a teacher or student) to select and customize some elemental signals that will then be linearly combined to form the signal under study. Customization should include time-shifts, time-dilation/contraction, frequency-shifts and maybe other specific parameters. Amplitude is just the linear combination coefficients.

This resulting signal will be plotted, windowed and filtered. At each stage, the resulting spectra will be shown. Windows and filters also selectable.

Finally, the filtered and windowed signal will be sliced, sampled and the DFT calculated (using FFT). At this stage the goal is to show the differences between the DFT and Fourier transform.

The educational goal is to answers questions like “what can I say about the original continuous signal from its samples?”, “which are the common pitfalls in analysis?”, “how the reconstruction differs from the original?”, etc. Also to show Gibbs phenomena and aliasing.

Everything should be reactive to GUI widgets to control parameters.

Considering that the goal is to teach basic DSP, I would very much prefer not using the DFT for approximating the Fourier Transforms, because I feel this will confuse the student a lot. I know that with careful manipulation, advanced “dspers” can use the FFT for this, but good luck explaining that to somebody who is starting to learn Fourier analysis. Of course, if the student only interacts with the GUI and never reads the code, will be oblivious, but I intend the code to be part of the lesson.

I imagine doing this by first writing code to handle linear combinations and time/frequency shifting. Second, writing some structure that holds a transform-pair and keeps them in sync when operating in one domain (e.g. if the user time-shifts one part, the other should be phase-rotated). Third, and the hardest: a way to provide arithmetical and convolutional products between all the elemental signals in the ensemble. This is needed for the windowing and filtering.

I was curious about what tools Julia and its ecosystem already provides to do this. I already have this in mind:

  • Makie for GUI and plots. I already tested a basic version of this idea and was impressed with the speed.
  • Symbolics for linear combinations.
    • Maybe also for solving the definite integrals of the FT?
  • Multiple dispatch for easily expanding the repertoire of transform-pairs and detecting missing product combinations.

I know doing this for many signals is very ambitious, but I’m fine having just a few elemental signals to play.

Thanks for reading. I hope somebody can guide me.

Bye!

Some material that I found very helpful in learning about signals in an intuitive sense are:

  1. https://www.hpmemoryproject.org/an/pdf/an_243.pdf
  2. Robert Bond Randall’s book “Vibration Based Condition Monitoring” or it you can get it, his older book “Frequency Analysis”.

Randall does a good job trying to get people to picture signals as rotating vectors.

To answer your question more specifically I am wondering if Grant Sanderson can be of help.