Overview of TensorMesh modules
mainTensorMesh is organized into specialized modules for different stages of the FEM pipeline:
tensormesh.mesh: Mesh data structures, built-in generators (gen_rectangle,gen_circle,gen_cube,gen_L, etc.), and I/O (Gmsh, VTK-HDF5).tensormesh.element: Shape functions, quadrature rules, and element transformations (geometric orders 1–4).tensormesh.assemble: Assemblers for matrices and vectors (ElementAssembler,NodeAssembler,FacetAssembler,FacetBilinearAssembler) and multi-field systems (MixedElementAssembler).tensormesh.sparse:SparseMatrix(atorch_sla.SparseTensorsubclass) supporting various backends (SciPy, PyTorch Krylov, cuDSS, STRUMPACK, PyAMG, AmgX).tensormesh.operator: Boundary condition handling viaCondenser(Dirichlet),BlochReducer(periodic), or wave operators (robin_operator,port_source).tensormesh.ode: Time integrators (Euler, midpoint, Runge–Kutta).tensormesh.dataset: Generation of parametric PDE datasets (Poisson, Heat, Wave, linear elasticity).tensormesh.visualization: Plotting via Matplotlib and PyVista.tensormesh.functional: FEM-specific tensor utilities (elasticity, Voigt notation).tensormesh.material: Material property definitions.tensormesh.optimizer: Optimization algorithms like OC for topology optimization.