Docs are under construction. Content may be incomplete or change.

Apply Atomic Constraints

Page type: Task guide
On this page

Prevent selected atoms or Cartesian components from moving during supported calculations, such as holding a host or slab fixed while relaxing a guest or adsorbate.

Before you begin

Distinguish three controls:

  • A layer lock prevents interactive editing.
  • Layer visibility controls display.
  • An atomic constraint changes the calculation degrees of freedom.

Only the third is a scientific constraint.

Procedure

Constraints panel with per-axis fix controls and the Apply Constraints action

  1. Switch to Edit and select the intended atoms.
  2. Open the Constraints tool.
  3. Enable Fix X, Fix Y, and/or Fix Z.
  4. Apply the constraint and inspect the selected atoms or property table.
  5. Save the constrained structure so its selective flags are preserved.
  6. Run a short test optimization and inspect the trajectory before starting a long workflow.

Use all three axes to hold atoms completely fixed. Use partial Cartesian constraints only when the coordinate system and physical rationale are explicit.

Verify the result

CheckPass condition
Selected indicesExactly the intended atoms are constrained
ComponentsX/Y/Z flags match the physical model
SerializationSaved structure preserves selective flags
Test trajectoryFixed coordinates remain unchanged
Free regionUnconstrained atoms can still respond

Note that convergence behavior can differ by operation. In some optimization paths, forces on constrained atoms may still influence the reported maximum-force criterion even though their coordinates do not move. Inspect both trajectory and force diagnostics.

Variants

  • In Tako Script, use tako.structure.fix(structure, indices) for fully fixed atoms and documented selective-coordinate helpers for partial constraints.
  • For surfaces, constrain physically justified bottom layers rather than every substrate atom by default.
  • For host–guest screening, report clearly that a rigid-host energy excludes induced fit.

Troubleshooting

SymptomLikely causeFix
Host movesLayer was locked but atoms were not constrainedApply X/Y/Z constraints and rerun
Optimization never meets fmaxConstrained atoms retain large reported forcesInspect free-atom motion and operation-specific force masking
Entire structure is immobileSelection or scope included all atomsClear and reapply to intended indices
Constraints vanish after import/exportFile format omitted selective flagsUse extXYZ/workspace formats that preserve metadata
Partial constraint acts in wrong directionCartesian axes do not match intended surface/cell directionInspect axes and use a deliberate coordinate frame