The challenge of managing molecular complexity is a common hurdle for modelers. Knowing how to effectively filter and target structural groups using clear specifications is an invaluable skill when working with molecular design platforms like SAMSON. This blog post explores structuralGroup attributes in SAMSON’s Node Specification Language (NSL), helping you streamline your modeling tasks with precision. If you’re aiming to make sense of attributes like numberOfAtoms or formalCharge, you’re in the right place!
Why Structural Group Attributes Matter in Molecular Modeling
Imagine you are working with a massive molecular structure and need to isolate specific groups for analysis—a critical step for tasks like charge distribution studies or atom-specific property adjustments. Structural group attributes in NSL allow you to define precise criteria to help with filtering nodes according to their properties, saving both time and effort.
Attributes at a Glance
The structuralGroup attributes provide a robust set of options for customizing node filters, both through inherited node attributes and dedicated structuralGroup properties. Below are some of the key attributes you can utilize:
- Inherited Attributes:
visible(sg.v): Filters based on a node’s visibility state.selected(sg.selected): Identifies nodes currently selected in the interface.name(sg.n): Allows filtering by group names like “L*” to match a pattern.
- Structural Group Specific Attributes:
formalCharge(sg.fc): Matches groups with a total formal charge.numberOfAtoms(sg.nat): Filters by the number of atoms in a group (e.g.,sg.nat 10:200).partialCharge(sg.pc): Targets groups with specific partial charge ranges.
Practical Examples
Here's how to use these attributes effectively:
- If you're looking to analyze groups with more than 100 atoms, use:
sg.nat > 100 - To identify structural groups with a formal charge between 6 and 8, input:
sg.fc 6:8 - When filtering visible structural groups, try:
sg.v. To exclude visible groups, usenot sg.v - For precision across different parameters, you can even combine expressions. For example:
sg.nat < 50 and sg.pc > 1.5
Visual Example
Below is an illustration derived from SAMSON's documentation showing some attributes:

Conclusion
The rich set of structuralGroup attributes in NSL simplifies targeting molecular groups, enabling more efficient modeling workflows. Whether you need to isolate groups matching specific formal charges or assess atom counts, understanding these attributes will transform how you interact with molecular data. To learn more about structural group attributes and dive deeper into their full potential, explore the original documentation.
Note: SAMSON and all SAMSON Extensions are free for non-commercial use. Start exploring molecular modeling today by downloading SAMSON.
