symcrys 0.5.0 → 0.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (86) hide show
  1. package/README.md +15 -3
  2. package/dist/crystalClasses.d.ts +222 -0
  3. package/dist/crystalClasses.d.ts.map +1 -0
  4. package/dist/crystalClasses.js +295 -0
  5. package/dist/crystalClasses.js.map +1 -0
  6. package/dist/index.d.ts +11 -9
  7. package/dist/index.d.ts.map +1 -1
  8. package/dist/index.js +6 -8
  9. package/dist/index.js.map +1 -1
  10. package/dist/lattice.d.ts +5 -1
  11. package/dist/lattice.d.ts.map +1 -1
  12. package/dist/lattice.js +3 -1
  13. package/dist/lattice.js.map +1 -1
  14. package/dist/magnetic.d.ts +36 -0
  15. package/dist/magnetic.d.ts.map +1 -0
  16. package/dist/magnetic.js +22 -0
  17. package/dist/magnetic.js.map +1 -0
  18. package/dist/operations.d.ts +10 -0
  19. package/dist/operations.d.ts.map +1 -1
  20. package/dist/operations.js +25 -0
  21. package/dist/operations.js.map +1 -1
  22. package/dist/pointGroups/data.d.ts +36 -1
  23. package/dist/pointGroups/data.d.ts.map +1 -1
  24. package/dist/pointGroups/data.js +29 -21
  25. package/dist/pointGroups/data.js.map +1 -1
  26. package/dist/pointGroups/elements.d.ts +16 -6
  27. package/dist/pointGroups/elements.d.ts.map +1 -1
  28. package/dist/pointGroups/elements.js +7 -2
  29. package/dist/pointGroups/elements.js.map +1 -1
  30. package/dist/pointGroups/magneticData.d.ts +66 -0
  31. package/dist/pointGroups/magneticData.d.ts.map +1 -0
  32. package/dist/pointGroups/magneticData.js +184 -0
  33. package/dist/pointGroups/magneticData.js.map +1 -0
  34. package/dist/pointGroups/magneticSymbols.d.ts +22 -0
  35. package/dist/pointGroups/magneticSymbols.d.ts.map +1 -0
  36. package/dist/pointGroups/magneticSymbols.js +103 -0
  37. package/dist/pointGroups/magneticSymbols.js.map +1 -0
  38. package/dist/pointGroups/pointGroups.d.ts +102 -24
  39. package/dist/pointGroups/pointGroups.d.ts.map +1 -1
  40. package/dist/pointGroups/pointGroups.js +293 -47
  41. package/dist/pointGroups/pointGroups.js.map +1 -1
  42. package/dist/pointGroups/properties.d.ts +25 -16
  43. package/dist/pointGroups/properties.d.ts.map +1 -1
  44. package/dist/pointGroups/properties.js +46 -56
  45. package/dist/pointGroups/properties.js.map +1 -1
  46. package/dist/pointGroups/wyckoff.d.ts +4 -1
  47. package/dist/pointGroups/wyckoff.d.ts.map +1 -1
  48. package/dist/pointGroups/wyckoff.js +6 -2
  49. package/dist/pointGroups/wyckoff.js.map +1 -1
  50. package/dist/siteSymmetry.d.ts +2 -1
  51. package/dist/siteSymmetry.d.ts.map +1 -1
  52. package/dist/siteSymmetry.js.map +1 -1
  53. package/dist/tensors/propertyTable.d.ts +45 -0
  54. package/dist/tensors/propertyTable.d.ts.map +1 -0
  55. package/dist/tensors/propertyTable.js +41 -0
  56. package/dist/tensors/propertyTable.js.map +1 -0
  57. package/dist/tensors/tensorForm.d.ts +21 -10
  58. package/dist/tensors/tensorForm.d.ts.map +1 -1
  59. package/dist/tensors/tensorForm.js +23 -24
  60. package/dist/tensors/tensorForm.js.map +1 -1
  61. package/dist/tensors/tensorProperties.d.ts +30 -0
  62. package/dist/tensors/tensorProperties.d.ts.map +1 -0
  63. package/dist/tensors/tensorProperties.js +44 -0
  64. package/dist/tensors/tensorProperties.js.map +1 -0
  65. package/dist/version.d.ts +6 -2
  66. package/dist/version.d.ts.map +1 -1
  67. package/dist/version.js +6 -2
  68. package/dist/version.js.map +1 -1
  69. package/package.json +6 -2
  70. package/src/crystalClasses.ts +451 -0
  71. package/src/index.ts +32 -38
  72. package/src/lattice.ts +5 -1
  73. package/src/magnetic.ts +88 -0
  74. package/src/operations.ts +31 -0
  75. package/src/pointGroups/data.ts +33 -22
  76. package/src/pointGroups/elements.ts +27 -8
  77. package/src/pointGroups/magneticData.ts +328 -0
  78. package/src/pointGroups/magneticSymbols.ts +110 -0
  79. package/src/pointGroups/pointGroups.ts +388 -65
  80. package/src/pointGroups/properties.ts +47 -56
  81. package/src/pointGroups/wyckoff.ts +17 -2
  82. package/src/siteSymmetry.ts +2 -1
  83. package/src/tensors/propertyTable.ts +89 -0
  84. package/src/tensors/tensorForm.ts +39 -28
  85. package/src/tensors/tensorProperties.ts +50 -0
  86. package/src/version.ts +6 -2
package/README.md CHANGED
@@ -13,9 +13,21 @@ import { operations, symbol, tensorForm } from 'symcrys';
13
13
 
14
14
  symbol('32'); // '321': ITC short symbol of the default setting
15
15
  operations('-3m'); // 12 operations, Cartesian matrices; x ∥ a, z ∥ c
16
- tensorForm('mm2', { rank: 3, parity: 'polar', timeParity: 'i', intrinsic: 'jk' }).parameters;
16
+ tensorForm('mm2', { rank: 3, parity: 'polar', intrinsic: 'jk' }).parameters;
17
17
  // [[0,0,2], [1,1,2], [2,0,0], [2,1,1], [2,2,2]]: xxz, yyz, zxx, zyy, zzz
