[WIP] Add script for automating delithiated LiFePO4 structure generation
Thanks for asking me to work on this. I will get started on it and keep this PR's description up to date as I form a plan and make progress.
Original prompt
Problem Statement
Create a script that automates the generation of delithiated Li₁₋₋ₓFePO₄ structures using the supercell program.
Requirements
The script should:
- Input: Accept a CIF file containing LiFePO₄ structure
- Supercell Generation: Create supercells of two types:
- 1x2x1 (expansion along b-axis)
- 1x1x2 (expansion along c-axis)
- Delithiation: Generate Li₁₋ₓFePO₄ structures by removing Li atoms at various concentrations (x values)
- Output: Produce CIF files for each delithiated structure using the supercell program
Implementation Details
The script should:
- Use the supercell program's capabilities for creating supercells and generating derivative structures
- Support multiple delithiation levels (e.g., x = 0.25, 0.5, 0.75, 1.0)
- Generate all symmetrically unique configurations for each composition
- Name output files systematically (e.g.,
LiFePO4_1x2x1_Li0.75FePO4_config1.cif)- Provide clear usage instructions and command-line options
Suggested Approach
- Parse the input CIF file
- Use supercell program to create the specified supercell (1x2x1 or 1x1x2)
- Use supercell's charge balancing or substitution features to remove Li atoms
- Generate all unique configurations for each composition
- Output results with descriptive filenames
Language
The script can be written in Python, bash, or another appropriate scripting language that can interface with the supercell program.
Testing
Include example usage with a sample LiFePO₄ CIF file if possible, or provide clear documentation on how to test the script.
This pull request was created as a result of the following prompt from Copilot chat.
Problem Statement
Create a script that automates the generation of delithiated Li₁₋₋ₓFePO₄ structures using the supercell program.
Requirements
The script should:
- Input: Accept a CIF file containing LiFePO₄ structure
- Supercell Generation: Create supercells of two types:
- 1x2x1 (expansion along b-axis)
- 1x1x2 (expansion along c-axis)
- Delithiation: Generate Li₁₋ₓFePO₄ structures by removing Li atoms at various concentrations (x values)
- Output: Produce CIF files for each delithiated structure using the supercell program
Implementation Details
The script should:
- Use the supercell program's capabilities for creating supercells and generating derivative structures
- Support multiple delithiation levels (e.g., x = 0.25, 0.5, 0.75, 1.0)
- Generate all symmetrically unique configurations for each composition
- Name output files systematically (e.g.,
LiFePO4_1x2x1_Li0.75FePO4_config1.cif)- Provide clear usage instructions and command-line options
Suggested Approach
- Parse the input CIF file
- Use supercell program to create the specified supercell (1x2x1 or 1x1x2)
- Use supercell's charge balancing or substitution features to remove Li atoms
- Generate all unique configurations for each composition
- Output results with descriptive filenames
Language
The script can be written in Python, bash, or another appropriate scripting language that can interface with the supercell program.
Testing
Include example usage with a sample LiFePO₄ CIF file if possible, or provide clear documentation on how to test the script.
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.