Giter VIP home page Giter VIP logo

regroup's People

Contributors

dennisbrookner avatar hkwang avatar jbgreisman avatar

Watchers

 avatar  avatar  avatar

regroup's Issues

regroup output should exclude parallel Miller planes

If one specifies an hmax parameter >1, it will be the case that several parallel Miller planes are available. Here is an example where both [0, -2, -2] and [0, -1, -1] can be seen in the output:

> regroup *.mccd.inp -sg 19 --hmax 2
           Facet       Angle                                    spacegroup n_symops
                        mean       std count                                       
0    (0, -2, -1)    4.577838  0.493757   129                   P 1 (No. 1)        1
1    (0, -2, -2)    7.435163  0.513735   129                   P 1 (No. 1)        1
2    (0, -1, -1)    7.435163  0.513735   129                   P 1 (No. 1)        1
3     (0, -2, 0)   17.367348  0.521376   129  P 1 21 1 (a,b,c-1/4) (No. 4)        2
4     (0, -1, 0)   17.367348  0.521376   129  P 1 21 1 (a,b,c-1/4) (No. 4)        2
..           ...         ...       ...   ...                           ...      ...
119    (0, 2, 0)  162.632652  0.521376   129  P 1 21 1 (a,b,c-1/4) (No. 4)        2
120    (0, 1, 0)  162.632652  0.521376   129  P 1 21 1 (a,b,c-1/4) (No. 4)        2
121    (0, 1, 1)  172.564837  0.513735   129                   P 1 (No. 1)        1
122    (0, 2, 2)  172.564837  0.513735   129                   P 1 (No. 1)        1
123    (0, 2, 1)  175.422162  0.493757   129                   P 1 (No. 1)        1

[124 rows x 6 columns]

In these cases, I think it makes the most sense to prune the output to only specify the Miller plane for which the gcd of the different spacings is 1.

To my knowledge, this can be implemented fairly simply by calling d = np.gcd.reduce([h, k, l]) and skipping/dropping entries for which d > 1.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.