Skip to content

Convert 'anyv' parallelisation to 'anysv' - #361

Merged
johnomotani merged 2 commits into
masterfrom
anysv-region
Jul 13, 2025
Merged

Convert 'anyv' parallelisation to 'anysv'#361
johnomotani merged 2 commits into
masterfrom
anysv-region

Conversation

@johnomotani

Copy link
Copy Markdown
Collaborator

Anticipate that when calculating multi-species collisions, the collision operators for every species should be calculated together, to be able to re-use parts of the computation. Therefore rather than 'anyv' regions inside an outer loop over species, r, and z, we want to have an outer loop over r and z, containing inner loops over both species and velocity space - call this an 'anysv' region (for any 's'pecies or 'v'elocity).

Resolves #356.

@johnomotani

Copy link
Copy Markdown
Collaborator Author

@mrhardman for now this PR does not include any loops over species, and just hard-codes is = 1 in the collision operator call https://github.com/mabarnes/moment_kinetics/blob/7cac2075cb8d2a2725281ef62f1bc36e507e2af2/moment_kinetics/src/fokker_planck.jl#L348
I'll leave it up to you to put the species-loops in the right places, and merge this with #353.

Anticipate that when calculating multi-species collisions, the collision
operators for every species should be calculated together, to be able to
re-use parts of the computation. Therefore rather than 'anyv' regions
inside an outer loop over species, r, and z, we want to have an outer
loop over r and z, containing inner loops over both species and velocity
space - call this an 'anysv' region (for any 's'pecies or 'v'elocity).
Currently only supports a single ion species - `is = 1` is hard-coded in
the outer loop.
@johnomotani
johnomotani merged commit 8e9f985 into master Jul 13, 2025
21 checks passed
@johnomotani
johnomotani deleted the anysv-region branch July 13, 2025 19:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Change anyv region parallelisation to support implicit cross-species collisions in the future

1 participant