@Override
  public Pointer<Float> allocate(int... n) {
    long size = 1;
    for (int val : n) {
      size *= val;
    }

    // Allocate complex numbers
    return FFTW3Library32.fftwf_alloc_real(size * 2);
  }
 @Override
 public Pointer<Float> deallocate(Pointer<Float> memory) {
   FFTW3Library32.fftwf_free(memory);
   return memory;
 }