Skip to main content

Build and visualize complex crystalline nanoparticle architectures, including models on substrates, for materials science, X-ray data analysis, and electron microscopy research

Project description

pyNMB_banner

Most nanoparticles have a well-defined shape. The habit of a crystalline nanoparticle is dependent on its crystallographic form and growth conditions. Its properties depends on its size, shape, surface topology and composition, etc... Modeling nanoparticles at the atomic scale is a crucial preliminary step to evaluate their potential for various applications. However, the process of generating an initial conformation for modeling and simulation is not that easy. Several tools are already available, including in the python realm. But to the best of our knowledge, they do not give access to the fascinating diversity of shapes encountered at the nanoscale. pyNanoMatBuilder is a new python tool designed to create nanoparticle models from any crystal structure or atomically precise structures, i.e. magic numbers polyhedra.

Various atomic ordered arrangements can be obtained by instantiating specific classes:

  • The crystalNPs utility builds several shapes, such as spheres, cubes, ellipsoids, parallelepipeds, and more generally any Wulff constructions. In addition to the database of cif coordinates, users can upload a cif file. Some pre-defined Wulff constructions are available, and it is also possible to specify the Miller indices and assign the minimum surface energies. This functionality is expected to work for any Bravais lattice.
  • Wulff constructions based on Bravais lattices cannot give access to some polyhedra, such as the icosahedra or decahedra five-fold structures. This is the reason why additional classes generate atomic arrangements of specific atomically precise polyhedra: platonic NPs, archimedean NPs, Catalan NPs and Johnson NPs. The corresponding classes do not pretend to be exhaustive, but they provide frequently observed structures.

The crystal habits of the structures generated by pyNanoMatBuilder are summarized below:


Installation

Activate your python environment and run:

pip install pyNanoMatBuilder

Quick usage

Let's first make a sphere with a diameter of ~ 4 nm. This is the target size, but the measured size will be slightly different due to compound cristalline organization.

from pyNanoMatBuilder import crystalNPs as cyNP
from pyNanoMatBuilder import utils as pyNMBu

# Define parameters
sphere_diameter = [4] # Target diameter in nm
# Instantiate the Crystal object (Au fcc sphere)
AuNP = cyNP.Crystal(
    "Au fcc",
    size=sphere_diameter, 
    shape="sphere", 
    thresholdCoreSurface=1, 
    skipSymmetryAnalyzis=False, 
    noOutput=False
)

# Save the results in various formats
# The 'write' utility automatically creates the 'coords/' directory, if it does not exist
pyNMBu.write("coords/SphericalAuNP.xyz", AuNP.NP)                # Main coordinates
pyNMBu.write("coords/SphericalAuNP_CoreSurface.xyz", AuNP.NPcs)  # Core/surface model
pyNMBu.write("coords/SphericalAuNP.script", AuNP.jMolCS)         # JMOL visualization script

# Save unitcells
pyNMBu.write("coords/SphericalAuNP_uc.cif", AuNP.cif)            # The base unitcell
pyNMBu.write("coords/SphericalAuNP_sc.cif", AuNP.sc)             # The supercell used for shaping

See more explanations in the How to? Workflow Guides section of the Main Tutorial notebook

Main Tutorial: Open In Colab


PyPI version Documentation Status License Downloads

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pynanomatbuilder-0.11.3.tar.gz (53.5 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pynanomatbuilder-0.11.3-py3-none-any.whl (44.4 MB view details)

Uploaded Python 3

File details

Details for the file pynanomatbuilder-0.11.3.tar.gz.

File metadata

  • Download URL: pynanomatbuilder-0.11.3.tar.gz
  • Upload date:
  • Size: 53.5 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for pynanomatbuilder-0.11.3.tar.gz
Algorithm Hash digest
SHA256 dad79f0ccd737938cdb1c74ff690a7b2fbd1448f31e7916033c0fc08261fa26d
MD5 96c817723ae966056cdf2db5f92f6c5e
BLAKE2b-256 3bb2c5f4ae7af1319bc412bebfe915ce26494f7bcc9eee7f77c0550d41bd4ba6

See more details on using hashes here.

File details

Details for the file pynanomatbuilder-0.11.3-py3-none-any.whl.

File metadata

File hashes

Hashes for pynanomatbuilder-0.11.3-py3-none-any.whl
Algorithm Hash digest
SHA256 a519a60ba200f02acf6c000b110f4c5f4b3c4ad77f41cda65f1d174561e5ddb4
MD5 ed49c6031b544adfdd2ce24f88f62c19
BLAKE2b-256 010e2da729bbe51c8809ecb4bef80c6d7c84396022f60bc185ac67c0cfbe2811

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page