Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/killiansheriff/atomisticreversemontecarlo
OVITO Python modifier to generate bulk crystal structures with target Warren-Cowley parameters.
https://github.com/killiansheriff/atomisticreversemontecarlo
high-entropy-alloys materials-science monte-carlo monte-carlo-simulation order-parameters ovito python-modifiers reverse-monte-carlo warren-cowley-parameters
Last synced: 3 days ago
JSON representation
OVITO Python modifier to generate bulk crystal structures with target Warren-Cowley parameters.
- Host: GitHub
- URL: https://github.com/killiansheriff/atomisticreversemontecarlo
- Owner: killiansheriff
- Created: 2023-07-12T19:20:40.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-11-21T20:58:43.000Z (about 1 month ago)
- Last Synced: 2024-12-09T05:42:45.010Z (14 days ago)
- Topics: high-entropy-alloys, materials-science, monte-carlo, monte-carlo-simulation, order-parameters, ovito, python-modifiers, reverse-monte-carlo, warren-cowley-parameters
- Language: Python
- Homepage:
- Size: 10.8 MB
- Stars: 21
- Watchers: 3
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Atomistic Reverse Monte-Carlo
![PyPI Version](https://img.shields.io/pypi/v/AtomisticReverseMonteCarlo.svg) ![PyPI Downloads](https://static.pepy.tech/badge/AtomisticReverseMonteCarlo)OVITO Python modifier to generate bulk crystal structures with target Warren-Cowley parameters.
## Usage
Here's an example on how to use the code to create the ``fcc_wc.dump`` file which has Warren-Cowley parameters that falls within a 1% difference of the targeted ones:```python
from ovito.io import export_file, import_filefrom AtomisticReverseMonteCarlo import AtomisticReverseMonteCarlo
mod = AtomisticReverseMonteCarlo(
nneigh=12, # number of neighbors to compute WC parameters (12 1NN in fcc)
T=1e-9, # rMC temperature
target_wc=[ # wc target 1-pij/cj
[0.32719603, -0.19925471, -0.12794131],
[-0.19925471, 0.06350427, 0.13575045],
[-0.12794131, 0.13575045, -0.00762235],
],
tol_percent_diff=[ # max percent tolerence allowed before stopping
[1, 1, 1],
[1, 1, 1],
[1, 1, 1],
],
save_rate=1000, # save rate
seed=123,
max_iter=None, # infinity number of iterations
)# Load the intial snapshot
pipeline = import_file("fcc_random.dump")
pipeline.modifiers.append(mod)
data = pipeline.compute()# Load data of the last trajectory
data = pipeline.compute(-1)
print(f'Target Warren-Cowley parameters: \n {data.attributes["Target Warren-Cowley parameters"]}')
print(f'Warren-Cowley parameters: \n {data.attributes["Warren-Cowley parameters"]}')
print(f'Warren-Cowley Percent error: \n {data.attributes["Warren-Cowley percent error"]}')export_file(
data,
"fcc_wc.dump",
"lammps/dump",
columns=[
"Particle Identifier",
"Particle Type",
"Position.X",
"Position.Y",
"Position.Z",
],
)
```
The script can be found in the ``examples`` directory.![](media/ovito_example.png)
## Installation
For a standalone Python package or Conda environment, please use:
```bash
pip install --user AtomisticReverseMonteCarlo
```For *OVITO PRO* built-in Python interpreter, please use:
```bash
ovitos -m pip install --user AtomisticReverseMonteCarlo
```If you want to install the lastest git commit, please replace ``AtomisticReverseMonteCarlo`` with ``git+https://github.com/killiansheriff/AtomisticReverseMonteCarlo``.
![](media/ovito_pro_desktop.png)
## Contact
If any questions, feel free to contact me (ksheriff at mit dot edu).## References & Citing
If you use this repository in your work, please cite:```
@article{sheriffquantifying2024,
title = {Quantifying chemical short-range order in metallic alloys},
doi = {10.1073/pnas.2322962121},
journaltitle = {Proceedings of the National Academy of Sciences},
author = {Sheriff, Killian and Cao, Yifan and Smidt, Tess and Freitas, Rodrigo},
date = {2024-06-18},
}
```