Grouping one type of atoms in a region

Hi
I have a question, how can I group one type of atoms in a specified region that has different atom types?
For example, A part of Copper atoms are in a region that oxygen and hydrogen atoms are, too. If I use the below line, LAMMPS groups all (Cu, O, and H) atoms in the specified region not only the Cu atoms that I want.

region Cu3 block 0 90 0 90 26.0 100.0 units box
group Cu3 region Cu3

If I use the below line, LAMMPS group Copper atoms in entire simulation box not that region that I want.

region Cu3 block 0 90 0 90 26.0 100.0 units box
group Cu3 type 3

How can I group only Cu atoms in the Cu3 region?

You have two options:

  • You can create a group that is the intersection of two groups (one would select by region, the other by type). Since (static) group creations are permanent, you can delete the auxiliary groups later.
  • You can define an atom style variable that selects atoms by group and region and then use that to define your group.