Obtain the lowest energy of a bicrystal with surfaces

Dear all users,

I constructed an orthogonal bicrystal with periodic boundary conditions(BC) in the two
directions in the plane of the grain boundary (x and z directions), and non-periodic BC (f)
in the normal direction of grain boundary (y direction). Two free surfaces, respectively at the
top and bottom of the bicrystal along y direction, are created. Now I want to obtain the lowest
energy of the grain boundary located in the middle of the bicrystal at 0 K and with pressures
(Pxx, Pyy and Pzz) being 0.0 bar. In the case of a bicrystal with ppp BC, in order to obtain
the lowest energy of the grain boundary, we often minimize the energy of bicrystal with “minimize”
command, and then use “fix box/relax” coupled with “minimize” to perform minimization.
Here, I referred to this method and tried as follows:

Step 1: use “fix aveforce 0.0 0.0 0.0”to enforce the block of atoms at each surface to move as
        a single block, and then use“minimize” to perform an energy minimization of the whole system.
Step 2: considering the non-periodic BC in y direction, I use “fix 1 all box/relax x 0.0 z 0.0 vmax 0.0001 ”
         to relax the system, and then “minimize” it with “fix aveforce 0.0 0.0 0.0”.

Because the non-periodic condition in y direction does not allow this dimension (Ly) to change,
and the target pressure (Pyy = 0.0) to be specified during relaxation, i got fixed Ly and quite
large Pyy after Step 2. Meanwhile, Lx and Lz changes with time, and the final pressures of these
two directions are quite close to 0.0 bar. As the doc introduced, atoms will rescale to new positions
during relaxation and minimization. (1) So do atoms just rescale along x and z directions in Step 2?
(2) If yes, is that just why the Pxx and Pzz will relax to the target values while the Pyy can not?

If both assumptions are right, then i wonder is there a way that will allow atoms to rescale along y
direction and thus the Pyy can relax to 0.0 bar in Step 2? If it is impossible to find such a way,
does it just mean that the “fix box/relax” can’t be used to obtain the lowest energy of grain boundary
in the case of pfp bicrystal ?

I sincerely appreciate any suggestion. Thanks in advance.
Sincerely, Yang

This comand:
fix 1 all box/relax x 0.0 z 0.0 vmax 0.0001

will only allow the box to change in x,z, so
no box change in y, and no rescaling of atoms in

y either.

However, the 2 crystals should be free to move
in y due to the non-periodicity in y. Do the 2 crystals
move apart (or closer together) during the minimization?

You could do a compute group/group between
the 2 crystals and monitor the force between
them during the minimization. I am guessing
the y-force between the 2 crystals goes to 0.0

You may be getting a large Pyy b/c the 2 crystals
are frozen (in y) and thus whatever initial Pyy there
is, is effectively locked in.

A more typical way to minimize a GB is to
let the 2 crystals relax, i.e. dont use fix aveforce.

Steve

Dear Steve,

Thanks for your quick comments. Sorry for my late response.
Please take a loook at the below reponse.

This comand:
fix 1 all box/relax x 0.0 z 0.0 vmax 0.0001

will only allow the box to change in x,z, so
no box change in y, and no rescaling of atoms in
y either.

However, the 2 crystals should be free to move
in y due to the non-periodicity in y. Do the 2 crystals
move apart (or closer together) during the minimization?

Sorry, Steve. I don’t know how to monitor this by “thermo” output. I tried to use ylo and yhi to monitor
the movement, but they just kept fixed during the minimization. Would you please give me some suggestion on this?

You could do a compute group/group between
the 2 crystals and monitor the force between
them during the minimization. I am guessing
the y-force between the 2 crystals goes to 0.0

As you guessed, the y-force goes to 0.0 for both cases, in which the fix aveforce is used or not. I also
found x-force and z-force go to 0.0. What’s the implication of “y-force = 0.0” here? Does it just imply
non-interaction in y between the two crystals? It seems to me that y-force and Pyy are independent of each
other. Because no matter the Pyy is quite large (fix aveforce is used) or zero (fix aveforce is not used),
we all get “y-force = 0.0”.

You may be getting a large Pyy b/c the 2 crystals
are frozen (in y) and thus whatever initial Pyy there
is, is effectively locked in.

A more typical way to minimize a GB is to
let the 2 crystals relax, i.e. dont use fix aveforce.

According to your advice, I tried to perform minimization without “fix aveforce” in Step 1 and 2.
During the first minimization in Step 1, Pyy will finally reach 0.0 from the initial large value.
## First minimization
   min_style cg
   min_modify line quadratic
##Output in logfile:
Step PotEng Lx Ly Press Pxx Pyy y-force
  0 -24329.021 22.262435 155.83704 1047.863 -5251.9654 14605.831 577.33581
100 -24576.967 22.262435 155.83704 -2270.959 -3039.6101 218.57311 0.29141314
200 -24576.986 22.262435 155.83704 -2642.6272 -3631.0645 6.2472344 0.0034134358
300 -24611.165 22.262435 155.83704 -11063.061 -8987.284 -13514.349 -5.6269898
400 -24614.158 22.262435 155.83704 -779.11877 -2000.3801 1665.8347 1.0874956
500 -24614.379 22.262435 155.83704 -2005.4378 -2999.5924 19.48554 -0.026845677
600 -24614.38 22.262435 155.83704 -2034.7956 -3039.2234 -4.6754331 0.0022519055
700 -24614.38 22.262435 155.83704 -2029.3321 -3030.9997 -1.0282886 -0.0031207622
800 -24614.38 22.262435 155.83704 -2029.4196 -3032.8674 0.57499415 0.00056941073
900 -24614.38 22.262435 155.83704 -2029.5231 -3032.3977 -0.10514983 -0.0001646924

When the “fix aveforce” is not used, we get two free surfaces in y, i.e. the two crystals are not frozen in y.
It seems that, compared with the periodic conditions in x and z, the free surfaces in y allow atoms much easier
(maybe totally free) to rescale in y, and thus much easier to relax the Pyy to zero. Is it right?

I don’t know the answers to your various Qs. Maybe Aidan will

have some ideas (CCd). I suggest you run the simplest problem

first which is no fix aveforce and let the atoms relax in y as they
wish to. B/c that boundary is non-periodic I don’t think there is
any guarantee that Pyy will go to zero, especially if you are controlling

the x,z box lengths with a barostat.

Steve

If you perform energy minimization on a system that is periodic in x and z, and non-periodic in y, and there are no external constraints (such as fix aveforce), then all the forces will be converged close to zero. Despite this, the stress tensor components will not generally be zero, because of interactions between periodic images. However, in the non-periodic y direction, things are more straightforward: VPyy ~ Sum(RiyFiy) = 0. So, if you fully converge Steps 1 and 2 without fix aveforce, you should get Pyy to be small.

I don’t understand why Pyy will experience a sudden increase at the beginning (of Step 2)

Because you change Lx, this changes Pyy. If you fully converge all the forces, Pyy will return to zero, regardless of Lx.

Dear Aidan and Steve,

Thanks for your informative comments.

You clarify that:
(1) for the bicrystal with pfp boundary conditions, if its energy is minimized with “fix aveforce”
    to impose external constrains in Steps 1 and 2, then we will get large Pyy because atoms are
     not allowed to rescale in y direction.
(2) if the energy is minimized without “fix aveforce”, and all the forces in the system are fully
     converged, then we can get the Pyy to be small or zero.

Sincerely, Yang