Skip to main content

Add your description here

Project description

Meshgen v0.2.6

This is a small tool to extract meshes from finite element solvers. In particular JCMsuite and COMSOL are supported.

Usage

for example run as

meshgen test/helix.jcm test/helix.msh

the input file is passed as the first argument, the output as the second

help is available

meshgen -h
usage: meshgen [-h] [-m {a,w,x,ab,wb,xb}] [-s] [--version] input output

convert between comsol, jcmsuite, and gmsh meshes

positional arguments:
  input                 with extension jcm, mphtxt, or msh
  output                with extension jcm, mphtxt, or msh

options:
  -h, --help            show this help message and exit
  -m, --mode {a,w,x,ab,wb,xb}
                        writing mode (binary only possible for .jcm files)
  -s, --skip_1d         skip writing 1D elements in 2D COMSOL meshes
  --version             show program's version number and exit

alternatively the library can also be used from within python

from meshgen import Mesh
meshes = Mesh.read(args.input)

Since we support submeshes this returns a list of meshes. This behavior will likely change in future versions of meshgen

Known limitations

Currently the following JCM features are not supported:

  • curvilinear elements
    • when using a post process to generate a JCM-ASCII export of the grid the displacement field for the curvilinear elements is placed at the end of the file. meshgen is simply going to ignore the curvilinearity.
    • in binary files this doesn't seem to work
  • in files that have subgrids we rely on comments in the mesh file to skip extraneous Vertical Grids
    • these comments are not present in binary jcm files -> binary files with subgrids that have Vertical Grids cannot be processed (the processing fails)

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

meshgen-0.2.6.tar.gz (94.7 kB view details)

Uploaded Source

Built Distribution

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

meshgen-0.2.6-py3-none-any.whl (17.8 kB view details)

Uploaded Python 3

File details

Details for the file meshgen-0.2.6.tar.gz.

File metadata

  • Download URL: meshgen-0.2.6.tar.gz
  • Upload date:
  • Size: 94.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for meshgen-0.2.6.tar.gz
Algorithm Hash digest
SHA256 58c5e42a4138a655ad36f1da4b96f012ceeec8deb05bb74eff1a5842decd2e56
MD5 45b9586d919c0cf4b6c0450a61e4a717
BLAKE2b-256 51df3e20e32881ed5a77d2b8ec3a00738527a1bcba6675fba0e902d66eedcae6

See more details on using hashes here.

Provenance

The following attestation bundles were made for meshgen-0.2.6.tar.gz:

Publisher: release.yml on tfp-photonics/meshgen

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file meshgen-0.2.6-py3-none-any.whl.

File metadata

  • Download URL: meshgen-0.2.6-py3-none-any.whl
  • Upload date:
  • Size: 17.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for meshgen-0.2.6-py3-none-any.whl
Algorithm Hash digest
SHA256 c36a8e9294091d09cd072f64c6be87a99149bfe6dd41d68dcd7d7a7b092c9aca
MD5 24fc40b93b495822b4aa1d81b5b59455
BLAKE2b-256 9a7335adb0a075763334464e8aec04fddceff1d284aeb6222734bbe48b6b47e2

See more details on using hashes here.

Provenance

The following attestation bundles were made for meshgen-0.2.6-py3-none-any.whl:

Publisher: release.yml on tfp-photonics/meshgen

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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