Git Product home page Git Product logo

pymsym's Introduction

pymsym

PyPI version Downloads

libmsym is a C library dealing with point group symmetry in molecules. pymsym is its python interface.

about

this library was originally developed by Marcus Johansson. the original library can be found here and seems unmaintained - after reaching out to the initial authors, i've decided to fork this so i can maintain it.

for more info, read the blog post.

installation

use pip:

pip install pymsym

api

there are two high-level functions, pymsym.get_point_group() and pymsym.get_symmetry_number().

here's a simple introduction:

import pymsym

# water
atomic_numbers = [8, 1, 1]
positions = [
  [0.007544053252786398, 0.39774343371391296, 0.0],
  [-0.7671031355857849, -0.18439316749572754, 0.0],
  [0.7595590949058533, -0.21335026621818542, 0.0]
 ]

pymsym.get_point_group(atomic_numbers, positions) # returns C2v
print(pymsym.get_symmetry_number(atomic_numbers, positions) # returns 2

the original lower-level classes from libmsym can also be accessed (pymsym.Element, etc).

point groups

here's all the point groups that pymsym can handle. some of these haven't been tested very well, please let me know if there are issues.

point_groups = [
    "C1", "Cs", "Ci", "C2", "C3", "C4", "C5", "C6", "C7", "C8",
    "D2", "D3", "D4", "D5", "D6", "D7", "D8", "C2v", "C3v", "C4v",
    "C5v", "C6v", "C7v", "C8v", "C2h", "C3h", "C4h", "C5h", "C6h",
    "C7h", "C8h", "D2h", "D3h", "D4h", "D5h", "D6h", "D7h", "D8h",
    "D2d", "D3d", "D4d", "D5d", "D6d", "D7d", "D8d", "S4", "S6",
    "S8", "T", "Th", "Td", "O", "Oh", "Cinfv", "Dinfh", "I", "Kh"
]

Corin Wagen, 2024

pymsym's People

Contributors

mcodev31 avatar corinwagen avatar rfkspada avatar shivupa avatar minhqdao avatar

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.