PyIron+Sphinx 中的自旋约束

Spin constraining in PyIron+Sphinx

我想限制体原子的自旋,同时让我的超级晶胞的自由表面原子释放它们的磁矩。在 PyIron+SPhinx 中是否有可能限制超晶胞中原子子集(不是全部)的自旋?

是的,原则上是可以的:

from pyiron import Project
import numpy as np

spx = pr.create.job.Sphinx('spx')
spx.structure = pr.create.structure.bulk('Fe', a=2.83, cubic=True)
spx.structure.set_initial_magnetic_moments([2, 2])
spx.fix_spin_constraint = True
spx.structure.spin_constraint = np.array([True, False])
spx.calc_static()
spx.run()

简短说明:spx.fix_spin_constraint = True初始化属性spx.structure.spin_constraint,它只包含True开头的所有原子。对于不需要约束的原子,可以设置False.