Experience using the p4est library for octogrid generation
Keywords:
octogrid
quadgrid
octree
quadtree
octogrid construction
p4est library
Abstract
Using the example of controlled octogrid construction in a complex domain, this article describes the functions of the open-source p4est library, designed for distributed work with octogrids and quadgrids. The main function signatures are provided, examples of their possible use are shown, and the nuances of their interaction are described. The library’s capabilities for base grid construction, controlled mesh refinement and coarsening, maintaining the 2:1 adjacency principle, processor load balancing, and other issues are discussed.
Section
Parallel software tools and technologies
References
- D. Meagher, Octree Encoding: A New Technique for the Representation, Manipulation and Display of Arbitrary 3-D Objects by Computer: techn. rep. / IPL-TR-80-111.(Rensselaer Polytechnic Institute, Troy, 1980).
- C. S. Peskin, “Flow Patterns Around Heart Valves: A Numerical Method,” Journal of Computational Physics 10 (2), 252–271 (1972).
doi 10.1016/0021-9991(72)90065-4
- C.-H. Yang, G. Scovazzi, A. Krishnamurthy, and B. Ganapathysubramanian, “Octree-Based Adaptive Mesh Refinement and the Shifted Boundary Method for Efficient Fluid Dynamics Simulations,” Adv. Comput. Sci. Eng. 4, 57–84 (2025).
doi 10.3934/acse.2025012
- K. Fujita, K. Katsushima, T. Ichimura, et al., “Octree-Based Multiple-Material Parallel Unstructured Mesh Generation Method for Seismic Response Analysis of Soil-Structure Systems,” Procedia Computer Science 80, 1624–1634 (2016).
doi 10.1016/j.procs.2016.05.496
- R. Schneiders, “Octree-Based Hexahedral Mesh Generation,” International Journal of Computational Geometry & Applications 10 (04), 383–398 (2000).
doi 10.1142/S021819590000022X
- C. Burstedde, L. C. Wilcox, and O. Ghattas, “p4est: Scalable Algorithms for Parallel Adaptive Mesh Refinement on Forests of Octrees,” SIAM Journal on Scientific Computing 33 (3), 1103–1133 (2011).
doi 10.1137/100791634
- T. Isaac, C. Burstedde, L. C. Wilcox, and O. Ghattas, “Recursive Algorithms for Distributed Forests of Octrees,” SIAM Journal on Scientific Computing 37 (5), C497–C531 (2015).
doi 10.1137/140970963
- T. Isaac, C. Burstedde, and O. Ghattas, “Low-Cost Parallel Algorithms for 2: 1 Octree Balance,” in 2012 IEEE 26th International Parallel and Distributed Processing Symposium (IEEE Press, Shanghai, 2012), pp. 426–437.
doi 10.1109/IPDPS.2012.47
- C. Burstedde, “Parallel Tree Algorithms for AMR and Non-Standard Data Access,” ACM Transactions on Mathematical Software 46 (4), 1–31 (2020).
doi 10.1145/3401990
- GNU General Public License, version 2.
https://www.gnu.org/licenses/old-licenses/gpl-2.0.en.html Cited April 3, 2026.
- Source code of the libraries p4est and sc.
https://github.com/cburstedde/p4est Cited April 2, 2026.
- GNU Lesser General Public License v2.1 - GNU Project - Free Software Foundation.
https://www.gnu.org/licenses/old-licenses/lgpl-2.1.en.html Cited April 3, 2026.
- G. M. Morton, A Computer Oriented Geodetic Data Base and a New Technique in File Sequencing: tech. rep.(IBM, 1966).