Пример #1
0
    def isotope (self,before="POMASS =    1.000", change="POMASS =    3.000"):
        from pymatgen.io.vasp.outputs import Poscar
        from pymatgen.io.vasp.inputs import PotcarSingle
        from pymatgen.io.vasp.outputs import Potcar
        from pymatgen.io.vasp.sets import MPNMRSet
        import shutil
        import os
        os.chdir(self.dire)
        print (os.getcwd())
        poscar= Poscar.from_file("POSCAR")
        # structure = poscar.structure
        print (poscar)
        potcar= Potcar.from_file("POTCAR")
        potc=str(potcar)

        cc= potc.replace(before,change)

        vv=PotcarSingle(cc,)
        vv.write_file("POTCAR_1")

        print (vv)