This constraint preserves the bravais lattice in constant stress simulations or optimization.
Parameters: local_atoms (list of int | None) – The group of atoms from which the frozen degrees of freedom should be calculated, e.g. a thermalized group of atoms. Default: All atoms. Returns: The number of degrees of freedom that are frozen by this constraint object. Return type: int
Run a geometry optimization of a rutile crystal with the Bravais lattice type fixed.
constraints = [BravaisLatticeConstraint()] bulk_configuration = OptimizeGeometry( bulk_configuration, max_forces=0.05*eV/Ang, max_stress=0.1*GPa, max_steps=200, max_step_length=0.2*Ang, constraints=constraints, trajectory_filename=None, optimizer_method=LBFGS(), )