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

Surface Charge Script #67

Merged
merged 8 commits into from
Aug 20, 2024
Merged

Surface Charge Script #67

merged 8 commits into from
Aug 20, 2024

Conversation

Alex-AMC
Copy link
Contributor

@Alex-AMC Alex-AMC commented Aug 20, 2024

This tool returns the surface charge for a given structure and a list of supplied hkl and offsets.
The script provides a GUI that can be used from Mercury or from the command line.

The output is a HTML file with a table for all the all selected surfaces and their associated charge, projected surface areas and normalised surface charge.

  • Users can supply a refcode or mol2 file whilst in command line mode.
  • If used from mercury, it will use the selected structure
  • It is sensitive to the structure bonding information, and thus, some difference may arise from using Refcode vs mol2 if the bonding is not exactly the same.

GUI:
image
Output example:
image

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Example Output:
![Example Output](assets/example_output.png)

> **Note** - When comparing charges for structures out of the CSD and from mol2 files the values might be different as the bonding might not be the same. When importing a mol2 the bonding and charges have to be calculated on the fly. Whereas the CSD structures the bonding is pre-assigned.
Copy link
Member

Choose a reason for hiding this comment

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

Whereas for CSD structures?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes thank you! I got sidetracked whilst writing this note and it could probably do with re-writing anyway

scripts/ReadMe.md Outdated Show resolved Hide resolved
Copy link
Contributor

@psacchi-ccdc psacchi-ccdc left a comment

Choose a reason for hiding this comment

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

Looking good!

scripts/surface_charge/_surface_charge_calculator.py Outdated Show resolved Hide resolved
scripts/surface_charge/surface_charge.py Show resolved Hide resolved
@ccdc-opensource ccdc-opensource deleted a comment from pmbulit Aug 20, 2024
# HTML Table Footer
html += """
</table>
<p><i> *-Surface charge is based on gasteiger partial charges <a href="https://www.sciencedirect.com/science/article/pii/S0040403901949779?via%3Dihub">10.1016/S0040-4039(01)94977-9</a></i> </p>
Copy link
Contributor

Choose a reason for hiding this comment

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

🚫 [flake8] <501> reported by reviewdog 🐶
line too long (205 > 200 characters)

# HTML Table Footer
html += """
</table>
<p><i> *-Surface charge is based on gasteiger partial charges <a href="https://www.sciencedirect.com/science/article/pii/S0040403901949779?via%3Dihub">10.1016/S0040-4039(01)94977-9</a></i> </p>
Copy link
Contributor

Choose a reason for hiding this comment

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

🚫 [flake8] <501> reported by reviewdog 🐶
line too long (205 > 200 characters)

Copy link

sonarcloud bot commented Aug 20, 2024

@Alex-AMC Alex-AMC merged commit 8bfe7f6 into main Aug 20, 2024
5 checks passed
@Alex-AMC Alex-AMC deleted the surface_charge_script branch August 20, 2024 14:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

4 participants