TetGenLink`
TetGenLink`

TetGenImport

TetGenImport["file.ext",expr]

imports data from a file into a TetGen expression.

TetGenImport["file",expr,"format"]

imports data in the specified format.

Details and Options

  • To use TetGenImport, you first need to load it using Needs["TetGenLink`"].
  • TetGenImport[File["path"],expr] is also supported.
  • The following formats specific to TetGen are supported by TetGenImport:
  • "node"a list of nodes
    "poly"a piecewise linear complex
    "smesh"a simple piecewise linear complex
    "ele"a list of tetrahedra
    "face"a list of triangular faces
    "vol"a list of maximum volumes
    "var"a list of variant constraints for facets/segments
    "neigh"a list of neighbors
  • The following general formats are supported by TetGenImport:
  • "off"Geomview's polyhedral file format
    "ply"polyhedral file format
    "stl"computer-aided design and manufacturing format
    "mesh"Medit's surface mesh file format
  • If no format is given, it is determined from the file extension.
  • TetGenImport currently works with the ASCII version of the above mentioned formats only. Use Import for binary versions of the file formats.

Examples

Basic Examples  (1)

First, load the package:

This creates an instance of a TetGen expression:

This finds a sample data file in the TetGenLink installation:

This loads the data file into the TetGen instance:

This extracts the points and facets:

This plots the shape:

Wolfram Research (2010), TetGenImport, Wolfram Language function, https://reference.wolfram.com/language/TetGenLink/ref/TetGenImport.html.

Text

Wolfram Research (2010), TetGenImport, Wolfram Language function, https://reference.wolfram.com/language/TetGenLink/ref/TetGenImport.html.

CMS

Wolfram Language. 2010. "TetGenImport." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/TetGenLink/ref/TetGenImport.html.

APA

Wolfram Language. (2010). TetGenImport. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/TetGenLink/ref/TetGenImport.html

BibTeX

@misc{reference.wolfram_2024_tetgenimport, author="Wolfram Research", title="{TetGenImport}", year="2010", howpublished="\url{https://reference.wolfram.com/language/TetGenLink/ref/TetGenImport.html}", note=[Accessed: 23-December-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_tetgenimport, organization={Wolfram Research}, title={TetGenImport}, year={2010}, url={https://reference.wolfram.com/language/TetGenLink/ref/TetGenImport.html}, note=[Accessed: 23-December-2024 ]}