Skip to content

Geometry constraints and dummy atoms: make them discoverable #306

Closed

Description

@ohlincha

From the 9.0.0 release test (Linux, 2026-10-12). Follow-up to #298 (dummy atoms work). The workflow is clunky:

  • The dummy atom X in the periodic table needs a tooltip ("Dummy atom: no electrons, no basis; for constraints and symmetry").
  • Constraints are reached from the Calculation Editor (Constraints button, only after choosing run type Geometry), which opens the Builder; they belong in the Builder itself (e.g. Tools › Geometry Constraints), usable at any time.
  • Atom selection for a constraint takes Shift+click; Ctrl+click does nothing. Both should work, as elsewhere.
  • After selecting atoms it is not clear that Constrain has to be pressed again in the Geometry Constraints dialog; the dialog should say what to do next and show the constraints made.

Activity

  1. mattasplund commented on Oct 12, 2026

    @mattasplund
    Collaborator

    When I had them write that part for me years ago, it was clunky, but I was happy to have the capabililty. I got used to it, and my labs explained it clearly enough that I had forgotten that it was tricky.
    One additional sanity check that might be nice ...
    When students select an angle or torsion constraint they sometimes pick them in the wrong order; say the center atom first and then the two end atoms. I don't know if the system could hint at selecting them in the correct order.

  2. ohlincha commented on Oct 12, 2026

    @ohlincha
    CollaboratorAuthor

    More from the release test (Andy, 2026-10-12):

    Constraints and run types. Constraints belong to the structure and are defined in the Builder at any time. A calculation uses them only if its run type can (geometry optimisation, GeoVib, scans). Otherwise they are kept with the structure but not used, and ECCE says so: the Calculation Editor shows e.g. "2 constraints defined: used only by geometry optimisations", Verify notes it, and the input writer leaves them out. Switching the run type to Geometry later applies them without setting them again.

    Placing a dummy atom is hard. With X chosen in the Build panel, a single click in empty space does nothing (a single click only adds at an open valence, and NH3 has none); a double click places X at the clicked screen point but at an unrelated depth (here 4.5 Å behind the molecule). Needed: (a) select atoms → "Add dummy atom at their centre" (the centroid of NH3's three H lies on the C3 axis; also ring centroids, bond midpoints); (b) a double click places a new atom at the depth of the molecule's centre.

    The Geometry Constraints dialog for NWChem does not look right — screenshot to follow.

  3. ohlincha commented on Oct 12, 2026

    @ohlincha
    CollaboratorAuthor

    Update: placing X works as expected in an NWChem calculation's Builder (single click puts it where intended). The failed placement above was in an ECCE-QM calculation, and ECCE-QM does not support dummy atoms. Needed there: when the calculation's code cannot use dummy atoms, choosing X in the Builder says so ("ECCE-QM does not support dummy atoms") instead of silently doing nothing on a click and placing the atom at an odd depth on a double click. The centroid tool ("Add dummy atom at the centre of the selection") remains useful but is not urgent.

  4. mattasplund commented on Oct 12, 2026

    @mattasplund
    Collaborator

    The way I would naturally do this would be to treat it as an atom. So, make the N atom tetrahedral, and add an X atom as a terminal atom. This treats it in the most natural way.

  5. ohlincha commented on Oct 13, 2026

    @ohlincha
    CollaboratorAuthor

    In 9.0.1:

    • Geometry constraints are defined in the Builder (Tools › Geometry Constraints…, or right-click on selected atoms) at any run type, and saved with the calculation. The Calculation Editor and Verify say when constraints exist but the run type does not use them.
    • Picked atoms are checked: an angle's centre is the atom bonded to both others, a torsion must be a bonded chain. A wrong but unambiguous order is corrected and shown ("Angle H2–N1–H3 (centre N1)"); atoms not bonded as required are added after confirmation.
    • Ctrl+click adds to the selection.
    • X attaches at an open site like a terminal atom (NH3: on the C3 axis, 1.01 Å from N). For saturated centres such as methane's carbon, Tools › Add Dummy Atom… places X at the centre of the selected atoms, or on the axis through the first picked atom at a chosen distance.
    • NWChem: a fixed atom used to make bond/angle/torsion constraints vanish silently; NWChem cannot combine the two, so it now stops with an error and Verify reports the combination.
    • Help page: Constraints and dummy atoms, with the ammonia potential as the example.

    Known gap: an undo that re-creates atoms drops the constraints on them without a message.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions