The transformation matrix
The transformation matrix P = (P, p) relating two coordinate systems
with basis vectors (a, b, c) and (a', b', c') has two parts:
 The linear part: P
 The origin shift: p
The new basis vectors (a', b', c') are related with the basis vectors (a, b, c) by
a' = P_{11}a + P_{21}b + P_{31}c

b' = P_{12}a + P_{22}b + P_{32}c

c' = P_{13}a + P_{23}b + P_{33}c

And if the new origin has the coordinates (p_{1}, p_{2}, p_{3})
in the coordinate system with basis vectors (a, b, c), then
 the linear part (P) of the transformation matrix is:
P = 

P_{11}  P_{12}  P_{13} 
P_{21}  P_{22}  P_{23} 
P_{31}  P_{32}  P_{33} 


 the origin shift (p) is:
This transformation can be written in the following way:
(a', b', c') = (a, b, c)(P, p)
Example:
a' = b;
b' = c + 1/4;
c' = a + 1/4
The first column of the linear part of the transformation matrix is (0 1 0)
and the first element of the origin shift is 0.
The second column of the linear part of the transformation matrix is (0 0 1)
and the second element of the origin shift is 1/4 (or 0.25).
The third column of the linear part of the transformation matrix is (1 0 0)
and the third element of the origin shift is 1/4 (or 0.25).
The matrix form of the transformation can be written in the following way:
 The linear part of the transformation matrix:
P = 



 The origin shift:
abc and xyz matrix notations
A (3x4) transformation matrix (P,p) with linear part P and the origin shift p can be represented by using the concise form:
P_{11}a+P_{21}b+P_{31}c,P_{12}a+P_{22}b+P_{32}c,P_{13}a+P_{23}b+P_{33}c; p_{1},p_{2},p_{3}
where it is understood that the abc entries should be read in columns.
As an example, a transformation matrix given as
2/3a1/3b+2/3c,b,2a+b; 1/6,1/3,1/3
can be written as:
(P, p) = 

2/3  0  2  1/6 
1/3  1  1  1/3 
2/3  0  0  1/3 


On the Bilbao Crystallographic Server, we also use the xyz notation likewise to represent transformation matrixes. But, this time, it should be interpreted in rows. Therefore, the example matrix above would be represented in the xyz notation as:
2/3x+2z,1/3xy+z,2/3x; 1/6,1/3,1/3
This time we used the concise form:
P_{11}x+P_{21}y+P_{31}z,P_{12}x+P_{22}y+P_{32}z,P_{13}x+P_{23}y+P_{33}z; p_{1},p_{2},p_{3}
Euler angles
According to Euler's rotation theorem, any rotation can be discribed using three angles (θ, φ, Ψ).
A general rotation can be written as:
[*] For more information: International Tables for Crystallography. Vol. A, Space Group Symmetry.
Ed. Theo Hahn (3rd ed.), Dordrecht, Kluwer Academic Publishers,
Section "Transformations in crystallography", 1995.