MaterSim / PyXtal

A code to generate atomic structure with symmetry
MIT License
253 stars 68 forks source link

molecular crystal with support from ASE #7

Closed qzhu2017 closed 6 years ago

qzhu2017 commented 6 years ago

@scottfredericks it might be a good idea to take the advantage of ase for generating molecular crystal. ASE provides a collection of small molecules which you can use for test.

from ase.build import molecule
c60 = molecule('C60')

Moreover, it has well designed class which can be very useful.

print(c60.get_positions())

check out my updates on github: https://github.com/qzhu2017/CMS/blob/master/ASE-scripts/Model_construction.ipynb

as well as the documentation of molecule class in ASE, https://wiki.fysik.dtu.dk/ase/ase/atoms.html

qzhu2017 commented 6 years ago

@scottfredericks , please complete the function of inertia tensor and upload your work to this repository.

scottfredericks commented 6 years ago

I now have a basic function for calculating the inertia tensor for an ASE-type molecule (get_inertia_tensor(mol) in molecule.py). However, I still am not sure how to calculate the point group or symmetry operations using this tensor. I will continue to test this functionality, and examine the source code of the pymatgen PointGroupAnalyzer class: http://pymatgen.org/_modules/pymatgen/symmetry/analyzer.html#PointGroupAnalyzer In the mean time, I will work on inserting discrete-symmetry molecules into low-symmetry Wyckoff positions, using pymatgen's Molecule class.

qzhu2017 commented 6 years ago

Please just use the pymatgen type molecule for your work. You don't need to switch to ASE. We just use ase to get access to the database of molecules.

qzhu2017 commented 6 years ago

The key of using inertia tensor is to obtain the principle axis, and then you should let these axes coincide with a, b, c, body diagonal or face diagonal directions.

scottfredericks commented 6 years ago

The inertia tensor will always have 3 orthogonal eigenvectors. However, it is not immediately clear which eigenvector corresponds to which principle axis (numpy does not sort them). For example, CH4's inertia tensor has 3 orthogonal eigenvectors: [ 0.20667028, 0.78441517, 0.58479076] [ 0.10026281, -0.61152744, 0.78484493] [-0.97325986, 0.10357136, 0.20503222] However, if we treat these as a matrix, the determinant is -1, meaning that we cannot simply rotate the molecule by the inverse of this matrix to get the desired orientation. One current problem is determining the correct rotation matrix for rotating the principle axes to [[1,0,0],[0,1,0],[0,0,1]]. It should just be a matter of trying permutations of the eigenvectors, but I am not sure about the exact method. Additionally, for a given rotation matrix, we may or may not be able to directly compute the principle axis/axes depending on the type of operation. The calculation of principle axis for an inversion or reflection is slightly different than the calculation for a standard rotation. So, for checking site compatibility, we need a different method for different types of symmetry operation. I apologize for the delay; I have been and will continue to work on these issues.

scottfredericks commented 6 years ago

I have updated molecule.py, and completed a function called reoriented_molecule. The function takes a molecule as input, then reorients the principle axes to [[1,0,0],[0,1,0],[0,0,1]]. The function returns both the reoriented molecule, and also the rotation matrix used to reach this orientation. This is accomplished by calling np.linalg.eigh on the molecule's inertia tensor.

Due to numerical errors, the function may need to be called multiple times to achieve the correct orientation. However, it is unlikely more than two attempts will be needed. This is handled automatically within the function; if more than 10 attempts are needed, the function returns an error.

The current objective is to create a function for classifying and describing arbitrary (non-translational) symmetry operations based on their type. matrix2aa in matrix.py currently works for non-zero and non-inversion rotation operations, but returns errors in other cases. Once this function is complete, we can appropriately orient a molecule based on symmetry requirements.

scottfredericks commented 6 years ago

I have fixed a bug in reoriented_molecule in (molecule.py) involving linear molecules. Previously the code never considered them as correctly oriented, due to the degeneracy of the eigenvectors of the inertia tensor.

The main objective is still the classification of symmetry operations: For determining the relevant axes of a symmetry operation from a matrix (matrix2aa), an Eigenvector approach seems most appropriate, as the rotation angle might be 0, and there may or may not be a reflection/inversion involved (this is why the previous approach fails). It is best to define four categories of matrix operations: identity (no change) pure inversion pure rotation rotoinversion These can be separated first by the determinant of the operation matrix, and secondly by the eigenvalues. Identity and pure inversion are trivial. For rotoinversion, we first multiply by the inverse, then treat the operation as a pure rotation. For pure rotation, there should only be one positive, real-valued eigenvector (we check that its eigenvalue is 1). This is the axis of rotation. For the angle, we choose a vector perpendicular to the rotational axis, apply the matrix to it, then calculate the angle between it and the old vector.

