Delete Cr-rich regions in a CoNiCrFe equiatomic alloy

Dear all,

I have a crystal structure consisting of 4 atom types (Cr, Ni, Fe, and Co). I want use Ovito to delete all the regions where there is a high concentration of Cr (type 1) atoms (Cr-rich regions). Other atom types in the Cr-rich regions should also be deleted. I have tried to use python to accomplish this. However, on running the script, I received an error that ‘ovito.modifiers.ConstructSurfaceModifier’ object has no attribute ‘region_type’. What is the simplest way to accomplish this?


Here is a possible workflow for OVITO Basic to find and delete Cr-rich regions:

  1. Use the Select Type modifier to select all Cr atoms.

  2. For each selected atom, the Compute Property modifier can help you count the number of Cr neighbors within a spherical cutoff. Please also see section Including neighbor particles in the calculation in the linked manual article.
    Possible modifier settings to calculate the local atomic concentration of Cr:
        :white_check_mark: Compute only for selected elements
        Expression: 1/(NumNeighbors+1)
        Neighbor expression: Selection/(NumNeighbors+1)
        (adapt the cutoff radius to your needs)

  3. The Expression Selection Modifier then lets you select Cr atoms based on the concentration values you calculated in the previous step.

  4. Include neighboring atoms in the selection by adding an Expand Selection modifier to the pipeline.

  5. Delete the particles from the scene with a Delete Selected modifier.

Thank you very much for your help. However, it appears that all the Cr atoms are selected (even those located outside the Cr-rich regions) irrespective of the cutoff radius I use in the “Compute Property” modifier. Perhaps there is something I am not doing right.

I appreciate your support greatly!

What’s the boolean expression you use in step 3?

I use “Myproperty” which was set in the previous steps (“Compute Property” modifier).

You should change it to Myproperty > X, where X is your criterion of a high concentration value.

If you only enter “Myproperty” in the text editor, the expression always evaluates to True for a Cr atom, because the Myproperty values for Cr atoms range in between 1/(NumNeighbors+1) to 1.

I see. Thanks.