-
Notifications
You must be signed in to change notification settings - Fork 9
refactoring: Create class for coordination number calculation #43
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
Open
Thomas3R
wants to merge
7
commits into
dftd4:main
Choose a base branch
from
Thomas3R:ncoord
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
5f035a2
refactor: move charge models to new multicharge namespace and create …
Thomas3R 7fec355
refactor: create class for coordination number calculation
Thomas3R b85b2c7
Update comment in dftd_ncoord.cpp
Thomas3R 6886aa7
Move cn and dcndr allocation into ncoord and dncoord functions.
Thomas3R c65dc27
NCoordBase constructor initializer list and code cleanup
Thomas3R b2a6fc0
rename functions for consistency
Thomas3R fc8baed
Leave deletion of arrays to object destructor
Thomas3R File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The D4 CN should not be part of the base class. In the Fortran code, this is also a separate subclass (of an error function CN class).
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the best way would be to include the
den
factor in thecountf
:cpp-d4/src/dftd_ncoord.cpp
Lines 460 to 461 in d61715f
Then we could create a new derived type of the
NCoordBase
e.g.NCoordErfD4
that usesncoord_base
. This way we could delete all the "doublicate" _d4 functions and would implement consistent dimensions for dcndr(N, 3N).There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just realized that changing dcndr(3N, N) to dcndr(N, 3N) is a lot more work than I thought and should be a PR for itself. Since I can not merge the _d4 functions and into the base class functions without this I will not implement this for now.