We want matrix2aa to return 1) an axis of rotation for rotations and rotoinversions, and None for the identity and inverse matrices 2) the angle of rotation for rotations/rotoinversions, and None for identity/inverse matrices 3) a boolean value for whether or not the operation contains an inversion. True for identity and pure rotations, and False for inverse and rotoinversion operations.

To avoid calling this function multiple times on an operation, I can create an OperationAnalyzer class which stores this information. This should make comparing operations easier. Other useful features for future implementation might include multiplicity, a function for comparing with another operation, the operation's name (ex: '2', 'm', '-3', etc.), and generalization to translation/shear operations.

Also, the previous method for generating a rotation matrix from the axis-angle representation seems to be flawed. It currently uses the SymmOp.from_axis_and_angle function, but this does not seem to work for all cases, so a new method is needed. There is a formula for each individual element of the desired matrix using cosines and sines. This should work, but I do need to check for numerical accuracy. It is difficult to verify that aa2matrix works without a working matrix2aa function, and vice-versa. So, I will fix aa2matrix first, then fix matrix2aa, and then cross-verify the two functions.

scottfredericks commented 6 years ago

aa2matrix has been remade based on https://en.wikipedia.org/wiki/Rotation_matrix#Axis_and_angle. It seem to work for simple cases; other cases have yet to be tested.

scottfredericks commented 6 years ago

@qzhu2017 After further testing on methane, it seems the original xyz file was very slightly asymmetric. As a result, the inertia tensor could not be symmetrized. The new methane xyz molecule does not have this issue, and there is now a hydrogen atom along one of the principal axes after random rotation followed by reorientation. So, I will try to make sure future test molecules have the desired symmetry up to a high numerical accuracy. Additionally, it looks like after reorientation, the molecule has point group operations on two separate principal axes. I will test this once matrix2aa is complete. If this is the case, we can align the molecule without referencing individual point group operations. I am not sure this is true for molecules in general, but it may be. For now I will implement the method we discussed.

scottfredericks commented 6 years ago

