Skip to content

Add get_nj_max function similar to Sapporo Light#18

Merged
HannoSpreeuw merged 2 commits into
masterfrom
Address_comment_AMUSE_issue_1209
May 28, 2026
Merged

Add get_nj_max function similar to Sapporo Light#18
HannoSpreeuw merged 2 commits into
masterfrom
Address_comment_AMUSE_issue_1209

Conversation

@HannoSpreeuw

Copy link
Copy Markdown
Collaborator

This should address @LourensVeen 's comment in AMUSE issue 1209.

For users of Sapporo Light backends, e.g. with PH4, attempted simulations with more than nj_max (currently set at 2^17) particles will yield an error in the "code.out" output file, if "redirection='file'" was set in the controlling Python script.
This was implemented through AMUSE MR 1218.
This commit has that same goal.
The first part of the code changes equivalent to AMUSE MR1218 have been added in the previous commit 13da4fe.
1) We increased the default value of "nj_max = 16384", which is way too low for many simulations. Instead, we set it to 2^18. The current default in Sapporo Light is 2^17.
2) Also, we added extra info to the error message if "address > nj_max".
@HannoSpreeuw

Copy link
Copy Markdown
Collaborator Author

What remains to be added is the PH4 code changes from MR 1218 that propagate the value of nj_max to higher levels, i.e. such that it becomes available at the level of the controlling Python script.

@HannoSpreeuw HannoSpreeuw changed the title Address comment amuse issue 1209 Add get_nj_max function similar to Sapporo Light May 28, 2026
@HannoSpreeuw HannoSpreeuw merged commit 30ec270 into master May 28, 2026
@HannoSpreeuw HannoSpreeuw deleted the Address_comment_AMUSE_issue_1209 branch May 28, 2026 13:34
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.

1 participant