Using the Elemental Composition Method
In order to calculate the molecular weight of a molecule, this method is used to describe its elemental composition.
The advantages of this method (as opposed to setting the molecular weight by a constant) are that:
- The molecular weight is automatically updated when you change the composition of the molecule; and,
- No round-off is applied to the result. Using the constant method for molecular weight incurs a round-off to the second decimal place.
The constant method is still provided for use with those materials that do not have an elemental composition (such as air), and also to provide backwards compatibility with simulations created in earlier versions of STAR-CCM+.
The Elemental Composition Method node contains a single child node, Atoms, that is used to manage the individual substances that make up the molecule.

In most instances, the Atoms node is populated automatically based on information that is contained in the materials property database. It is, however, possible to populate this node manually.
Populating the Composition
Individual substances are added to the composition by right-clicking on the Atoms node and choosing New Atom from the pop-up menu.

Choosing New Atom opens the Add atom to elemental composition dialog, which you can use to set the substance and its quantity in the molecule. A list of available substances is provided in the drop-down menu, and an entry box accepts the number of atoms of the chosen substance

Clicking OK completes the specification and add a corresponding Atom child node to the Atoms manager node.
Removing Substances
Substances can be removed from the composition by right-clicking on their respective Atom nodes and choosing Delete.