A Mesh visualization tool for the fem_2d library.
fem_2d
allows mesh files to be exported in a json format compatible with this library:
use fem_2d::prelude::*;
// load a raw mesh file (this is an alternate format, not compatible with this library)
let mut mesh = mesh::from_file("./input_files/some_mesh.json").unwrap();
// execute some refinements
mesh.set_global_expansion_orders([3, 4]).unwrap();
mesh.h_refine_elems(vec![0, 3, 4, 6], HRef::T).unwrap();
// export the mesh file
mesh.export_to_json("./output_files/refined_mesh.json").unwrap();
This tool allows mesh files to be visualized in 3D, and exported as images
- Install Node.js if you haven't already
- Download or clone this repository to a directory of your choice
- Navigate to that directory in a terminal and run the command
npm install
- Using the same terminal pointed at the directory containing this repo, run
node server.js
in the terminal - Navigate to localhost:3000 in your browser
- Click
choose file
in the top right corner or the app and select a mesh.json file generated byfem_2d
- Use the options on the right to manipulate the appearance of the mesh, or click and drag on the mesh to rotate it.
Please include one or more of the following citations in any academic or commercial work based on this repository:
- Corrado, Jeremiah; Harmon, Jake; Notaros, Branislav; Ilic, Milan M. (2022): FEM_2D: A Rust Package for 2D Finite Element Method Computations with Extensive Support for hp-refinement. TechRxiv. Preprint. https://doi.org/10.36227/techrxiv.19166339.v1
- Corrado, Jeremiah; Harmon, Jake; Notaros, Branislav (2021): A Refinement-by-Superposition Approach to Fully Anisotropic hp-Refinement for Improved Efficiency in CEM. TechRxiv. Preprint. https://doi.org/10.36227/techrxiv.16695163.v1
- Harmon, Jake; Corrado, Jeremiah; Notaros, Branislav (2021): A Refinement-by-Superposition hp-Method for H(curl)- and H(div)-Conforming Discretizations. TechRxiv. Preprint. https://doi.org/10.36227/techrxiv.14807895.v1