Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use amrex::FFT for Gaussian random field generation #775

Open
BenWibking opened this issue Oct 17, 2024 · 5 comments
Open

use amrex::FFT for Gaussian random field generation #775

BenWibking opened this issue Oct 17, 2024 · 5 comments
Labels
enhancement New feature or request

Comments

@BenWibking
Copy link
Collaborator

Describe the proposal
Now that amrex::FFT exists, we can do the FFT to generate Gaussian random fields (e.g., for turbulence initial conditions and driving) directly on the GPU.

Describe alternatives you've considered
Keep using the existing Python script to generate the input turbulence field.

Additional context
AMReX-Codes/amrex#4193

cc @psharda @markkrumholz

@BenWibking BenWibking added the enhancement New feature or request label Oct 17, 2024
@BenWibking BenWibking changed the title use amrex::FFT for Gaussian random field generator use amrex::FFT for Gaussian random field generation Oct 17, 2024
@markkrumholz
Copy link
Collaborator

I can't tell from the AMReX PR: how / does this handle adaptive grids?

@BenWibking
Copy link
Collaborator Author

I can't tell from the AMReX PR: how / does this handle adaptive grids?

It doesn't. What I had in mind was very high resolution uniform grid turbulence simulations. But you could interpolate using the AMR machinery to fine grids.

@markkrumholz
Copy link
Collaborator

I can't tell from the AMReX PR: how / does this handle adaptive grids?

It doesn't. What I had in mind was very high resolution uniform grid turbulence simulations. But you could interpolate using the AMR machinery to fine grids.

I see. OK, then while I think we might want to use this for initial condition generation, I don't think we want to use it for turbulence driving. For turbulence driving you want to have the capability to drive at wavenumbers smaller than are supported on the level 0 grid. Ronan's implementation using Christoph's driving code is working now, and he's preparing the PRs to get the necessary changes incorporated into both Christoph's code and Quokka.

@BenWibking
Copy link
Collaborator Author

Ok, great. Right, this would only be for non-AMR cases.

@markkrumholz
Copy link
Collaborator

Understood.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants