aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2021-02-15 15:18:25 +0100
committerThomas White <taw@physics.org>2021-02-15 15:18:25 +0100
commit256775aceb2ba11a764768982d7c84d9683c3dd9 (patch)
treeeee61cca8f1b20c4fdadfbc5ea65722fcd97328a
parent09e71ff37379f6827a50a0e2d4ec26971af2b00c (diff)
GUI: Complete the symmetry lookup table for export
-rw-r--r--src/gui_export.c187
1 files changed, 162 insertions, 25 deletions
diff --git a/src/gui_export.c b/src/gui_export.c
index a4e07577..b79d7518 100644
--- a/src/gui_export.c
+++ b/src/gui_export.c
@@ -77,37 +77,174 @@ struct point_group_conversion
};
+/* Table for converting CrystFEL's knowledge about centering, point group
+ * and unique axis into something that can be recognised by external programs.
+ * If xds_spgnum=0, ccp4=NULL, or something is missing form this table entirely,
+ * it means that there is no way to represent the situation to that program
+ * without re-indexing the dataset. */
struct point_group_conversion pg_conversions[] = {
- /* Triclinic */
- {'P', "1", 0, 1, "P 1"},
+ /* Triclinic */
+ {'P', "1", 0, 1, "P 1"},
+ {'P', "-1", 1, 1, "P 1"},
/* Monoclinic */
- {'P', "2_uaa", 0, 0, "P211"},
- {'P', "2/m_uaa", 1, 0, "P211"},
- {'P', "2_uab", 0, 3, "P121"},
- {'P', "2/m_uab", 1, 3, "P121"},
- {'P', "2_uac", 0, 0, "P112"},
- {'P', "2/m_uac", 1, 0, "P112"},
- {'P', "2", 0, 0, "P121"}, /* unique axis c */
- {'P', "2/m", 1, 0, "P121"}, /* unique axis c */
-
- {'C', "2_uaa", 0, 0, "C211"},
- {'C', "2/m_uaa", 1, 0, "C211"},
- {'C', "2_uab", 0, 5, "C121"},
- {'C', "2/m_uab", 1, 5, "C121"},
- {'C', "2_uac", 0, 0, "C112"},
- {'C', "2/m_uac", 1, 0, "C112"},
- {'C', "2", 0, 0, "C121"}, /* unique axis c */
- {'C', "2/m", 1, 0, "C121"}, /* unique axis c */
+ {'P', "2_uaa", 0, 0, "P211"},
+ {'P', "m_uaa", 0, 0, "Pm11"},
+ {'P', "2/m_uaa", 1, 0, "P211"},
+ {'P', "2_uab", 0, 3, "P121"},
+ {'P', "m_uab", 0, 0, "P1m1"},
+ {'P', "2/m_uab", 1, 3, "P121"},
+ {'P', "2_uac", 0, 0, "P112"},
+ {'P', "m_uac", 0, 0, "P11m"},
+ {'P', "2/m_uac", 1, 0, "P112"},
+ {'P', "2", 0, 0, "P121"}, /* unique axis c */
+ {'P', "m", 0, 0, "P11m"}, /* unique axis c */
+ {'P', "2/m", 1, 0, "P121"}, /* unique axis c */
+
+ {'A', "2_uab", 0, 0, "A121"},
+ {'A', "m_uab", 0, 0, "A1m1"},
+ {'A', "2/m_uab", 1, 0, "A121"},
+ {'A', "2_uac", 0, 0, "A112"},
+ {'A', "m_uac", 0, 0, "A11m"},
+ {'A', "2/m_uac", 1, 0, "A112"},
+ {'A', "2", 0, 0, "A121"}, /* unique axis c */
+ {'A', "m", 0, 0, "A11m"}, /* unique axis c */
+ {'A', "2/m", 1, 0, "A121"}, /* unique axis c */
+
+ {'B', "2_uaa", 0, 0, "B211"},
+ {'B', "m_uaa", 0, 0, "Bm11"},
+ {'B', "2/m_uaa", 1, 0, "B211"},
+ {'B', "2_uac", 0, 0, "B112"},
+ {'B', "m_uac", 0, 0, "B11m"},
+ {'B', "2/m_uac", 1, 0, "B112"},
+ {'B', "2", 0, 0, "B112"}, /* unique axis c */
+ {'B', "m", 0, 0, "B11m"}, /* unique axis c */
+ {'B', "2/m", 1, 0, "B112"}, /* unique axis c */
+
+ {'C', "2_uaa", 0, 0, "C211"},
+ {'C', "m_uaa", 0, 0, "Cm11"},
+ {'C', "2/m_uaa", 1, 0, "C211"},
+ {'C', "2_uab", 0, 5, "C121"},
+ {'C', "m_uab", 0, 0, "C1m1"},
+ {'C', "2/m_uab", 1, 5, "C121"},
+
+ {'I', "2_uaa", 0, 0, "I211"},
+ {'I', "m_uaa", 0, 0, "Im11"},
+ {'I', "2/m_uaa", 1, 0, "I211"},
+ {'I', "2_uab", 0, 0, "I121"},
+ {'I', "m_uab", 0, 0, "I1m1"},
+ {'I', "2/m_uab", 1, 0, "I121"},
+ {'I', "2_uac", 0, 0, "I112"},
+ {'I', "m_uac", 0, 0, "I11m"},
+ {'I', "2/m_uac", 1, 0, "I112"},
+ {'I', "2", 0, 0, "I121"}, /* unique axis c */
+ {'I', "m", 0, 0, "I11m"}, /* unique axis c */
+ {'I', "2/m", 1, 0, "I121"}, /* unique axis c */
/* Orthorhombic */
- {'P', "222", 0, 16, "P222"},
- {'P', "mmm", 1, 16, "P222"},
- {'C', "222", 0, 21, "C222"},
- {'C', "mmm", 1, 21, "C222"},
-
- /* FIXME: Complete this list. Ugh. */
+ {'P', "222", 0, 16, "P222"},
+ {'P', "mmm", 1, 16, "P222"},
+ {'P', "mm2", 0, 25, "Pmm2"},
+ {'A', "222", 0, 0, "A222"},
+ {'A', "mmm", 1, 0, "A222"},
+ {'A', "mm2", 0, 38, "Amm2"},
+ {'B', "222", 0, 0, "B222"},
+ {'B', "mmm", 1, 0, "B222"},
+ {'B', "mm2", 0, 0, "Bmm2"},
+ {'C', "222", 0, 21, "C222"},
+ {'C', "mmm", 1, 21, "C222"},
+ {'C', "mm2", 0, 35, "Cmm2"},
+ {'F', "222", 0, 22, "F222"},
+ {'F', "mmm", 1, 22, "F222"},
+ {'F', "mm2", 0, 42, "Fmm2"},
+ {'I', "222", 0, 23, "I222"},
+ {'I', "mmm", 1, 23, "I222"},
+ {'I', "mm2", 0, 45, "Imm2"},
+
+ /* Tetragonal */
+ {'P', "4", 0, 75, "P4"}, /* unique axis c */
+ {'P', "4/m", 1, 75, "P4"}, /* unique axis c */
+ {'P', "422", 0, 89, "P422"}, /* unique axis c */
+ {'P', "4/mmm", 1, 89, "P422"}, /* unique axis c */
+ {'P', "4mm", 0, 99, "P4mm"}, /* unique axis c */
+ {'P', "-4", 0, 81, "P-4"}, /* unique axis c */
+ {'P', "-42m", 0, 111, "P-42m"}, /* unique axis c */
+ {'P', "-4m2", 0, 115, "P-4m2"}, /* unique axis c */
+ {'P', "4_uac", 0, 75, "P4"},
+ {'P', "4/m_uac", 1, 75, "P4"},
+ {'P', "422_uac", 0, 89, "P422"},
+ {'P', "4/mmm_uac", 1, 89, "P422"},
+ {'P', "4mm_uac", 0, 99, "P4mm"},
+ {'P', "-4_uac", 0, 81, "P-4"},
+ {'P', "-42m_uac", 0, 111, "P-42m"},
+ {'P', "-4m2_uac", 0, 115, "P-4m2"},
+ {'I', "4", 0, 79, "I4"}, /* unique axis c */
+ {'I', "4/m", 1, 79, "I4"}, /* unique axis c */
+ {'I', "422", 0, 97, "I422"}, /* unique axis c */
+ {'I', "4/mmm", 1, 97, "I422"}, /* unique axis c */
+ {'I', "4mm", 0, 107, "I4mm"}, /* unique axis c */
+ {'I', "-4", 0, 82, "I-4"}, /* unique axis c */
+ {'I', "-42m", 0, 121, "I-42m"}, /* unique axis c */
+ {'I', "-4m2", 0, 119, "I-4m2"}, /* unique axis c */
+ {'I', "4_uac", 0, 79, "I4"},
+ {'I', "4/m_uac", 1, 79, "I4"},
+ {'I', "422_uac", 0, 97, "I422"},
+ {'I', "4/mmm_uac", 1, 97, "I422"},
+ {'I', "4mm_uac", 0, 107, "I4mm"},
+ {'I', "-4_uac", 0, 82, "I-4"},
+ {'I', "-42m_uac", 0, 121, "I-42m"},
+ {'I', "-4m2_uac", 0, 119, "I-4m2"},
+
+ /* Trigonal (rhombohedral) */
+ {'R', "3_R", 0, 0, "R3:R"},
+ {'R', "-3_R", 1, 0, "R3:R"},
+ {'R', "32_R", 0, 0, "R32:R"},
+ {'R', "-3m_R", 1, 0, "R32:R"},
+ {'R', "3m_R", 0, 0, "R3m:R"},
+
+ /* Trigonal (rhombohedral on hexagonal axes) */
+ {'H', "3_H", 0, 146, "R3:H"},
+ {'H', "-3_H", 1, 146, "R3:H"},
+ {'H', "32_H", 0, 155, "R3:H"},
+ {'H', "-3m_H", 1, 155, "R3:H"},
+ {'H', "3m_H", 0, 0, "R3m:H"},
+
+ /* Trigonal (hexagonal) */
+ {'P', "3_H", 0, 143, "P3"},
+ {'P', "-3_H", 1, 143, "P3"},
+ {'P', "312_H", 0, 149, "P312"},
+ {'P', "-31m_H", 1, 149, "P312"},
+ {'P', "321_H", 0, 150, "P321"},
+ {'P', "-3m1_H", 1, 150, "P321"},
+ {'P', "3m1_H", 0, 156, "P3m1"},
+ {'P', "31m_H", 0, 157, "P31m"},
+
+ /* Hexagonal */
+ {'P', "6", 0, 168, "P6"},
+ {'P', "6/m", 1, 168, "P6"},
+ {'P', "622", 0, 177, "P622"},
+ {'P', "6/mmm", 1, 177, "P622"},
+ {'P', "6mm", 0, 177, "P6mm"},
+ {'P', "-6m2", 0, 187, "P-6m2"},
+ {'P', "-62m", 0, 189, "P-62m"},
+
+ /* Cubic */
+ {'P', "23", 0, 195, "P23"},
+ {'P', "m-3", 1, 195, "P23"},
+ {'P', "432", 0, 207, "P432"},
+ {'P', "m-3m", 1, 207, "P432"},
+ {'P', "-43m", 0, 215, "P -4 3 m"},
+ {'I', "23", 0, 197, "I23"},
+ {'I', "m-3", 1, 197, "I23"},
+ {'I', "432", 0, 211, "I432"},
+ {'I', "m-3m", 1, 211, "I432"},
+ {'I', "-43m", 0, 217, "I -4 3 m"},
+ {'F', "23", 0, 196, "F23"},
+ {'F', "m-3", 1, 196, "F23"},
+ {'F', "432", 0, 209, "F432"},
+ {'F', "m-3m", 1, 209, "F432"},
+ {'F', "-43m", 0, 216, "F -4 3 m"},
{'*', NULL, 0, 0, NULL}
};