Skip to main content

Microstructure generation and meshing

Project description

Microgen logo

Microgen is a Python library designed to facilitate microstructure generation and meshing. Here are its core features:

  • Repeated cells: Generation of lattice structures such as octet trusses and honeycombs.
  • Triply Periodic Minimal Surfaces (TPMS): TPMS-based lattice generation known for favorable physical (mechanical, thermal, ...) properties like low density and large surface area.
  • Virtual composites microstructures: Generation of basic reinforcement geometries, including spheres, cylinders, ellipsoids, and more.
  • 3D Voronoi tessellation: Simulation of granular materials and polycrystalline metals.
  • Meshing: Regular and periodic meshing using Gmsh, remeshing using Mmg.

Generation of 3D objects is achievable through functions that utilize Open CASCADE (via Cadquery) or VTK (using PyVista). Neper offers tools for 3D tessellation, while Gmsh handles the generation of both regular and periodic meshes, with Mmg handling remeshing tasks.

Gyroid TPMS

PyPI package PyPI
Conda forge package Conda
Documentation Documentation
Status Status
Citation DOI
License License
Website Website
Binder Binder

Installation

With pip:

pip install microgen

With conda:

conda install conda-forge::microgen

To modify the sources, clone this repository and install microgen:

git clone https://github.com/3MAH/microgen.git
cd microgen
pip install -e .[all]
pre-commit install

The -e or --editable option allows to modify the sources without having to reinstall the package and [all] installs the optional development dependencies.

Run tests with pytest:

pytest tests -n auto

Examples

Click on the image to be redirected to the corresponding example on Microgen's documentation

Basic shapes

Repeated cells

Triply Periodic Minimal Surfaces (TPMS)

3D operations

Mesh

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

microgen-1.3.2.tar.gz (66.1 kB view details)

Uploaded Source

Built Distribution

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

microgen-1.3.2-py3-none-any.whl (63.6 kB view details)

Uploaded Python 3

File details

Details for the file microgen-1.3.2.tar.gz.

File metadata

  • Download URL: microgen-1.3.2.tar.gz
  • Upload date:
  • Size: 66.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.8

File hashes

Hashes for microgen-1.3.2.tar.gz
Algorithm Hash digest
SHA256 d64874c852a38225159188b2454bf22b9fb18d1ddd12540b0fa7eb4606a77157
MD5 f6bef8eb533c1137c9139f8b1329d29d
BLAKE2b-256 c0163d329d38f8bdc907e507575611ec5657871ae08e03dc3cef5e9c8504c8bd

See more details on using hashes here.

File details

Details for the file microgen-1.3.2-py3-none-any.whl.

File metadata

  • Download URL: microgen-1.3.2-py3-none-any.whl
  • Upload date:
  • Size: 63.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.8

File hashes

Hashes for microgen-1.3.2-py3-none-any.whl
Algorithm Hash digest
SHA256 5b844f74da87c95bced2130a29f1f2c37c273366a6e83c2f0d66393d64f4b9e6
MD5 5ffc7e5f013e0da0dcd899261534d72d
BLAKE2b-256 702ba887a0660292ca2ed0dc8c461afdfab6bbd4b666ac2494934115ffadb363

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