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

SOLVED: Issue with Kabsch alignment #17

Merged
merged 1 commit into from
Apr 2, 2024

Conversation

alessiagp
Copy link

This pull request solves the issue I found when computing the Kabsch alignment of two nearly identical structures. I added an absolute value to the calculation of the RMSD to prevent the generation of very small negative values.

When two structures are found to be identical by the program, the value align->rmsd_mat[knt]*align->rmsd_mat[knt] is equal to zero. If msd_removed (found at 10^-29 for identical structures) is greater than msd_added (found at 10^-30 for identical structures), the overall result is negative so the RMSD cannot be calculated.

This update yields a very small value of RMSD even to nearly identical structures, allowing the computation of Kabsch alignment.

I corrected the function for all clustering criterions.

@mgiulini mgiulini self-requested a review April 2, 2024 08:49
@mgiulini mgiulini merged commit 81a8721 into potestiolab:master Apr 2, 2024
2 checks passed
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.

2 participants