@qzhu2017 I have just learned that np.linalg.eig and np.linalg.eigh output eigenvectors to columns, not rows. This had been causing a great deal of confusion, as the matrix [ 0 1 0 ] [ 0 0 1 ] [ 1 0 0 ] outputs rows which are not the correct eigenvalue (which should be a real multiple of [1,1,1]. However, the correct eigenvalue is contained in one of the output columns. I have implemented this into reoriented_molecule, and am about to implement it into matrix2aa.

scottfredericks commented 6 years ago

@qzhu2017 matrix2aa is now complete. It seems to produce the correct results for matrices generated by aa2matrix. Note that matrix2aa always outputs an angle between 0 and pi. I will now work on a class for comparing SymmOp's.

scottfredericks commented 6 years ago

@qzhu2017 I have created the class OperationAnalyzer within matrix.py. It takes a SymmOp as input, then calculates the type, axis, angle, and order of the operation. Now, to check if two operations are equal, we can simply compare their type and order. Also, for convenience, this information can be viewed by printing the OperationAnalyzer object directly.

scottfredericks commented 6 years ago

@qzhu2017 I have completed the orientation_in_wyckoff_position function (in molecule.py). So far I have only tested the results for the low-symmetry Wyckoff position 24l with m.. symmetry, in the spacegroup Pm-3m. But, the results appear to be correct for water, methane, and hydrogen.

For input, the function takes a pymatgen Molecule object, the international spacegroup number, and the Wyckoff position's index within the spacegroup. It outputs a list of valid orientation SymmOps, which can be applied to the original molecule using mol.apply_operation(op) If an orientation has a degree of freedom about an axis, you can apply a random rotation about the axis using "randomize=True". I recommend leaving the default value of True, as directional biases may appear otherwise. Additionally, if you want to check a molecule based on its current orientation, you may use "exact_orientation=True". In this case, the function only outputs either True or False, as we only have to check one orientation.

I will continue to test the function for other Wyckoff positions and molecules. I don't think finding false positive orientations will be an issue, since the program checks each orientation in the process. But, it may be tricky to check if additional orientations are possible, especially for higher-symmetry molecules. The next step is to create a function for generating molecular crystals for a given molecular stoichiometry. My understanding is that we will generate an atomic crystal with increased volume, then "plug in" molecules into the atomic sites, provided the symmetry is sufficient.

---Results so far--- (for spacegroup 221, position 24l (index 2), site symmetry m..) For water, 2 orientations are found. This is because water has two symmetries which are conjugate to m.. - one reflection across the plane of the molecule, and one reflection across a plane which splits the molecule in half. Repeating the program gives equivalent orientations but with different random rotations about the x-axis.

For methane, 6 orientations are found. For each case, two hydrogen atoms lie within the y-z plane, while the other two are on opposite sides of the plane. Technically all 6 orientations are equivalent up to rotation about the x-axis, so in this particular case we could get the same result from one orientation. I think this is due to permutational symmetry; we could imagine the hydrogen atoms having 4 different colors. There are then 6 permutations which cannot be mapped onto each other via rotation alone. Of course quantum mechanically, these states are indistinguishable. However, I think the multiplicity might be useful in other cases; I will try to come up with an example.

In the special case of hydrogen, the program outputs 13 different orientations. One orientation is along the x-axis, and the other 12 are within the y-z plane. This might seem strange at first, but it makes sense considering that infinitesimal rotations are treated as 12-fold rotations. Naturally, we would expect that the probability of lying within the y-z plane is infinitely greater than the chance of lying within the x-axis (since a plane is infinitely larger than a line). But, our program just treats infinity as 12 in this case, so the probability is precisely 12 times greater. A class for storing infinitesimal transformations could be helpful for formalizing this in the future, but does not seem necessary yet.

qzhu2017 commented 6 years ago

@scottfredericks This function of orientation_in_wyckoff_position looks nice. I would like to test it further. Could you please upload your molecule xyzzy files to our GitHub repo. Right now, it has only ch4.xyz.

qzhu2017 commented 6 years ago

@scottfredericks, thanks for your excellent job!

I have created a script to perform systematic test on the orientation_in_wyckoff_position function. ee3d4c8

So far I have included a few molecules from ase library,

    for name in ['H2', 'H2O', 'HCl', 'PH3', 'CH4', 'C60']:

please install ase, and then execute the command

 $ python from_ase_molecule.py

And I checked the site symmetry of space group 16(P222) with the site symmetry of .2.

H2  has point group symmetry:  D*h
Found 13 orientations for  H2
H2O  has point group symmetry:  C2v
Found 1 orientations for  H2O
HCl  has point group symmetry:  C*v
Found 1 orientations for  HCl
PH3  has point group symmetry:  C3v
CH4  has point group symmetry:  Td
Found 3 orientations for  CH4
C60  has point group symmetry:  Ih
Found 1 orientations for  C60

I also exported the re-alligned molecules to xyz folder. You can use vesta to visualize it by the following command:

$ vesta xyz/CH4-0.xyz

Here I assumed you have installed vesta software. By clicking 'b' from the menu bool, you will get a view of the molecules from y-axis. ...

so far the code works. For all the exported xyz files, it does look good when I view them along y-axis.

However, there a few problems, 1, H2 somehow has 13 orientations while CH4 has 3 orientations. I don't know how they are calculated. It looks like there are a few duplicates here. 2, H2O has only one, this is perfect! 3, C60 has only one, which is a bit strange. There should exist more than one 2-foler axis, I believe.

Suggestions, Can we allow the output of site symmetry symbol like .2., m.., it would be really good to have such function when we perform systematic test.

qzhu2017 commented 6 years ago

@scottfredericks I suggest you also create a function to output site symmetry symbol. In principle, there should be 32 point groups. But you need to consider the special the position of special axis (like 2.. and .2.). So you will need to consider more. But the good thing is that

def make_site_symm_symbol(R):
"""
Args: the rotation symmetry of wyckoff sites:
Return: the symbol of site symmetry (2.., ..m, etc)
"""
    if len(wyckoff)==1:
        return '1'
    elif len(wyckoff)==2:
        -1
        2..
        .2.
        ..2
        m..
        .m.
        ..m
    elif len(wyckoff)==3:
        3..
    elif len(wyckoff)==4:
        .2/m. 
        2/m..
        ..2/m
        222
        mm2
        m2m
        2mm
        4..
    elif len(wyckoff)==6:
        -3..
        3.2
        .32
        6..
        .3m
    elif len(wyckoff)==8:
        mmm
        4/m..
        422
        -4..
        42.2
        4m.m
        -42.m
    elif len(wyckoff)==12:
        .-3m
        -6..
        6/m..
        -6m2
        622
        23.
    elif len(wyckoff)==16:
        4/mm.m
    elif len(wyckoff)==24:
        6/mmm
        m-3.
        432
        -43m
    elif len(wyckoff)==48:
        m-3m

This code can be put in database/make_spgtype_db.py

scottfredericks commented 6 years ago

@qzhu2017 Okay, I will work on a site symmetry classification function. It should not be hard to find the symmetry for each axis, using OperationAnalyzer. However, some of the site symmetry groups have different notation, for example .3m and m-3m, which have a 3 listed in the y-axis spot, even though the 3-fold rotation is not along the y-axis. Cases like these will require some additional if-then statements - I will try to read up on the details of Schoenflies notation.

For the other cases, it should be possible to just determine the site symmetry of the first point in the Wyckoff position, and then rotate it as needed using the wyckoff_generators.csv database. For example, if the first point's site symmetry is m.., and the generator for the second point is 'y,z,x', I think the second point's site symmetry should be '.m.' Since the orientation_in_wyckoff_position function only checks the first point in the Wyckoff position, I think this is a good starting point in case rotating the symmetry group is difficult to do.

Looking at C60, you are right - there are many 2-fold rotation axes, but they seem to all lie along a line connecting two hexagons. So, they should all be symmetry-equivalent. I think this means any additional orientations would be redundant. However, based on this reasoning, I am not sure why the program detects multiple orientations for CH4 but not C60. I will continue to look into it.

scottfredericks commented 6 years ago

@qzhu2017 Running OperationAnalyzer on c60's point group, it looks like the rotation order is not detected correctly. As a result, not all of the 2-fold rotation axes were recognized. I will try and re-adjust the numerical tolerance so that it works.

scottfredericks commented 6 years ago

@qzhu2017 I have made 2 changes to improve the accuracy: 1st, I make the program use PointGroupAnalyzer.symmetrize_molecule. I believe this makes some small adjustments to the atomic positions. It makes the angle of rotation slightly closer to an integer divisor of 2 pi. 2nd, I recoded how we determine the order of a rotation. I had some trouble determining the right tolerances for numpy.isclose(), so I just changed it to check the absolute value of the difference between the angle and a multiple of 2pi.

After making these changes, the program now correctly detects the order of the rotations for c60. However, it still only finds 1 orientation. I am still not sure why this is, but I will continue to work on it.

scottfredericks commented 6 years ago

@qzhu2017 I have fixed another numerical issue in OperationAnalyzer.is_conjugate. The program now finds 15 orientations for C60, which should be the correct result.

Now the issue is eliminating redundancy. My plan is to loop through the symmetry elements and look for pairs which are symmetrically equivalent. Two elements should be symmetrically equivalent if there is a point group operation which maps the first axis onto the second, or vice-versa. I think this should reduce the outputs for C60 and CH4 down to 1, and reduce the output for H2 down to 2. Additionally, the program should be a bit faster.

qzhu2017 commented 6 years ago

C60 has 20 hexagons + 12 pentagons. There are two types of C-C edges, 1: exclusively shared by two hexagons, and 2: shared by one hexagon and one pentagon. The 2-fold axes should pass through the middle point of edge 1. There should be (206-125)/2=15 edges. So your results seem to be correct.

Regarding the elimination of redundancy, I agree with your proposal.

scottfredericks commented 6 years ago

@qzhu2017 I have implemented the method which I described above. Some of the redundancy is gone, but not all. Hydrogen now produces 5 results, and C60 produces 4. For hydrogen I think the issue may have to do with the way get_symmetry assigns symmetry to linear molecules; this needs to be fixed either way. For c60, I don't know what the issue is. I am not completely sure that two symmetrically equivalent symmetry elements are guaranteed to have a point group operation mapping one onto the other, though clearly this is true at least some of the time.

I think it may still be possible to find equivalent axes by calculating the moment of inertia about two axes. The only risk is that in rare cases, the moment of inertia will not be unique. For example, consider the reflectional symmetries of water. There are two different axes of reflection. We can take the moment of inertia about each of these axes. The two values will be different. However, if we were to scale the molecule's size, the two moments would change at different rates. So, there should be some length for which the two values are equal, meaning we would treat the two axes as equivalent, even though they are not. So, even though the chances are extremely small, there could hypothetically be a molecule where this is the case. To avoid this problem, we can rescale the model and compare the moments of inertia a second time. I think it should be impossible for the two moments to be equal for both scales unless the axes actually are equivalent. This takes a small amount of extra computation time, but should still save time in the long run by eliminating redundant orientations. I will try to implement this tonight.

qzhu2017 commented 6 years ago

@scottfredericks I updated the code to check the site symmetry of m.. with H2. And I got the 5 results for H2. But it is clear that some of them are redundant already from the xyz file.

qiangzhu@Qiangs-MBP:~/Desktop/github/crystallography$ cat xyz/H2-*.xyz
2
H2
H -0.000000 0.368372 0.012482
H 0.000000 -0.368372 -0.0124822
H2
H -0.000000 -0.364991 0.051330
H 0.000000 0.364991 -0.0513302
H2
H 0.000000 -0.368374 -0.012403
H -0.000000 0.368374 0.0124032
H2
H 0.368583 0.000000 0.000000
H -0.368583 0.000000 -0.0000002
H2
H -0.000000 0.292297 0.224534
H 0.000000 -0.292297 -0.224534

Structures 0, 1, 2 are nearly identical.

scottfredericks commented 6 years ago

@qzhu2017 I have implemented the moment of inertia method which I described. Also, I changed the way the program loops through the constraints; this seems to have been causing an issue. I think the program works correctly now (for .2. symmetry): Hydrogen has 2 orientations, Ph3 has none, and all of the others have 1. It also seems to work for your new site symmetry check of m...

qzhu2017 commented 6 years ago

@scottfredericks looks good now. I will think about other test cases to make sure it is correct. I just added site symmetry of 3.., however, the program stops with a warning that operation is not orthogonal.

qzhu2017 commented 6 years ago

@scottfredericks just add more site symmetries to check. It should go through if your code works.

After that, you can start to implement the function of output site symmetry symbol and then we can use a few molecules to run a systematic scan of all site symmetries.

After this is done, we shall be ready to write the code to generate molecular crystals. It should be pretty straightforward then.

scottfredericks commented 6 years ago

@qzhu2017 It looks like the operations of 3-fold symmetry actually are not orthogonal: [-1. 1. 0.] [-1. 0. 0.] [ 0. 0. 1.] This is because the operations are meant to be applied to relative coordinates, not absolute ones. I did not consider this. It should be easy to fix though. I will loop through all of the Wyckoff symmetry and look for non-orthogonal operations (it should just be 3 and 6-fold rotations and rotoinversions). I can then replace them with orthogonal operations, and create a new database with them. We should still keep the old database for working with relative coordinates, since the Wyckoff checking function uses it. P.S. I did not mean to close the issue; I hit the button on accident.

scottfredericks commented 6 years ago

@qzhu2017 I have implemented the orthogonality check and conversion within orientation_in_wyckoff_position. However, I still need to fix the way the program detects 6-fold symmetry. I will try to have this done tonight.

qzhu2017 commented 6 years ago

@scottfredericks I think the implementation might be incorrect.

H2  has point group symmetry:  D*h
Found 2 orientations for  H2  with site symm 2
Found 2 orientations for  H2  with site symm m
Found 2 orientations for  H2  with site symm 3
Found 1 orientations for  H2  with site symm -1
Found 2 orientations for  H2  with site symm 2/m
H2O  has point group symmetry:  C2v
Found 1 orientations for  H2O  with site symm 2
Found 2 orientations for  H2O  with site symm m
Found 1 orientations for  H2O  with site symm 3
HCl  has point group symmetry:  C*v
Found 1 orientations for  HCl  with site symm 2
Found 1 orientations for  HCl  with site symm m
Found 1 orientations for  HCl  with site symm 3
CS2  has point group symmetry:  D*h
Found 2 orientations for  CS2  with site symm 2
Found 2 orientations for  CS2  with site symm m
Found 2 orientations for  CS2  with site symm 3
Found 1 orientations for  CS2  with site symm -1
Found 2 orientations for  CS2  with site symm 2/m
C2Cl4  has point group symmetry:  D2h
Found 3 orientations for  C2Cl4  with site symm 2
Found 3 orientations for  C2Cl4  with site symm m
Found 3 orientations for  C2Cl4  with site symm 3
Found 1 orientations for  C2Cl4  with site symm -1
Found 3 orientations for  C2Cl4  with site symm 2/m
PH3  has point group symmetry:  C3v
Found 1 orientations for  PH3  with site symm m
CH4  has point group symmetry:  Td
Found 1 orientations for  CH4  with site symm 2
Found 1 orientations for  CH4  with site symm m
Found 1 orientations for  CH4  with site symm 3
C6H6  has point group symmetry:  D6h
Found 2 orientations for  C6H6  with site symm 2
Found 2 orientations for  C6H6  with site symm m
Found 2 orientations for  C6H6  with site symm 3
Found 1 orientations for  C6H6  with site symm -1
Found 2 orientations for  C6H6  with site symm 2/m
C60  has point group symmetry:  Ih
Found 1 orientations for  C60  with site symm 2
Found 1 orientations for  C60  with site symm m
Found 1 orientations for  C60  with site symm 3
Found 1 orientations for  C60  with site symm -1
Found 1 orientations for  C60  with site symm 2/m

H2O shouldn't have 3 fold symmetry, while PH3 should have it. It is also strange that C6H6 has two orientations. qiangzhu@Qiangs-MBP:~/Desktop/github/crystallography$ cat xyz/C6H6-0.xyz 12 H6 C6 C 0.000000 1.317578 0.459026 C 0.000000 0.261260 1.370569 C 0.000000 -1.056317 0.911543 C -0.000000 -1.317578 -0.459026 C -0.000000 -0.261260 -1.370569 C -0.000000 1.056318 -0.911542 H 0.000000 2.344173 0.816679 H 0.000000 0.464822 2.438453 H 0.000000 -1.879351 1.621774 H -0.000000 -2.344173 -0.816679 H -0.000000 -0.464822 -2.438453 H -0.000000 1.879351 -1.621774 This one looks like 3.. symmetry, qiangzhu@Qiangs-MBP:~/Desktop/github/crystallography$ cat xyz/C6H6-1.xyz 12 H6 C6 C -0.697624 -0.033509 1.207855 C 0.697624 -0.033509 1.207855 C 1.395248 -0.000000 0.000000 C 0.697624 0.033509 -1.207855 C -0.697624 0.033509 -1.207855 C -1.395248 -0.000000 0.000000 H -1.241180 -0.059618 2.148960 H 1.241180 -0.059618 2.148960 H 2.482360 0.000000 -0.000000 H 1.241180 0.059618 -2.148960 H -1.241180 0.059618 -2.148960 H -2.482360 -0.000000 0.000000

This one doesn't look like 3.. symmetry,

scottfredericks commented 6 years ago

@qzhu2017 There were some looping errors in the program, which resulted in the wrong operations being assigned, and some operations being left out; these should be fixed now. Based on the listed point groups and wyckoff site symmetries, the results now look correct to me.

qzhu2017 commented 6 years ago

@scottfredericks
I looks good to me as well. Now you can work on the code to list the site symmetry symbol based on the operations.

scottfredericks commented 6 years ago

@qzhu2017 I tried converting the non-orthogonal operations into pure rotations for other space groups, but the code does not work. I believe this is because the 3- and 6-fold rotations are not always about the z axis (they are for space group 147, which seems to work correctly). I think we can fix this by re-generating the general Wyckoff position for each space group, then generating the site-symmetry based on this. I already have a script for generating the site symmetry database; I will try and modify it, then upload it if it works.

scottfredericks commented 6 years ago

@qzhu2017 I have implemented the necessary code. Rather than generating a separate database, I just do the conversion within get_wyckoff_symmetry if necessary - I realized that for trigonal and hexagonal spacegroups, we can convert the operations just by conjugating by the inverse of the lattice vectors. In other words, we just have to transform the basis, and then our operations will be orthogonal. The from_ase_molecule.py script still produces the correct results, and the site symmetry operation for every point, wyckoff position, and space group is now orthogonal (provided you set molecular=True within get_wyckoff_symmetry). I will now try to work on printing the site symmetry.

qzhu2017 commented 6 years ago

@scottfredericks wyckoff_symmetry_df_molecular = read_csv("database/wyckoff_symmetry_molecular.csv")

FileNotFoundError: File b'database/wyckoff_symmetry_molecular.csv' does not exist

scottfredericks commented 6 years ago

@qzhu2017 The issue should be fixed - I removed the reference to the csv file.

qzhu2017 commented 6 years ago

Seems that there is no issue anymore.