CharacteristicMappingMethod / cmm-turbulence

CMM Turbulence code
GNU General Public License v3.0
1 stars 0 forks source link

Rework function files layout #21

Closed Arcadia197 closed 2 years ago

Arcadia197 commented 2 years ago

Functions are starting to get randomly scattered across different files. Cudagrid contains grid class, fft functions and save functions, which does not nicely correspond to the file name anymore. Also, simulation and euler contain a few functions which name are a bit misleading.

My idea: Setup structure with main core loop (euler file), containing subfunctions for routines, which should not contain any kernel functions Kernel and device functions will be moved into different files, clustered under areas. Those could be 'simulation', 'hermite', 'fft', 'grid transformations', 'save functions', 'particles', 'conservation' and maybe a 'helper' file for useful little functions.

Contents of specific files: simulation - map advection, applying map stack, initial condition, incompressibility check hermite - nothing changed fft - all functions in fourier space (iLap, lap, dx, dy) and transformations containing cufftDoubles grid transformations - i'm not sure yet, content of cudagrid together with other usefull classes? save functions - binary and hdf save options particles - well, particles conservation - all conservational properties to be investigated over time, this should also contain incomp threshold and timing i think helper - old or not used code could go in here for storage in commented form

Arcadia197 commented 2 years ago

I directly started with this and moved all fft and fourier space related functions in a new file called cmm-fft. I like the naming convention with cmm at the beginning, as cuda is too obvious. I think I will keep it for further files

Arcadia197 commented 2 years ago

new folder numerical contains hermite, timestep and particle computations, as they all can be described under this category

cmm-io hosts the read and write operations

cudagrid has been cleared of all functions which do not belong there

Arcadia197 commented 2 years ago

Files have been restructured. This has been addressed in a recent commit at eclipse branch. Now all files and functions are in my opinion very nicely structured.