supercell-core
Package for investigation of mulitlayer 2D heterostructures lattices
Author: Tomasz Necio, University of Warsaw
Copyright (C) 2019-2020 University of Warsaw
Please cite the following paper, if you use the software: Supercell-core software: A useful tool to generate an optimal supercell for vertically stacked nanomaterial, AIP Advances 10, 105105 (2020); https://doi.org/10.1063/5.0023984, T. Necio and M. Birowska.
Installation:
pip3 install supercell-core --user
Documentation
https://readthedocs.org/projects/supercell-core/
Usage example
# Load supercell_core and NumPy
import supercell_core as sc
import numpy as np
# Read NiPS3 data from a POSCAR file into `nips3` Lattice object
# We need to provide names of chemical elements because they don't have to
# appear in POSCAR, but supercell-core needs them
# This will only work if you actually have a file named "POSCAR_nips3",
# you can copy it from /supercell_core/resources/vasp/NiPS3 directory
nips3 = sc.read_POSCAR("POSCAR_nips3", atomic_species=["Ni", "P", "S"])
# Let's create `graphene` Lattice object by hand
graphene = sc.lattice()
graphene.set_vectors([2.133, -1.23], [2.133, 1.23])
# atom "C" at position (0, 0, 0)
graphene.add_atom("C", (0, 0, 0))
# Methods can be chained
nips3_with_a_rouge_atom = sc.lattice().set_vectors(*nips3.vectors()) \
.add_atom("U", (0, 0, 1), spin=(0, 0, 1))
# Define heterostructure
h = sc.heterostructure().set_substrate(graphene).add_layer(nips3)
# Calculate strain tensor for particular supercell configuration
# (see help(sc.heterostructure()) for details)
M = [[1, -9], [8, 1]]
theta = 21.9 * sc.DEGREE
res = h.calc(M=M, thetas=[theta])
print(res.strain_tensors()) # Use help(res) to see all public methods of `Result`
# Optimise strain to find best supercell, with max repetition along any
# axis <= 12 substrate unit cells, and relative angle only from 0 to 7 degrees
# with resolution 0.1 deg
res = h.opt(max_el=12, thetas=[np.arange(0, 7*sc.DEGREE, 0.1*sc.DEGREE)])
superlattice = res.superlattice() # Lattice object
superlattice.save_POSCAR("POSCAR_sc") # save to file
fig, ax = superlattice.draw()
fig.show() # Show unit cell using matplotlib library
# To learn more use built-in documentation, e.g.:
help(nips3) # shows help on Lattice object when Python is in interactive mode (use 'q' to quit)
print(help(nips3)) # prints to stdout
Metadata
Release files for supercell-core 0.1.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| supercell_core-0.1.7.tar.gz | 34.1 kB | Without provenance | Details for supercell_core-0.1.7.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| supercell_core-0.1.7-py3-none-any.whl | Python 3 | none | any | Details for supercell_core-0.1.7-py3-none-any.whl |
Total release size: 84.6 kB
Release files / supercell_core-0.1.7.tar.gz
| Download URL | supercell_core-0.1.7.tar.gz |
|---|---|
| Size | 34.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ca12367663fdee1323e5504edbd5896d01c7961884c621f802c6de1393a981e5
|
|
BLAKE2b-256 checksum How to use checksums |
de9b2f1cce9f78e93f11311df2c8870ca2927473d7be0c55c75e0d890db1fb53
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.6.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.8.5
|
Release files / supercell_core-0.1.7-py3-none-any.whl
| Download URL | supercell_core-0.1.7-py3-none-any.whl |
|---|---|
| Size | 50.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
03d887ae6f26ea50b67debefb3f7b06b83b67bec7d392126413f384752eeb568
|
|
BLAKE2b-256 checksum How to use checksums |
7868ec9791177a340d170fdc0e99126be2df590eaf7441c61c76b5a8bbec049f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.6.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.8.5
|
Security for supercell-core 0.1.7
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.