Back to main menu

Option: rotate

Syntax

-rotate [com] <x|y|z> <θ>

-rotate [com] [hkl] <θ>

-rotate [com] <vx> <vy> <vz> <θ>

Description

This option allows to rotate the system (i.e. both the box and atoms) around a given axis.

The axis of rotation can be one of 'x', 'y', 'z' (referring to cartesian axes), or a crystallographic direction defined by its Miller indices (see how to specify Miller indices). If the crystallographic orientation of the system is defined (e.g. through the option -properties) then the Miller indices are considered with respect to that orientation. Otherwise the orientation assumed is X=[100], Y=[010], Z=[001]. It is also possible to give any other direction by entering the Cartesian coordinates of a vector (vx vy vz) in angströms. The angle of rotation θ must be provided in degrees.

If the keyword "com" is used, then the center of rotation is the center of mass of the system. Otherwise (i.e. if the keyword is omitted), the center of rotation is the Cartesian origin (0,0,0).

If forces (fx,fy,fz) or velocities (vx,vy,vz) exist as auxiliary properties, then they are rotated accordingly.

This option affects some properties of the system (e.g. the elastic tensor) if they were read with the option -properties before the present option.

If a selection was defined (with the option -select) then the rotation is applied only to selected atoms, and the box is not rotated. If the keyword "com" is used, then the selected atoms are rotated around their center of mass.

After the application of this option, some atoms may end up out of the box, which can be fixed thanks to the option -wrap.

Default

By default the system is not rotated.

Examples

Back to main menu