https://github.com/hendriks73/jipesfft
Native FFT for jipes
https://github.com/hendriks73/jipesfft
aarch64 accelerate-framework arm64 fft java jipes jni linux macos windows x86-64
Last synced: about 2 months ago
JSON representation
Native FFT for jipes
- Host: GitHub
- URL: https://github.com/hendriks73/jipesfft
- Owner: hendriks73
- License: lgpl-2.1
- Created: 2021-10-15T09:15:45.000Z (over 3 years ago)
- Default Branch: dev
- Last Pushed: 2023-08-05T13:36:47.000Z (almost 2 years ago)
- Last Synced: 2025-01-28T15:49:39.232Z (4 months ago)
- Topics: aarch64, accelerate-framework, arm64, fft, java, jipes, jni, linux, macos, windows, x86-64
- Language: Java
- Homepage:
- Size: 445 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html)
[](https://maven-badges.herokuapp.com/maven-central/com.tagtraum/jipesfft)
[](https://github.com/hendriks73/jipesFFT/actions?query=branch%3Adev++)
[](https://codecov.io/gh/hendriks73/jipesFFT/tree/dev)# jipesFFT
Native FFT (Fast Fourier Transformation) implementations for Java
(macOS, Windows, Linux).The macOS version uses Apple's [Accelerate
framework](https://developer.apple.com/documentation/accelerate).
Windows and Linux versions use more ordinary implementations.## Installation
jipesFFT is released via [Maven](https://maven.apache.org).
You can install it via the following dependency:```xml
com.tagtraum
jipesfft-complete
```
## Usage
Here's a simple example that demonstrates how the `com.tagtraum.jipesfft.FFT`
class can be used:```java
import com.tagtraum.jipesfft.FFT;class Demo {
public static void main(final String[] args) {
// Create a new FFT instance suitable
// for a window length of 8 samples.
// Do this in a "try" statement to ensure native resources
// are freed in a timely fashion.
try (final FFT fft = new FFT(8)) {
final float[] result = fft.transform(new float[]{0, 0, 0, 1, 0, 0, 0, 1});
// real part of the complex result
float[] real = result[FFT.REAL];
// imaginary part of the complex result
float[] imaginary = result[FFT.IMAGINARY];
// frequencies for the result - must still be multiplied with sampling
// frequency. Second half of frequency array is not necessarily useful.
float[] frequencies = result[FFT.FREQUENCY];// go on and do something with it...
}
}
}
```## Java Module
jipesFFT is shipped as a Java module
(see [JPMS](https://en.wikipedia.org/wiki/Java_Platform_Module_System))
with the name `tagtraum.jipesfft`.## API
You can find the complete [API here](https://hendriks73.github.io/jipesFFT/).
## Additional Resources
- [Discrete Fourier Transform (Wikipedia)](https://en.wikipedia.org/wiki/Discrete_Fourier_transform)
- [Intro to Discrete Fourier Transform by M. Müller and F. Zalkow](https://www.audiolabs-erlangen.de/resources/MIR/FMP/C2/C2_DFT-FFT.html)
- [Fast Fourier Transform (algorithm)](https://en.wikipedia.org/wiki/Fast_Fourier_transform)
- [Nyquist Frequency](https://en.wikipedia.org/wiki/Nyquist_frequency)
- [Fundamentals of Music Processing by Meinard Müller](https://www.springer.com/gp/book/9783030698072)