18
18
  ```
19
19
 
20
- Documentation, conventions (ITC and Birss) and their print sources, and the Python package of the
21
- same version: [github.com/manganite/symcrys](https://github.com/manganite/symcrys).
20
+ `symcrys` is the crystallographic API: the 32 crystal classes, without time reversal. The 122
21
+ magnetic point groups are in `symcrys/magnetic`, under the same function names; there `'32'` is a
22
+ white group, and a crystal without magnetic order has the grey group of its class:
23
+
24
+ ```ts
25
+ import { allowedProperties } from 'symcrys/magnetic';
26
+
27
+ allowedProperties("321'"); // ['piezoelectric', 'gyrotropic']: quartz
28
+ allowedProperties("m'm'2"); // six of the seven names, 'ferromagnetic' among them
29
+ ```
30
+
31
+ Documentation (getting started, conventions, tensors, examples, reference):
32
+ [manganite.github.io/symcrys](https://manganite.github.io/symcrys/). Source, issues and the Python
33
+ package of the same version: [github.com/manganite/symcrys](https://github.com/manganite/symcrys).
@@ -0,0 +1,222 @@
1
+ /**
2
+ * The crystallographic API: the 32 crystal classes, without time reversal. It is what `index.ts`
3
+ * exports. Nothing here mentions time reversal: an operation is its matrix, a tensor has no time
4
+ * parity, and the named properties are those of time-even tensors. A question that involves time
5
+ * reversal (a magnetic point group, a time-odd tensor or property, an operation combined with time
6
+ * reversal) is a RangeError that names the magnetic API (`magnetic.ts`, `symcrys/magnetic`), where
7
+ * the key `'32'` is the white group and a crystal without magnetic order has the grey group of its
8
+ * class (`"321'"`; docs/conventions.md, "Two entry points").
9
+ *
10
+ * Everything is computed by the modules that serve both entry points; this module checks what
11
+ * comes in and leaves time reversal out of what goes back.
12
+ */
13
+ import type { CrystalSystem } from './lattice.js';
14
+ import type { Mat3, Vec3 } from './linalg.js';
15
+ import * as elements from './pointGroups/elements.js';
16
+ import type { Convention, PointGroupKey, Setting, SettingOptions, SymbolOptions } from './pointGroups/pointGroups.js';
17
+ import * as wyckoff from './pointGroups/wyckoff.js';
18
+ import * as site from './siteSymmetry.js';
19
+ import type { TensorPropertyName as MagneticTensorPropertyName } from './tensors/propertyTable.js';
20
+ import type { IntrinsicSymmetry, TensorForm, TensorParity, TensorRank } from './tensors/tensorForm.js';
21
+ /** A point operation: an orthogonal Cartesian matrix (rotation, rotoinversion, mirror, inversion). */
22
+ export interface Operation {
23
+ /** The orthogonal Cartesian 3×3 matrix, rows first. */
24
+ readonly matrix: Mat3;
25
+ }
26
+ /**
27
+ * A crystal class with the properties that are fixed by its operations. None of them depends on
28
+ * the setting or the convention (docs/conventions.md, "Properties").
29
+ */
30
+ export interface PointGroup {
31
+ /** The key (docs/conventions.md, "Keys"). */
32
+ readonly key: PointGroupKey;
33
+ /** The crystal system. */
34
+ readonly crystalSystem: CrystalSystem;
35
+ /** Number of operations. */
36
+ readonly order: number;
37
+ /** Contains the inversion. */
38
+ readonly centrosymmetric: boolean;
39
+ /** Polar (pyroelectric class): some direction is left unchanged by every operation. */
40
+ readonly polar: boolean;
41
+ /** Chiral (enantiomorphic class): proper rotations only. */
42
+ readonly chiral: boolean;
43
+ /** The Laue class: the centrosymmetric crystal class generated by the class and the inversion. */
44
+ readonly laueClass: PointGroupKey;
45
+ }
46
+ /** A crystal class in a given setting. */
47
+ export interface PointGroupInSetting {
48
+ /** The key of the crystal class. */
49
+ readonly key: PointGroupKey;
50
+ /** The 1-based index of the setting. */
51
+ readonly setting: number;
52
+ }
53
+ /** One point operation described geometrically. */
54
+ export type OperationDescription = Omit<elements.OperationDescription, 'timeReversal'>;
55
+ /** The kind of tensor. */
56
+ export interface TensorSpec {
57
+ /** Number of indices, 0 to 4. */
58
+ readonly rank: TensorRank;
59
+ /** `'polar'` or `'axial'`: whether an improper operation changes the sign (factor det R). */
60
+ readonly parity: TensorParity;
61
+ /** The index symmetry of the tensor. */
62
+ readonly intrinsic: IntrinsicSymmetry;
63
+ }
64
+ /**
65
+ * An operation as a caller may pass it: its matrix. `timeReversal: false` is accepted, so that an
66
+ * operation of the magnetic API without time reversal can be handed on from plain JavaScript; with
67
+ * `timeReversal: true` it is refused, at compile time and at run time.
68
+ */
69
+ type OperationArgument = Operation & {
70
+ /** Accepted if false; an operation with time reversal belongs to the magnetic API. */
71
+ readonly timeReversal?: false;
72
+ };
73
+ /** A tensor specification as a caller may pass it; `timeParity: 'i'` is accepted, `'c'` refused. */
74
+ type TensorSpecArgument = TensorSpec & {
75
+ /** Accepted if `'i'`; a time-odd tensor belongs to the magnetic API. */
76
+ readonly timeParity?: 'i';
77
+ };
78
+ /** A named property: the tensor that describes it, what it is and where it is defined. */
79
+ export interface TensorProperty {
80
+ /** The kind of tensor whose non-zero form means that the property is allowed. */
81
+ readonly spec: TensorSpec;
82
+ /** The physical quantity the tensor relates. */
83
+ readonly description: string;
84
+ /** Print source of the definition, with printed page. */
85
+ readonly source: string;
86
+ }
87
+ /** Name of a tensor property in `TENSOR_PROPERTIES`. */
88
+ export type TensorPropertyName = Extract<MagneticTensorPropertyName, 'pyroelectric' | 'ferroaxial' | 'piezoelectric' | 'gyrotropic'>;
89
+ /**
90
+ * The named tensor properties of the crystal classes: those of time-even tensors. `'gyrotropic'`
91
+ * is optical activity. The properties of time-odd tensors (`'ferromagnetic'`, …) are in the
92
+ * magnetic API.
93
+ */
94
+ export declare const TENSOR_PROPERTIES: Readonly<Record<TensorPropertyName, TensorProperty>>;
95
+ export { POINT_GROUP_KEYS } from './pointGroups/pointGroups.js';
96
+ /** True if `key` is the key of one of the 32 crystal classes. */
97
+ export declare function isPointGroupKey(key: string): key is PointGroupKey;
98
+ /** The crystal class with this key. Throws a RangeError for an unknown key. */
99
+ export declare function pointGroup(key: PointGroupKey): PointGroup;
100
+ /** All 32 crystal classes, in the order of `POINT_GROUP_KEYS` (by crystal system, as in ITA). */
101
+ export declare function pointGroups(): readonly PointGroup[];
102
+ /**
103
+ * Finds a crystal class by a Hermann–Mauguin symbol in the given convention (default `'itc'`): the
104
+ * short symbol of a setting, a full symbol, or the key (spaces are ignored). A symbol that names
105
+ * one setting gives that setting; the key, and a short symbol that several settings share (the
106
+ * monoclinic ones: `2` for unique axis b and c), give the default setting of the convention.
107
+ * Returns undefined if nothing matches, also for a value that is not a string and for the
108
+ * symbol of a magnetic group with time reversal. Symbols are written as in this library: `-` for
109
+ * the overbar, also in the Birss convention (`m-3m`, where Birss prints `m3m`; docs/conventions.md,
110
+ * "Where ITC and Birss differ").
111
+ */
112
+ export declare function findPointGroup(hm: string, conventionName?: Convention): PointGroupInSetting | undefined;
113
+ /** The settings of a crystal class, with symbols and the default of the given convention (default `'itc'`). */
114
+ export declare function settings(key: PointGroupKey, conventionName?: Convention): readonly Setting[];
115
+ /**
116
+ * All operations of the crystal class in the requested setting (default: the convention's default
117
+ * setting). ITC convention: in ITA's order, identity first, then as ITA numbers the general
118
+ * position. Birss convention: in birss-app's order (docs/conventions.md, "Order of the
119
+ * operations"). The matrices are Cartesian (docs/conventions.md, "Cartesian frame").
120
+ */
121
+ export declare function operations(key: PointGroupKey, options?: SettingOptions): readonly Operation[];
122
+ /**
123
+ * Generators of the crystal class in the requested setting (docs/conventions.md, "Generators"). ITC
124
+ * convention: ITA's selected generators in printed order, without the identity and ITA's lattice
125
+ * translations, so the list is empty for `1`; for `mm2` settings 2 and 3, which ITA does not list,
126
+ * those of setting 1 carried into their frame. Birss convention: birss-app's generators (for `1`
127
+ * the identity, as in birss-app).
128
+ */
129
+ export declare function generators(key: PointGroupKey, options?: SettingOptions): readonly Operation[];
130
+ /** A symbol of the crystal class in the requested convention and setting. */
131
+ export declare function symbol(key: PointGroupKey, options?: SymbolOptions): string;
132
+ export { holohedry } from './pointGroups/properties.js';
133
+ /**
134
+ * True if the group generated by `operations` contains the inversion, e.g. for the operations of a
135
+ * distorted crystal. A list that is not closed is closed first. For a crystal class, read
136
+ * `pointGroup(key).centrosymmetric`.
137
+ */
138
+ export declare function isCentrosymmetricOf(operations: readonly OperationArgument[]): boolean;
139
+ /**
140
+ * True if the group generated by `operations` is chiral: proper rotations only. For a crystal
141
+ * class, read `pointGroup(key).chiral`. Polar is the named property `'pyroelectric'`:
142
+ * `allowsPropertyOf(operations, 'pyroelectric')`.
143
+ */
144
+ export declare function isChiralOf(operations: readonly OperationArgument[]): boolean;
145
+ /**
146
+ * Each operation of the crystal class described geometrically, in the order of `operations` for
147
+ * the same key and options. Axes are named by the symmetry direction they lie along: in the ITC
148
+ * convention with the sign of ITA Table 2.1.3.1, in the Birss convention signed as birss-app signs
149
+ * them (first non-zero Cartesian component positive); the sign fixes what the sense refers to.
150
+ */
151
+ export declare function describeOperations(key: PointGroupKey, options?: SettingOptions): readonly OperationDescription[];
152
+ /**
153
+ * The positions of the full Hermann–Mauguin symbol in the requested convention and setting, each
154
+ * with its symmetry directions (ITA Table 2.1.3.1) and the symmetry elements along them. All
155
+ * positions of the crystal family are listed, also those the symbol of the class leaves out (then
156
+ * without `symbol`); the triclinic family has none. The directions keep the sign of Table 2.1.3.1
157
+ * in both conventions; in the Birss convention an axis of `describeOperations` may be reversed, so
158
+ * match it to a direction whose dot product with it is ±1, not by identity.
159
+ */
160
+ export declare function symmetryDirections(key: PointGroupKey, options?: SettingOptions): readonly elements.SymmetryDirection[];
161
+ /**
162
+ * The site symmetry of `direction` (any non-zero vector, Cartesian) under `operations`, which may
163
+ * be any list of point operations (for instance those of a distorted crystal). The operations
164
+ * fixing the direction within the tolerance are closed under the products found in the list and
165
+ * the direction is set onto their fixed space, repeated until stable, so that for a group the
166
+ * result is a subgroup and the set direction lies exactly on its elements. For a list that is not a
167
+ * group, `multiplicity` may not be an integer. Throws a RangeError for a zero vector, and if the
168
+ * closed operations fix no common direction (a tolerance far too large, e.g. 0.5).
169
+ */
170
+ export declare function siteSymmetry(operations: readonly OperationArgument[], direction: Vec3, options?: site.SiteSymmetryOptions): site.SiteSymmetry;
171
+ /**
172
+ * The Wyckoff positions of a crystal class for directions, as ITA tabulates them (general position
173
+ * first), in the ITC convention only (docs/conventions.md, "Site symmetry and Wyckoff positions").
174
+ */
175
+ export declare function wyckoffPositions(key: PointGroupKey, options?: SettingOptions): readonly wyckoff.WyckoffPosition[];
176
+ /**
177
+ * The Wyckoff position of a direction (Cartesian) in a crystal class: the position whose site
178
+ * symmetry is conjugate to that of the direction (ITA's definition). `tolerance` as for
179
+ * `siteSymmetry`.
180
+ */
181
+ export declare function wyckoffPositionOf(key: PointGroupKey, direction: Vec3, options?: wyckoff.WyckoffOptions): wyckoff.WyckoffPosition;
182
+ /**
183
+ * The form of a tensor under a crystal class in the requested setting (default: the default
184
+ * setting of the convention, `'itc'` unless given). The tensor is given by its specification or by
185
+ * the name of a property in `TENSOR_PROPERTIES` (`'piezoelectric'`). The convention matters only
186
+ * through the setting: the same setting index gives the same form in both conventions
187
+ * (docs/conventions.md, "Tensors").
188
+ */
189
+ export declare function tensorForm(key: PointGroupKey, spec: TensorSpecArgument | TensorPropertyName, options?: SettingOptions): TensorForm;
190
+ /**
191
+ * The form of a tensor under the group generated by `operations`, e.g. the site symmetry of a
192
+ * surface normal (`siteSymmetry`) or the operations of a distorted crystal. The tensor is given by
193
+ * its specification or by the name of a property in `TENSOR_PROPERTIES`. The operations are
194
+ * Cartesian and orthogonal; a list that is not closed is closed first.
195
+ */
196
+ export declare function tensorFormOf(operations: readonly OperationArgument[], spec: TensorSpecArgument | TensorPropertyName): TensorForm;
197
+ /**
198
+ * The components of `tensor` (length 3^rank, flat index) in a frame rotated by the orthogonal
199
+ * matrix `rotation`: t′_{i…} = f·Σ R_{ia}…R_{…}·t_{a…}, with f = det(R) for an axial tensor and 1
200
+ * for a polar one. To express a tensor in the frame of a surface, pass the matrix whose rows are
201
+ * the new axes in the old frame. The kind of tensor is given by its specification or by the name
202
+ * of a property in `TENSOR_PROPERTIES`.
203
+ */
204
+ export declare function rotateTensor(tensor: readonly number[], rotation: Mat3, specOrName: TensorSpecArgument | TensorPropertyName): number[];
205
+ /**
206
+ * True if the crystal class allows the named property, e.g. `allowsProperty('-6m2',
207
+ * 'piezoelectric')`: the tensor that describes it (`TENSOR_PROPERTIES`) has a non-zero form under
208
+ * the class. Symmetry only allows a property; whether a crystal shows it is a question of the
209
+ * material. It does not depend on setting or convention. Throws a RangeError for an unknown key or
210
+ * name.
211
+ */
212
+ export declare function allowsProperty(key: PointGroupKey, name: TensorPropertyName): boolean;
213
+ /** The named properties the crystal class allows, in the order of `TENSOR_PROPERTIES`. */
214
+ export declare function allowedProperties(key: PointGroupKey): TensorPropertyName[];
215
+ /**
216
+ * True if the group generated by `operations` allows the named property, e.g. for the site
217
+ * symmetry of a surface normal or the operations of a distorted crystal.
218
+ */
219
+ export declare function allowsPropertyOf(operations: readonly OperationArgument[], name: TensorPropertyName): boolean;
220
+ /** The named properties the group generated by `operations` allows. */
221
+ export declare function allowedPropertiesOf(operations: readonly OperationArgument[]): TensorPropertyName[];
222
+ //# sourceMappingURL=crystalClasses.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"crystalClasses.d.ts","sourceRoot":"","sources":["../src/crystalClasses.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAClD,OAAO,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;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
2
+ * The crystallographic API: the 32 crystal classes, without time reversal. It is what `index.ts`
3
+ * exports. Nothing here mentions time reversal: an operation is its matrix, a tensor has no time
4
+ * parity, and the named properties are those of time-even tensors. A question that involves time
5
+ * reversal (a magnetic point group, a time-odd tensor or property, an operation combined with time
6
+ * reversal) is a RangeError that names the magnetic API (`magnetic.ts`, `symcrys/magnetic`), where
7
+ * the key `'32'` is the white group and a crystal without magnetic order has the grey group of its
8
+ * class (`"321'"`; docs/conventions.md, "Two entry points").
9
+ *
10
+ * Everything is computed by the modules that serve both entry points; this module checks what
11
+ * comes in and leaves time reversal out of what goes back.
12
+ */
13
+ import * as elements from './pointGroups/elements.js';
14
+ import * as groups from './pointGroups/pointGroups.js';
15
+ import * as properties from './pointGroups/properties.js';
16
+ import * as wyckoff from './pointGroups/wyckoff.js';
17
+ import * as site from './siteSymmetry.js';
18
+ import { TENSOR_PROPERTIES as ALL_TENSOR_PROPERTIES } from './tensors/propertyTable.js';
19
+ import * as tensors from './tensors/tensorForm.js';
20
+ const USE_MAGNETIC = "the crystallographic API has no time reversal; use the magnetic API ('symcrys/magnetic', in Python symcrys.magnetic)";
21
+ /**
22
+ * The named tensor properties of the crystal classes: those of time-even tensors. `'gyrotropic'`
23
+ * is optical activity. The properties of time-odd tensors (`'ferromagnetic'`, …) are in the
24
+ * magnetic API.
25
+ */
26
+ export const TENSOR_PROPERTIES = Object.freeze(Object.fromEntries(Object.entries(ALL_TENSOR_PROPERTIES)
27
+ .filter(([, p]) => p.spec.timeParity === 'i')
28
+ .map(([name, { spec, description, source }]) => [
29
+ name,
30
+ Object.freeze({
31
+ spec: Object.freeze({ rank: spec.rank, parity: spec.parity, intrinsic: spec.intrinsic }),
32
+ description,
33
+ source,
34
+ }),
35
+ ])));
36
+ const TENSOR_PROPERTY_NAMES = Object.freeze(Object.keys(TENSOR_PROPERTIES));
37
+ // --- what comes in ---------------------------------------------------------------------------------
38
+ /** The key of a crystal class, checked. */
39
+ function classKey(key) {
40
+ if (groups.isPointGroupKey(key))
41
+ return key;
42
+ if (groups.isMagneticPointGroupKey(key)) {
43
+ throw new RangeError(`${JSON.stringify(key)} is a magnetic point group, not a crystal class: ${USE_MAGNETIC}`);
44
+ }
45
+ throw new RangeError(`Unknown point group key: ${JSON.stringify(key)}`);
46
+ }
47
+ /** A name of the table of this API, checked. */
48
+ function propertyName(name) {
49
+ if (typeof name === 'string') {
50
+ if (Object.hasOwn(TENSOR_PROPERTIES, name))
51
+ return name;
52
+ if (Object.hasOwn(ALL_TENSOR_PROPERTIES, name)) {
53
+ throw new RangeError(`${JSON.stringify(name)} is the property of a time-odd tensor: ${USE_MAGNETIC}`);
54
+ }
55
+ }
56
+ throw new RangeError(`Unknown tensor property: ${JSON.stringify(name)} (known: ${TENSOR_PROPERTY_NAMES.join(', ')})`);
57
+ }
58
+ /** The time-even tensor of a specification or of a property name, as the shared modules take it. */
59
+ function timeEven(specOrName) {
60
+ if (typeof specOrName === 'string')
61
+ return propertyName(specOrName);
62
+ if (typeof specOrName !== 'object' || specOrName === null) {
63
+ throw new RangeError(`Not a tensor specification: ${JSON.stringify(specOrName)}`);
64
+ }
65
+ const timeParity = specOrName.timeParity;
66
+ if (timeParity === 'c')
67
+ throw new RangeError(`A time-odd tensor (timeParity 'c'): ${USE_MAGNETIC}`);
68
+ if (timeParity !== undefined && timeParity !== 'i') {
69
+ throw new RangeError(`Unknown time parity: ${JSON.stringify(timeParity)}`);
70
+ }
71
+ return { rank: specOrName.rank, parity: specOrName.parity, timeParity: 'i', intrinsic: specOrName.intrinsic };
72
+ }
73
+ /** Checks a list of operations of a caller: an operation with time reversal is an error. */
74
+ function checkUnitary(operations) {
75
+ operations.forEach((op, i) => {
76
+ const timeReversal = op.timeReversal;
77
+ if (timeReversal === true) {
78
+ throw new RangeError(`Operation ${i} is combined with time reversal: ${USE_MAGNETIC}`);
79
+ }
80
+ if (timeReversal !== undefined && timeReversal !== false) {
81
+ throw new RangeError(`Operation ${i}: timeReversal must be false or absent, not ${JSON.stringify(timeReversal)}`);
82
+ }
83
+ });
84
+ }
85
+ /** A list of operations as the shared modules take it. */
86
+ function unitary(operations) {
87
+ checkUnitary(operations);
88
+ return operations.map((op) => ({ matrix: op.matrix, timeReversal: false }));
89
+ }
90
+ // --- what goes back --------------------------------------------------------------------------------
91
+ const withoutTimeCache = new WeakMap();
92
+ /** The operations as their matrices; the shared modules return the same frozen list for the same call. */
93
+ function matricesOnly(ops) {
94
+ let result = withoutTimeCache.get(ops);
95
+ if (!result) {
96
+ result = Object.freeze(ops.map((op) => Object.freeze({ matrix: op.matrix })));
97
+ withoutTimeCache.set(ops, result);
98
+ }
99
+ return result;
100
+ }
101
+ const descriptionCache = new WeakMap();
102
+ // --- point groups ----------------------------------------------------------------------------------
103
+ export { POINT_GROUP_KEYS } from './pointGroups/pointGroups.js';
104
+ /** True if `key` is the key of one of the 32 crystal classes. */
105
+ export function isPointGroupKey(key) {
106
+ return groups.isPointGroupKey(key);
107
+ }
108
+ const groupCache = new Map();
109
+ /** The crystal class with this key. Throws a RangeError for an unknown key. */
110
+ export function pointGroup(key) {
111
+ let g = groupCache.get(classKey(key));
112
+ if (!g) {
113
+ const { crystalSystem, order, centrosymmetric, polar, chiral, laueClass } = groups.pointGroup(key);
114
+ g = Object.freeze({ key, crystalSystem, order, centrosymmetric, polar, chiral, laueClass });
115
+ groupCache.set(key, g);
116
+ }
117
+ return g;
118
+ }
119
+ /** All 32 crystal classes, in the order of `POINT_GROUP_KEYS` (by crystal system, as in ITA). */
120
+ export function pointGroups() {
121
+ return groups.POINT_GROUP_KEYS.map((key) => pointGroup(key));
122
+ }
123
+ /**
124
+ * Finds a crystal class by a Hermann–Mauguin symbol in the given convention (default `'itc'`): the
125
+ * short symbol of a setting, a full symbol, or the key (spaces are ignored). A symbol that names
126
+ * one setting gives that setting; the key, and a short symbol that several settings share (the
127
+ * monoclinic ones: `2` for unique axis b and c), give the default setting of the convention.
128
+ * Returns undefined if nothing matches, also for a value that is not a string and for the
129
+ * symbol of a magnetic group with time reversal. Symbols are written as in this library: `-` for
130
+ * the overbar, also in the Birss convention (`m-3m`, where Birss prints `m3m`; docs/conventions.md,
131
+ * "Where ITC and Birss differ").
132
+ */
133
+ export function findPointGroup(hm, conventionName = 'itc') {
134
+ return groups.findPointGroup(hm, conventionName);
135
+ }
136
+ /** The settings of a crystal class, with symbols and the default of the given convention (default `'itc'`). */
137
+ export function settings(key, conventionName = 'itc') {
138
+ return groups.settings(classKey(key), conventionName);
139
+ }
140
+ /**
141
+ * All operations of the crystal class in the requested setting (default: the convention's default
142
+ * setting). ITC convention: in ITA's order, identity first, then as ITA numbers the general
143
+ * position. Birss convention: in birss-app's order (docs/conventions.md, "Order of the
144
+ * operations"). The matrices are Cartesian (docs/conventions.md, "Cartesian frame").
145
+ */
146
+ export function operations(key, options) {
147
+ return matricesOnly(groups.operations(classKey(key), options));
148
+ }
149
+ /**
150
+ * Generators of the crystal class in the requested setting (docs/conventions.md, "Generators"). ITC
151
+ * convention: ITA's selected generators in printed order, without the identity and ITA's lattice
152
+ * translations, so the list is empty for `1`; for `mm2` settings 2 and 3, which ITA does not list,
153
+ * those of setting 1 carried into their frame. Birss convention: birss-app's generators (for `1`
154
+ * the identity, as in birss-app).
155
+ */
156
+ export function generators(key, options) {
157
+ return matricesOnly(groups.generators(classKey(key), options));
158
+ }
159
+ /** A symbol of the crystal class in the requested convention and setting. */
160
+ export function symbol(key, options) {
161
+ return groups.symbol(classKey(key), options);
162
+ }
163
+ // --- properties that follow from operations ---------------------------------------------------------
164
+ export { holohedry } from './pointGroups/properties.js';
165
+ /**
166
+ * True if the group generated by `operations` contains the inversion, e.g. for the operations of a
167
+ * distorted crystal. A list that is not closed is closed first. For a crystal class, read
168
+ * `pointGroup(key).centrosymmetric`.
169
+ */
170
+ export function isCentrosymmetricOf(operations) {
171
+ return properties.isCentrosymmetricOf(unitary(operations));
172
+ }
173
+ /**
174
+ * True if the group generated by `operations` is chiral: proper rotations only. For a crystal
175
+ * class, read `pointGroup(key).chiral`. Polar is the named property `'pyroelectric'`:
176
+ * `allowsPropertyOf(operations, 'pyroelectric')`.
177
+ */
178
+ export function isChiralOf(operations) {
179
+ return properties.isChiralOf(unitary(operations));
180
+ }
181
+ // --- symmetry elements -----------------------------------------------------------------------------
182
+ /**
183
+ * Each operation of the crystal class described geometrically, in the order of `operations` for
184
+ * the same key and options. Axes are named by the symmetry direction they lie along: in the ITC
185
+ * convention with the sign of ITA Table 2.1.3.1, in the Birss convention signed as birss-app signs
186
+ * them (first non-zero Cartesian component positive); the sign fixes what the sense refers to.
187
+ */
188
+ export function describeOperations(key, options) {
189
+ const described = elements.describeOperations(classKey(key), options);
190
+ let result = descriptionCache.get(described);
191
+ if (!result) {
192
+ result = Object.freeze(described.map(({ kind, order, axis, sense }) => Object.freeze({ kind, order, ...(axis ? { axis } : {}), ...(sense ? { sense } : {}) })));
193
+ descriptionCache.set(described, result);
194
+ }
195
+ return result;
196
+ }
197
+ /**
198
+ * The positions of the full Hermann–Mauguin symbol in the requested convention and setting, each
199
+ * with its symmetry directions (ITA Table 2.1.3.1) and the symmetry elements along them. All
200
+ * positions of the crystal family are listed, also those the symbol of the class leaves out (then
201
+ * without `symbol`); the triclinic family has none. The directions keep the sign of Table 2.1.3.1
202
+ * in both conventions; in the Birss convention an axis of `describeOperations` may be reversed, so
203
+ * match it to a direction whose dot product with it is ±1, not by identity.
204
+ */
205
+ export function symmetryDirections(key, options) {
206
+ return elements.symmetryDirections(classKey(key), options);
207
+ }
208
+ // --- site symmetry and Wyckoff positions -----------------------------------------------------------
209
+ /**
210
+ * The site symmetry of `direction` (any non-zero vector, Cartesian) under `operations`, which may
211
+ * be any list of point operations (for instance those of a distorted crystal). The operations
212
+ * fixing the direction within the tolerance are closed under the products found in the list and
213
+ * the direction is set onto their fixed space, repeated until stable, so that for a group the
214
+ * result is a subgroup and the set direction lies exactly on its elements. For a list that is not a
215
+ * group, `multiplicity` may not be an integer. Throws a RangeError for a zero vector, and if the
216
+ * closed operations fix no common direction (a tolerance far too large, e.g. 0.5).
217
+ */
218
+ export function siteSymmetry(operations, direction, options) {
219
+ checkUnitary(operations);
220
+ // The shared function reads the matrices only, and it keeps the products of a list by the identity
221
+ // of the list, so the list of the caller is passed on as it is.
222
+ return site.siteSymmetry(operations, direction, options);
223
+ }
224
+ /**
225
+ * The Wyckoff positions of a crystal class for directions, as ITA tabulates them (general position
226
+ * first), in the ITC convention only (docs/conventions.md, "Site symmetry and Wyckoff positions").
227
+ */
228
+ export function wyckoffPositions(key, options) {
229
+ return wyckoff.wyckoffPositions(classKey(key), options);
230
+ }
231
+ /**
232
+ * The Wyckoff position of a direction (Cartesian) in a crystal class: the position whose site
233
+ * symmetry is conjugate to that of the direction (ITA's definition). `tolerance` as for
234
+ * `siteSymmetry`.
235
+ */
236
+ export function wyckoffPositionOf(key, direction, options) {
237
+ return wyckoff.wyckoffPositionOf(classKey(key), direction, options);
238
+ }
239
+ // --- tensors ---------------------------------------------------------------------------------------
240
+ /**
241
+ * The form of a tensor under a crystal class in the requested setting (default: the default
242
+ * setting of the convention, `'itc'` unless given). The tensor is given by its specification or by
243
+ * the name of a property in `TENSOR_PROPERTIES` (`'piezoelectric'`). The convention matters only
244
+ * through the setting: the same setting index gives the same form in both conventions
245
+ * (docs/conventions.md, "Tensors").
246
+ */
247
+ export function tensorForm(key, spec, options) {
248
+ return tensors.tensorForm(classKey(key), timeEven(spec), options);
249
+ }
250
+ /**
251
+ * The form of a tensor under the group generated by `operations`, e.g. the site symmetry of a
252
+ * surface normal (`siteSymmetry`) or the operations of a distorted crystal. The tensor is given by
253
+ * its specification or by the name of a property in `TENSOR_PROPERTIES`. The operations are
254
+ * Cartesian and orthogonal; a list that is not closed is closed first.
255
+ */
256
+ export function tensorFormOf(operations, spec) {
257
+ return tensors.tensorFormOf(unitary(operations), timeEven(spec));
258
+ }
259
+ /**
260
+ * The components of `tensor` (length 3^rank, flat index) in a frame rotated by the orthogonal
261
+ * matrix `rotation`: t′_{i…} = f·Σ R_{ia}…R_{…}·t_{a…}, with f = det(R) for an axial tensor and 1
262
+ * for a polar one. To express a tensor in the frame of a surface, pass the matrix whose rows are
263
+ * the new axes in the old frame. The kind of tensor is given by its specification or by the name
264
+ * of a property in `TENSOR_PROPERTIES`.
265
+ */
266
+ export function rotateTensor(tensor, rotation, specOrName) {
267
+ return tensors.rotateTensor(tensor, rotation, timeEven(specOrName));
268
+ }
269
+ /**
270
+ * True if the crystal class allows the named property, e.g. `allowsProperty('-6m2',
271
+ * 'piezoelectric')`: the tensor that describes it (`TENSOR_PROPERTIES`) has a non-zero form under
272
+ * the class. Symmetry only allows a property; whether a crystal shows it is a question of the
273
+ * material. It does not depend on setting or convention. Throws a RangeError for an unknown key or
274
+ * name.
275
+ */
276
+ export function allowsProperty(key, name) {
277
+ return tensors.tensorForm(classKey(key), propertyName(name), { setting: 1 }).basis.length > 0;
278
+ }
279
+ /** The named properties the crystal class allows, in the order of `TENSOR_PROPERTIES`. */
280
+ export function allowedProperties(key) {
281
+ return TENSOR_PROPERTY_NAMES.filter((name) => allowsProperty(key, name));
282
+ }
283
+ /**
284
+ * True if the group generated by `operations` allows the named property, e.g. for the site
285
+ * symmetry of a surface normal or the operations of a distorted crystal.
286
+ */
287
+ export function allowsPropertyOf(operations, name) {
288
+ return tensors.tensorFormOf(unitary(operations), propertyName(name)).basis.length > 0;
289
+ }
290
+ /** The named properties the group generated by `operations` allows. */
291
+ export function allowedPropertiesOf(operations) {
292
+ const ops = unitary(operations);
293
+ return TENSOR_PROPERTY_NAMES.filter((name) => tensors.tensorFormOf(ops, name).basis.length > 0);
294
+ }
295
+ //# sourceMappingURL=crystalClasses.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"crystalClasses.js","sourceRoot":"","sources":["../src/crystalClasses.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAKH,OAAO,KAAK,QAAQ,MAAM,2BAA2B,CAAC;AACtD,OAAO,KAAK,MAAM,MAAM,8BAA8B,CAAC;AA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AAC,EAAE,CAAC,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC;AAChG,CAAC;AAED,0FAA0F;AAC1F,MAAM,UAAU,iBAAiB,CAAC,GAAkB;IAClD,OAAO,qBAAqB,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,cAAc,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC,CAAC;AAC3E,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,gBAAgB,CAAC,UAAwC,EAAE,IAAwB;IACjG,OAAO,OAAO,CAAC,YAAY,CAAC,OAAO,CAAC,UAAU,CAAC,EAAE,YAAY,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC;AACxF,CAAC;AAED,uEAAuE;AACvE,MAAM,UAAU,mBAAmB,CAAC,UAAwC;IAC1E,MAAM,GAAG,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;IAChC,OAAO,qBAAqB,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,OAAO,CAAC,YAAY,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC;AAClG,CAAC"}
package/dist/index.d.ts CHANGED
@@ -1,16 +1,18 @@
1
1
  /**
2
- * Public API of symcrys. Everything exported here is covered by SemVer (see CLAUDE.md);
3
- * everything else is internal.
2
+ * Public API of symcrys: the crystallographic API, for the 32 crystal classes and without time
3
+ * reversal. The magnetic point groups, time-odd tensors and operations with time reversal are in
4
+ * the magnetic API, `symcrys/magnetic` (`magnetic.ts`), under the same function names
5
+ * (docs/conventions.md, "Two entry points"). Everything exported here and there is covered by
6
+ * SemVer (see CLAUDE.md); everything else is internal.
4
7
  */
5
8
  export { VERSION } from './version.js';
6
9
  export type { Mat3, Vec3 } from './linalg.js';
7
- export type { Operation } from './operations.js';
8
10
  export { crystalFamily, latticeBasis, type CrystalFamily, type CrystalSystem, type FixedAngleFamily, } from './lattice.js';
9
- export { POINT_GROUP_KEYS, findPointGroup, generators, isPointGroupKey, operations, pointGroup, pointGroups, settings, symbol, type Convention, type PointGroup, type PointGroupInSetting, type PointGroupKey, type PointGroupType, type Setting, type SettingOptions, type SymbolOptions, } from './pointGroups/pointGroups.js';
10
- export { isCentrosymmetric, isChiral, isPiezoelectric, isPolar, laueClass } from './pointGroups/properties.js';
11
+ export type { Convention, PointGroupKey, Setting, SettingOptions, SymbolOptions } from './pointGroups/pointGroups.js';
11
12
  export { LATTICE_SYMMETRY_DIRECTIONS, type Uvw } from './symmetryDirections.js';
12
- export { describeOperations, symmetryDirections, type Axis, type DirectionElements, type OperationDescription, type OperationKind, type SymmetryDirection, } from './pointGroups/elements.js';
13
- export { siteSymmetry, type SiteSymmetry, type SiteSymmetryOptions } from './siteSymmetry.js';
14
- export { wyckoffPositionOf, wyckoffPositions, type Hkl, type WyckoffOptions, type WyckoffPosition, } from './pointGroups/wyckoff.js';
15
- export { rotateTensor, tensorForm, tensorFormOf, type IntrinsicSymmetry, type TensorForm, type TensorParity, type TensorRank, type TensorSpec, type TimeParity, } from './tensors/tensorForm.js';
13
+ export type { Axis, DirectionElements, OperationKind, SymmetryDirection } from './pointGroups/elements.js';
14
+ export type { SiteSymmetry, SiteSymmetryOptions } from './siteSymmetry.js';
15
+ export type { Hkl, WyckoffOptions, WyckoffPosition } from './pointGroups/wyckoff.js';
16
+ export type { IntrinsicSymmetry, TensorForm, TensorParity, TensorRank } from './tensors/tensorForm.js';
17
+ export { POINT_GROUP_KEYS, TENSOR_PROPERTIES, allowedProperties, allowedPropertiesOf, allowsProperty, allowsPropertyOf, describeOperations, findPointGroup, generators, holohedry, isCentrosymmetricOf, isChiralOf, isPointGroupKey, operations, pointGroup, pointGroups, rotateTensor, settings, siteSymmetry, symbol, symmetryDirections, tensorForm, tensorFormOf, wyckoffPositionOf, wyckoffPositions, type Operation, type OperationDescription, type PointGroup, type PointGroupInSetting, type TensorProperty, type TensorPropertyName, type TensorSpec, } from './crystalClasses.js';
16
18
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAEvC,YAAY,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAC9C,YAAY,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,EACL,aAAa,EACb,YAAY,EACZ,KAAK,aAAa,EAClB,KAAK,aAAa,EAClB,KAAK,gBAAgB,GACtB,MAAM,cAAc,CAAC;AAEtB,OAAO,EACL,gBAAgB,EAChB,cAAc,EACd,UAAU,EACV,eAAe,EACf,UAAU,EACV,UAAU,EACV,WAAW,EACX,QAAQ,EACR,MAAM,EACN,KAAK,UAAU,EACf,KAAK,UAAU,EACf,KAAK,mBAAmB,EACxB,KAAK,aAAa,EAClB,KAAK,cAAc,EACnB,KAAK,OAAO,EACZ,KAAK,cAAc,EACnB,KAAK,aAAa,GACnB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,iBAAiB,EAAE,QAAQ,EAAE,eAAe,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAC;AAC/G,OAAO,EAAE,2BAA2B,EAAE,KAAK,GAAG,EAAE,MAAM,yBAAyB,CAAC;AAChF,OAAO,EACL,kBAAkB,EAClB,kBAAkB,EAClB,KAAK,IAAI,EACT,KAAK,iBAAiB,EACtB,KAAK,oBAAoB,EACzB,KAAK,aAAa,EAClB,KAAK,iBAAiB,GACvB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,YAAY,EAAE,KAAK,YAAY,EAAE,KAAK,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAC9F,OAAO,EACL,iBAAiB,EACjB,gBAAgB,EAChB,KAAK,GAAG,EACR,KAAK,cAAc,EACnB,KAAK,eAAe,GACrB,MAAM,0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ACR,YAAY,EACZ,MAAM,EACN,kBAAkB,EAClB,UAAU,EACV,YAAY,EACZ,iBAAiB,EACjB,gBAAgB,EAChB,KAAK,SAAS,EACd,KAAK,oBAAoB,EACzB,KAAK,UAAU,EACf,KAAK,mBAAmB,EACxB,KAAK,cAAc,EACnB,KAAK,kBAAkB,EACvB,KAAK,UAAU,GAChB,MAAM,qBAAqB,CAAC"}
package/dist/index.js CHANGED
@@ -1,14 +1,12 @@
1
1
  /**
2
- * Public API of symcrys. Everything exported here is covered by SemVer (see CLAUDE.md);
3
- * everything else is internal.
2
+ * Public API of symcrys: the crystallographic API, for the 32 crystal classes and without time
3
+ * reversal. The magnetic point groups, time-odd tensors and operations with time reversal are in
4
+ * the magnetic API, `symcrys/magnetic` (`magnetic.ts`), under the same function names
5
+ * (docs/conventions.md, "Two entry points"). Everything exported here and there is covered by
6
+ * SemVer (see CLAUDE.md); everything else is internal.
4
7
  */
5
8
  export { VERSION } from './version.js';
6
9
  export { crystalFamily, latticeBasis, } from './lattice.js';
7
- export { POINT_GROUP_KEYS, findPointGroup, generators, isPointGroupKey, operations, pointGroup, pointGroups, settings, symbol, } from './pointGroups/pointGroups.js';
8
- export { isCentrosymmetric, isChiral, isPiezoelectric, isPolar, laueClass } from './pointGroups/properties.js';
9
10
  export { LATTICE_SYMMETRY_DIRECTIONS } from './symmetryDirections.js';
10
- export { describeOperations, symmetryDirections, } from './pointGroups/elements.js';
11
- export { siteSymmetry } from './siteSymmetry.js';
12
- export { wyckoffPositionOf, wyckoffPositions, } from './pointGroups/wyckoff.js';
13
- export { rotateTensor, tensorForm, tensorFormOf, } from './tensors/tensorForm.js';
11
+ export { POINT_GROUP_KEYS, TENSOR_PROPERTIES, allowedProperties, allowedPropertiesOf, allowsProperty, allowsPropertyOf, describeOperations, findPointGroup, generators, holohedry, isCentrosymmetricOf, isChiralOf, isPointGroupKey, operations, pointGroup, pointGroups, rotateTensor, settings, siteSymmetry, symbol, symmetryDirections, tensorForm, tensorFormOf, wyckoffPositionOf, wyckoffPositions, } from './crystalClasses.js';
14
12
  //# sourceMappingURL=index.js.map