User Tools

Site Tools


How to create GB

Single element GB

Download structure of supercell with GB from Crystalium database.

Twin GB in C2/m Li2MnO3

Take a unit cell of Li2MnO3:

and use the following script:

from siman.geo import create_supercell
from siman.geo import two_cell_to_one
from structures import *
from siman.calc_manage   import add_loop, res_loop, smart_structure_read
from siman.header import db
#create twin
if 1:
    st = smart_structure_read(path_to_file/Li2MnO3.POSCAR)
    st = st.get_conventional_cell()
    mul_matrix = [[1,-1,0],[1,1,0],[1,0,3]]
    sc = create_supercell(st, mul_matrix, mul = (0.5,0.5,1))
    if 1:
         sc.rprimd[0][2] = 0
         sc.rprimd[1][2] = 0
         sc.rprimd[2][1] = 0
    sc = sc.shift_atoms([0,0,0.5])
    scm = sc.mirror(2)'m'
    scm = scm.shift_atoms([0,0,1], return2cell=0)
    sc.rprimd[2] = sc.rprimd[2]*2
    sct = two_cell_to_one(sc, scm)

Constructed supercell:

The same GB with applied periodic translation:

tut/gb.txt · Last modified: 2024/02/19 15:43 by a.boev

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki