## automodel.nonstd_restraints() — add restraints on ligands

`nonstd_restraints(aln)`

> This method is called automatically by `automodel` after it generates the standard protein restraints. It adds restraints to keep non-standard residues (anything treated as a HETATM or BLK residue, such as ligands or metal ions) in a reasonable conformation. You can override this method if you need to change these restraints.

> By default, four sets of restraints are built:

- For each residue that has no defined topology (generally BLK residues, used to transfer ligands directly from templates, as described in Section 2.2.1), intra-residue distances are all constrained to their template values. This causes each residue to behave as a rigid body.
- Inter-residue distances are constrained to template values if these are 7Å or less. This has the effect of preserving multiple-HETATM structures such as DNA chains. If the distances are 2.3Å or less they are assumed to be bonds and so are restrained more strongly and also excluded from the nonbonded list.
- Residue-protein atom distances are strongly constrained to template values (and excluded from the nonbonded list) if these are 2.3Å or less. This preserves chemical bonds between ligands and the protein.
- Residue-protein Cα distances are constrained to template values if these are 10Å or less and are not already bonded by the previous restraints. This preserves the ligand position.