zsiciarz / aquila

Aquila is a digital signal processing library for C++11.
http://aquila-dsp.org
MIT License
462 stars 112 forks source link

What is Aquila?

Aquila is an open source and cross-platform DSP (Digital Signal Processing) library for C++11.

Build Status Windows Build Status Coverage Status Coverity Scan Build Status

Example

#include "aquila/aquila.h"

int main()
{
    // input signal parameters
    const std::size_t SIZE = 64;
    const Aquila::FrequencyType sampleFreq = 2000, f1 = 125, f2 = 700;

    Aquila::SineGenerator sine1(sampleFreq);
    sine1.setAmplitude(32).setFrequency(f1).generate(SIZE);
    Aquila::SineGenerator sine2(sampleFreq);
    sine2.setAmplitude(8).setFrequency(f2).setPhase(0.75).generate(SIZE);
    auto sum = sine1 + sine2;

    Aquila::TextPlot plot("Input signal");
    plot.plot(sum);

    // calculate the FFT
    auto fft = Aquila::FftFactory::getFft(SIZE);
    Aquila::SpectrumType spectrum = fft->fft(sum.toArray());

    plot.setTitle("Spectrum");
    plot.plotSpectrum(spectrum);

    return 0;
}

For more usage examples see the examples directory or browse them online.

Features

Requirements

The following dependencies are required to build the library from source.

Contributing

See CONTRIBUTING.md for some guidelines how to get involved.

License

The library is licensed under the MIT (X11) license. A copy of the license is distributed with the library in the LICENSE file.

Authors

Zbigniew Siciarz (zbigniew at siciarz dot net)

This library includes code from Takuya Ooura's mathematical software packages, which are available at http://www.kurims.kyoto-u.ac.jp/~ooura/.