Constraints
The Constraints keyword in the OPT section supports multiple clauses joined by
;.
Frozen Atoms/Components
| Syntax | Example | Description |
|---|---|---|
freeze_atoms:i-j;k | freeze_atoms:1-3;6 | Freeze all components of atoms 1–3 and 6 |
freeze_x:i | freeze_x:2 | Freeze X component of atom 2 |
freeze_y:i | freeze_y:3 | Freeze Y component of atom 3 |
freeze_z:i | freeze_z:4 | Freeze Z component of atom 4 |
freeze_xy:i | freeze_xy:5 | Freeze X and Y of atom 5 |
freeze_xz:i | freeze_xz:6 | Freeze X and Z of atom 6 |
freeze_yz:i | freeze_yz:7 | Freeze Y and Z of atom 7 |
Geometric Targets
Append ! for hard constraint (enforced via null-space projection).
| Syntax | Example | Description |
|---|---|---|
bond:i-j=value | bond:1-2=1.40ang | Bond distance target |
angle:i-j-k=value | angle:1-2-3=104.5deg | Bond angle target |
dihedral:i-j-k-l=value | dihedral:1-2-3-4=180deg! | Dihedral angle target (hard) |
Units: ang (Angstrom), bohr, deg (degrees), rad (radians).
Penalty Tuning
| Syntax | Description |
|---|---|
kbond=value | Bond force constant |
kangle=value | Angle force constant |
kdihedral=value | Dihedral force constant |
k=value | Set all three at once |
Default penalty constants are used if not specified. Hard constraints (!) use
null-space projection instead of quadratic penalties.
Examples
Freeze atom 1:
Constraints freeze_atoms:1
Freeze X component of atom 2:
Constraints freeze_x:2
Bond constraint with custom force constant:
Constraints bond:1-2=1.40ang;kbond=20.0
Angle constraint:
Constraints angle:1-2-3=109.5deg;kangle=2.0
Hard dihedral constraint:
Constraints dihedral:1-2-3-4=180deg!
Combined constraints:
Constraints freeze_atoms:1;bond:1-2=1.10ang!;k=0.5
Notes
- Multiple clauses are joined by
;. - Hard constraints (
!) are enforced via null-space projection rather than soft quadratic penalties. - Constraint indices are 1-based, matching the atom order in the
GEOMETRYsection. - Frozen atoms/components zero the corresponding gradient/step components.