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

Computation power spectra with folding #218

Open
JegerBroxterman opened this issue Dec 11, 2024 · 0 comments
Open

Computation power spectra with folding #218

JegerBroxterman opened this issue Dec 11, 2024 · 0 comments

Comments

@JegerBroxterman
Copy link

Hi,

The way the power spectra with folding are computed currently is by changing the positions of particles according to

box_over_fold_x = box_x / fold
inv_box_over_fold_x = 1.0 / box_over_fold_x
x_pos = (x_pos % box_over_fold_x) * inv_box_over_fold_x

with fold = 2.0^folding, i.e. (from swiftsimio readthedocs)
image

Should this not be
x_pos = (x_pos % box_over_fold_x) * fold ?

For example, without folding (folding = 0 and fold =1) the positions are now converted to
x_pos = (x_pos % (Lbox/1) ) * 1 / Lbox = x_pos / Lbox

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

No branches or pull requests

1 participant