Hi,
may I suggest to add an "examples" directory with at least one little program to show how to go from samples to spectrum and back?
It might look like this:
use Math::FourierTransform;
my Complex @data = (1..6)».Complex;
say @data;
my Complex @spectrum = discrete-fourier-transform @data;
say @spectrum;
my Complex @back = (discrete-fourier-transform(@spectrum».conj)».conj) »/» @data.elems;
say @back;
# Let's cheat!
say @back».round(10⁻¹²);
Additional examples may show how to use the transformed data to implement a high or low-pass filter.
Hi Fernando, if you want to edit the README with what you'd like to see I'm happy to accept a PR. That way you go on record as knowing whats happening in the example ;P
Hi, may I suggest to add an "examples" directory with at least one little program to show how to go from samples to spectrum and back? It might look like this:
Additional examples may show how to use the transformed data to implement a high or low-pass filter.