Program Library

- Provenance of code.
- Purpose of code.
- Specification.
- Description of subroutine's operation.
- References.
- Parameter descriptions.
- Error indicators.
- Accuracy estimate.
- Any additional information.
- Example of code
- Auxiliary subroutines required.
- Keywords.
- Download source code.
- Links.

H.K.D.H. Bhadeshia,

Phase Transformations Group,

Department of Materials Science and Metallurgy,

University of Cambridge,

Cambridge, U.K.

To calculate the coordinate transformation matrix relating two crystals of arbitrary structure.

Language: | FORTRAN |

Product form: | Source code |

SUBROUTINE MAP_CRYSTAL_CORD(H1, K1, L1, JR1, H2, K2, L2, JR2, H4, K4, L4, JR4,

& H5, K5, L5, JR5, C, D, G1, G2)

REAL H1, K1, L1, H2, K2, L2, H4, K4, L4, H5, K5, L5, C(9), D(9), G1(9), G2(9)

INTEGER JR1, JR2, JR4, JR5

MAP_CRYSTAL_CORD calculates the coordinate transformation matrix relating two crystals of arbitrary structure, from data consisting of a pair of vectors (real or reciprocal) from each crystal. The pair from one crystal must be parallel to that from the other crystal. This is useful in studying the orientation relationships between crystals.

The two crystals are called Crystal 1 and Crystal 2. The two vectors associated with each crystal are known as Vector 1 and Vector 2.

- H.K.D.H. Bhadeshia, Worked Examples in the Geometry of Crystals, Institute of Materials, London, 1987.
- H.K.D.H. Bhadeshia, chapter on crystallography in Microstructural Characterisation of High Temperature Materials, ed. E. Metcalfe, Institute of Metals, London, 1988.

**H1, K1, L1**- reals- [H1,K1,L1] is Vector 1 of Crystal 1.
**JR1**- integer- JR1 = 0 if [H1,K1,L1] is in real space, 1 if it is in reciprocal
space.
**H2, K2, L2**- reals- [H2,K2,L2] is Vector 2 of Crystal 1.
**JR2**- integer- JR2 = 0 if [H2,K2,L2] is in real space, 1 if it is in reciprocal space.
**H4, K4, L4**- reals- [H4,K4,L4] is Vector 1 of Crystal 2. It must be parallel to
[H1,K1,L1].
**JR4**- integer- JR4 = 0 if [H4,K4,L4] is in real space, 1 if it is in reciprocal
space.
**H5, K5, L5**- reals- [H5,K5,L5] is Vector 2 of Crystal 2. It must be parallel to
[H2,K2,L2].
**JR5**- integer- JR5 = 0 of [H5,K5,L5] is in real space, 1 if it is in reciprocal
space.
**G1**- real array of dimension 9- G1 is the metric tensor for Crystal 1.
**G2**- real array of dimension 9- G2 is the metric tensor for Crystal 2.

**D**- real array of dimension 9- D is the coordinate transformation matrix.
**C**- real array of dimension 9- C is the inverse of D.

None.

No information supplied.

None.

REAL H1, K1, L1, H2, K2, L2, H4, K4, L4, H5, K5, L5 REAL G1(9), G2(9), C(9), D(9) INTEGER JR1, JR2, JR4, JR5 READ (5,*) H1, K1, L1, JR1 READ (5,*) H2, K2, L2, JR2 READ (5,*) H4, K4, L4, JR4 READ (5,*) H5, K5, L5, JR5 CALL MAP_CRYSTAL_CORD(H1, K1, L1, JR1, H2, K2, L2, JR2, H4, K4, L4, & JR4,H5, K5, L5, JR5, C, D, G1, G2) WRITE (6,1) (D(I), I=1,9) WRITE (6,2) WRITE (6,1) (C(I), I=1,9) 1 FORMAT (5X,3F8.4) 2 FORMAT ('The inverse is ') STOP END

None supplied.

None supplied.

MAP_UTIL_MAGG

MAP_UTIL_PROD

MAP_UTIL_INVERS

MAP_UTIL_CROSS

transformation matrix, parallel

**
MAP originated from a joint project of the National Physical Laboratory and the University of Cambridge.
**