How to find the plane of orientation

I have run a simulation in LAMMPS after which I am getting a FCC crystal structure and a HCP crystal structure. I want to find the plane of orientation of HCP crystal structure. Is there any way I can find it. I am using OVITO as a visualization software.

Interesting question. There should be a fairly simple way to obtain this information for each atom, based on its neighborhood, but I don’t know what it is. LAMMPS does allow you to compute a set of bond-orientational order parameters:

Unfortunately for you, these quantities are rotationally invariant. In other words, the information you seek has already been averaged out by first summing the spherical harmonics Y_{lm} over m for each l. If you went into the LAMMPS code, you could have it print out the unaveraged Y_{lm}. In fact, there exist commented lines of code that do just that in compute_orientorder_atom.cpp:

for(int m = 0; m < 2*n+1; m++) {
qm_sum += qnm_r[iw][m]*qnm_r[iw][m] + qnm_i[iw][m]*qnm_i[iw][m];
// printf(“Ylm^2 = %d %d %g\n”,n,m,
// qnm_r[iw][m]*qnm_r[iw][m] + qnm_i[iw][m]*qnm_i[iw][m]);

You would then need to perform some kind of operation on a suitable set of Y_{lm} to extract the axis normal to the basal plane. This is beyond the ability of most users of OVITO.