Skip to content

Conversation

@matteobecchi
Copy link
Collaborator

@matteobecchi matteobecchi commented Dec 17, 2025

Related Issues: close #145
Requested Reviewers: @andrewtarzia @SimoneMartino98

In the LENS and neighbor_list code, if the simulation box is not provided in the Universe, it is computed by the code. But in the case of system without PBC, the box was computed anew even if it was present.

With 2D system, this new box had zero thickness, and this lead to the code crashing with divisions by zero.

I solved the problem by only computing the box anew if it's not present in the Universe.

All previous tests still pass, and I added new tests on 2D systems to ensure everything works.

@matteobecchi
Copy link
Collaborator Author

I also solved (I think) the issue #144 , avoiding the "netCDF4 is not available. Writing AMBER ncdf files will be slow." message every time dynsight is imported in a script.

@matteobecchi matteobecchi linked an issue Dec 17, 2025 that may be closed by this pull request
@matteobecchi matteobecchi self-assigned this Dec 17, 2025
Copy link
Collaborator

@SimoneMartino98 SimoneMartino98 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

very nice !

@matteobecchi matteobecchi changed the title Solving issue #145 Solving issues #145 and #144 Dec 17, 2025
@matteobecchi matteobecchi marked this pull request as ready for review December 17, 2025 10:45
@matteobecchi matteobecchi merged commit 87c0b58 into GMPavanLab:main Dec 17, 2025
11 checks passed
@matteobecchi matteobecchi deleted the devel branch December 17, 2025 10:55
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.

list_neighbours_along_trajectory() calculation fails in 2D systems Remove useless MDA warnings

3 participants