[lammps-users] Help using the orient command.

Hello,

I want to create an hcp crystal in different orientations in LAMMPS. By reading the manual, i concluded that orient command may be useful. In defining a custom lattice as follows, an error saying " Illegal lattice command" is flashed.

lattice custom 3.23 &

a1 1.0 0.0 0.0 a2 -0.5 0.866 0.0 a3 0.0 0.0 1.5944 &

basis 0.3333 0.6667 0.2500 basis 0.6667 0.3333 0.7500 &

orient a1 0 1 0 a2 1 0 0 a3 0 0 1

I guess i need to replace a1, a2, a3 in orient with x, y, z. Can someone tell me how exactly should i use this command, say for example i want the plane (2 -1 0) normal to the z- direction.

Just use the lattice hcp style (not custom) and the orient
options to rotate the unit cell with respect to the simulation
box. Read the lattice doc page carefullly and visualize
your results.

Steve

Steve,

I want to generate a crystral structure of the space group P63/mmc. It has two bases atoms positions (1/3, 2/3, 1/4) and (2.3,1/3,3/4). I was trying to do it using the custom lattice option as follows:

lattice custom 3.23 &

a1 1.0 0.0 0.0 a2 -0.5 0.866 0.0 a3 0.0 0.0 1.5944 &

basis 0.3333 0.6667 0.2500 basis 0.6667 0.3333 0.7500

Using hcp will mean that i should use four bases atoms . What do you think is a better option? And if i go for hcp what will be the positions of my bases atoms? And how will i be able to further orient the crystal?

Regards,
Himanshu

You can do it either ways. There is no unique unit cell for lattices. The
lattice doc page describes the basis atoms in each units cell it defines,
but with custom you can do whatever you want.

Steve