Skip to content

Commit 407f07e

Browse files
authored
Update README.md
1 parent 564ddbf commit 407f07e

File tree

1 file changed

+125
-1
lines changed

1 file changed

+125
-1
lines changed

README.md

Lines changed: 125 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,131 @@
1-
# sqs_substitution_tool
1+
# 🔁 SQS Substitution Tool
22

33
[![Documentation Status](https://img.shields.io/badge/docs-online-blue.svg)](https://naveen-dandu.github.io/sqs_substitution_tool/)
44
[![CI](https://github.com/naveen-dandu/sqs_substitution_tool/actions/workflows/python-package.yml/badge.svg)](https://github.com/naveen-dandu/sqs_substitution_tool/actions)
55
[![LICENSE](https://img.shields.io/github/license/naveen-dandu/sqs_substitution_tool)](LICENSE)
66

77
A substitution-based randomizer for generating VASP-compatible POSCAR files.
8+
9+
A Python-based command-line utility to perform **site substitution** in crystal structures (POSCAR/CONTCAR format), enabling the generation of **Special Quasirandom Structures (SQS)** for binary, ternary, or quaternary materials systems.
10+
11+
---
12+
13+
## 🔍 Overview
14+
15+
This tool automates the substitution of atoms in a crystal lattice with customizable control over:
16+
- **Which elements to replace**
17+
- **How many atoms to substitute**
18+
- Randomized sampling of configurations (without replacement)
19+
- Output format in standard VASP-compatible POSCAR format
20+
21+
---
22+
23+
## 🧪 Use Case
24+
25+
Simulating alloy or doped systems such as:
26+
27+
- Substituting `O` with `S` in ZnO₂
28+
- Generating SQS-like structures for CoBHT by replacing Co atoms with Ni, Mn, or Cu
29+
- Studying defect energetics or composition-dependent electronic structure
30+
31+
---
32+
33+
## 🚀 Installation
34+
35+
```bash
36+
git clone https://github.com/naveen-dandu/sqs_substitution_tool.git
37+
cd sqs_substitution_tool
38+
pip install -r requirements.txt # optional, if needed
39+
```
40+
---
41+
42+
## 🔀 SQS Substitution Tool
43+
This Python script provides an interactive CLI interface for performing simple SQS-like random substitutions on atoms in a VASP structure (POSCAR) using pymatgen.
44+
45+
## 📦 Features
46+
Select a host atom to substitute
47+
Specify the number of substitutions
48+
Choose multiple elements to substitute with
49+
Performs randomized substitutions over the specified host atom indices
50+
Outputs a modified structure as POSCAR_substituted
51+
52+
---
53+
54+
## 🖥️ Usage
55+
56+
```bash
57+
python sqs_prompt_substitute.py
58+
```
59+
60+
You will be prompted interactively:
61+
62+
```vbnet
63+
64+
Which atom do you want to substitute (e.g., Co)? Co
65+
Found 3 atoms of Co.
66+
How many atoms do you want to substitute? [1 <= n <= 12] 2
67+
Enter substitution elements (e.g., Cu Ni Mn): Cu Mn
68+
69+
Substitution complete. Output written to POSCAR_substituted
70+
🧬 Replacements made:
71+
- Atom index 1Cu
72+
- Atom index 2Mn
73+
```
74+
75+
---
76+
77+
## 📁 Input
78+
Ensure a file named POSCAR_CoBHT is present in the same directory.
79+
This should be a valid VASP POSCAR file readable by pymatgen.
80+
81+
---
82+
83+
## 📤 Output
84+
A new file POSCAR_substituted will be generated with the substituted atoms.
85+
86+
---
87+
88+
## 🛠 Requirements
89+
Python 3.7+
90+
pymatgen
91+
92+
Install via pip:
93+
94+
```bash
95+
96+
pip install pymatgen
97+
```
98+
99+
---
100+
101+
🧠 Features
102+
Works with any crystal structure containing labeled atoms
103+
Supports binary, ternary, and quaternary systems
104+
Tracks replaced atom indices for reproducibility
105+
Prepares data for machine learning and SQS generation
106+
107+
---
108+
109+
## 📄 License
110+
MIT License. See LICENSE.
111+
112+
---
113+
114+
## 👨‍🔬 Author
115+
Developed by Naveen Dandu, with integration in materials data workflows.
116+
117+
---
118+
119+
## 📣 Citation
120+
121+
If you use this tool for your research or publication, please cite:
122+
123+
```
124+
@software{sqs_sub_tool,
125+
author = {Naveen Dandu},
126+
title = {SQS Substitution Tool},
127+
year = 2025,
128+
url = {https://github.com/naveen-dandu/sqs_substitution_tool}
129+
}
130+
```
131+

0 commit comments

Comments
 (0)