-
Notifications
You must be signed in to change notification settings - Fork 22
Description
Hej,
Following the discussion here, I've started to think about what should be the next big steps in the modernization of fftpack. In my opinion, the two most important ones would be:
- Templating all of the routines with
fyppto support all the different precisions already included instdlib(simple, double, extended, and quadruple). - Provide modern high- and low-levels interfaces to the different transforms, similar to what has been done with
stdlib_linalgmodule.
For both of these ideas, I think that restructuring the package into a set of well-defined modules and submodules would be a good idea. Not only would all the functionalities be equipped with a proper interface, but it will also ease maintenance and the eventual move to fypp-templating.
Here is a possible structure followed by a short description of the different modules/submodules.
.
└── src/
├── module: fftpack.f90
├── module: fftpack_kinds.f90
├── module: fftpack_legacy.f90
│ └── submodule: fftpack_drivers.f90
│ ├── submodule: fftpack_drivers_pass.f90
│ └── submodule: fftpack_drivers_rad.f90
├── module: fftpack_modern.f90
└── module: fftpack_utils.f90
-
fftpack_kinds.f90(module): Essentially a module similar tostdlib_kindsdefining all the different precisions supported byfftpack(currently only double precision, but we'll be able to extend this list once we start usingfypp). -
fftpack_legacy.f90(module): Defines all the legacy interfaces to the transforms supported byfftpack(and eventually those for the future precisions withfypp).fftpack_drivers.f90(submodule): Provides the actual implementations of the different transforms + the definition of the interfaces for the set ofpass*andrad*routines.fftpack_drivers_pass.f90(submodule): Provides all of the implementations of thepass*subroutines (including all the different precisions later on).fftpack_drivers_rad.f90(submodule): Provides all of the implementations of therad*subroutines (including all the different precisions later on).
-
fftpack_modern.f90(module): Provides all of the modern generic interfaces (and implementations?) that may eventually become thestdlibstandard (see this discussion). -
fftpack_utils.f90(module): A simple module with all of the utility functions we can already have or can think of.
This is just a sketch but since it may eventually impact how stdlib will support Fourier transforms, let me ping part of the other team to get their feedback as well. Ping: @perazz, @jalvesz, @jvdp1, @zoziha. @p-costa, you also have extensive experience with 2DECOMP&FFT library I believe so feel free to give your own 2 cents about modern interfaces for instance. @jacobwilliams, @certik, @milancurcic, @ivan-pi, since you were involved in the initial discussion and modernization a few years ago, your insights are also more than welcome.