Publications

Back to Peer-reviewed journal papers

IFDD-Surf: Implicit-Function and Domain-Decomposition-Based Surface Generation for Distributed-Memory Parallel Environments

Authors
N. Morita†, K. Shuji, N. Mitsume
Published in
Software Impacts
Volume, pages
Vol.30, p.100864
Year
2026
Type
Peer-reviewed journal papers
Link
https://doi.org/10.1016/j.simpa.2026.100864
Topics
Particle methods Coupled analysis Large-scale parallel computing Tsunami and disaster mitigation Immersed boundary and interface capturing
Keywords
IFDD-Surf Surface mesh generation Implicit function Domain decomposition Distributed-memory parallel environment Visualization Marching cubes Parallel computing Signed-distance field Particle-number-density field
グラフィカルアブストラクト
グラフィカルアブストラクト

概要

大規模な数値シミュレーションは、計算領域を部分領域に分ける領域分割を用いて、分散メモリ型の並列計算機で行うのが一般的です。結果のデータも部分領域ごとに分かれて各計算ノードに置かれるので、可視化でも、データを 1 つのノードに集めずに直接処理する仕組みが必要です。また、複雑な結果では注目すべき領域を前もって特定できるとは限らないので、対話的な可視化の環境に組み込みやすく、任意の視点から確認できる軽量な表面データを作ることが欠かせません。さらに、汎用の可視化の枠組みは、有限要素法などのメッシュを用いる手法と、SPH 法(smoothed particle hydrodynamics)などの粒子法の両方の結果を扱う必要があり、両者は連成解析で組み合わされることもあります。これらの手法はデータ構造や境界の表し方が異なるため、数値解析手法によらない共通の可視化の手順を作ることは難しい課題です。

本論文は、分散メモリ型の並列環境で、大規模な数値シミュレーションの結果から表面メッシュを生成するソフトウェア IFDD-Surf を紹介しています。IFDD-Surf は、シミュレーションの結果を、符号付き距離場や粒子数密度場といった陰関数表現に基づくスカラー場に変換し、MPI で並列化したマーチングキューブ法で三角形の表面メッシュを生成します。各プロセスは自分の部分領域の分散データを扱い、隣接する部分領域との通信によって、部分領域の境界に偽の面ができるのを抑えます。生成した表面メッシュは PLY 形式または FBX 形式で書き出し、Unreal Engine 5 などのレンダリング環境で使えます。論文では、Lucy モデルを用いた性能評価と、粒子法によるダムブレイクの解析結果の可視化を示しています。

IFDD-Surf(v1.0)は Fortran と MPI で書かれ、MIT ライセンスで公開されています(コード:https://github.com/SoftwareImpacts/SIMPAC-2026-170、開発者の文書:https://github.com/nqomorita/IFDD_Surf)。実装した手法とその評価は、著者らの先行研究(日本計算工学会論文集、2024 年)に基づいています。

重要点

1. 陰関数表現で、数値解析手法によらずに表面を生成する

IFDD-Surf は、対象の表面を、空間に定義したスカラー場の等値面として表します。入力は、各部分領域に属する計算点の座標と、各点に与えた陰関数表現に基づくスカラー値です。メッシュを用いる手法の結果には、符号付き距離場を使います。物体の領域 Ω\Omega とその表面 ∂Ω\partial\Omega に対して、物体の内部で負、外部で正となる次の場を定義します。

f(x)={−d(x,∂Ω)(x∈Ω),+d(x,∂Ω)(x∉Ω)(1)f(\boldsymbol{x}) = \begin{cases} -d(\boldsymbol{x}, \partial\Omega) & (\boldsymbol{x} \in \Omega), \\ +d(\boldsymbol{x}, \partial\Omega) & (\boldsymbol{x} \notin \Omega) \end{cases} \tag{1}

ここで、f(x)f(\boldsymbol{x}) は点 x\boldsymbol{x} での符号付き距離、d(x,∂Ω)d(\boldsymbol{x}, \partial\Omega) は点 x\boldsymbol{x} から表面 ∂Ω\partial\Omega までの最短距離です。式 (1) は表面の上で 0 になるので、しきい値を 0 とした等値面として表面を取り出せます。

粒子法の結果には、粒子数密度場を使います。粒子数密度は、評価点 x\boldsymbol{x} の近くにある粒子を、重みを付けて数えたものです。

n(x)=∑jw(∣x−xj∣),w(r)={1−r/re(0≤r≤re),0(r>re)(2)n(\boldsymbol{x}) = \sum_{j} w(|\boldsymbol{x} - \boldsymbol{x}_j|), \qquad w(r) = \begin{cases} 1 - r/r_e & (0 \leq r \leq r_e), \\ 0 & (r > r_e) \end{cases} \tag{2}

ここで、n(x)n(\boldsymbol{x}) は点 x\boldsymbol{x} での粒子数密度、xj\boldsymbol{x}_j は粒子 jj の位置、w(r)w(r) は距離 rr に対する重み関数、rer_e は影響半径で、初期粒子間隔 l0l_0 に対して re=3.3l0r_e = 3.3 l_0 としています。粒子数密度は流体の内部で大きく、外部では 0 に近づくので、自由表面に当たるしきい値を指定して等値面を取り出せます。

このように結果を陰関数のスカラー場に変換することで、メッシュを用いる手法、粒子法、それらを組み合わせた連成解析の結果に、同じ処理の流れを使えます。論文は、この数値解析手法への非依存性を、IFDD-Surf の第 1 の主要な貢献としています。別々の可視化の手順が必要になりがちなメッシュを用いる手法と粒子法の結果を、共通のマーチングキューブ法の処理につなげられるからです。

2. 領域分割された分散データを、1 つのノードに集めずに並列に処理する

IFDD-Surf は、隣接する部分領域が共有する境界の近くの計算点を重ねて持つ、重なりのある領域分割を前提としています。重なりを通じてほかの部分領域から写した計算点を外部節点、その部分領域がもともと持つ計算点を内部節点と呼びます。このような分散データは METIS などのグラフ分割のライブラリで作れますが、IFDD-Surf は特定の分割の道具に依存せず、任意の重なりのある領域分割に使えます。

各 MPI プロセスは、担当する部分領域の中で MC セル(マーチングキューブ法で使うセル)を生成して処理し、分散データを 1 つのノードに集めません。処理は 5 つの段階からなります(図 1)。各プロセスは、入力と領域の設定(P1)、局所的な MC セルの生成(P2)、スカラー値の割り当てと部分領域の境界での補正(P3)、マーチングキューブ法による三角形メッシュの生成(P4)、PLY 形式または FBX 形式のファイルへの書き出し(P5)を行います。

IFDD-Surf の処理の流れ
図 1 IFDD-Surf の処理の流れ。実線の枠の処理は、各 MPI プロセスが担当する部分領域で並列に実行します。破線の枠は、IFDD-Surf の外部のシミュレータとレンダリングの道具です。矢印には、段階の間で受け渡すデータを書いています。出典:原論文 Fig. 1(CC BY 4.0)。

論文は、領域分割されたデータのために設計したこの並列処理を、第 2 の主要な貢献としています。各プロセスは、隣接する部分領域と必要な境界の情報だけをやり取りするので、シミュレーションが作った分散データの配置を保ったまま、可視化のデータを作れます。

3. 部分領域の境界に偽の面ができるのを抑える

部分領域ごとに独立に等値面を作ると、部分領域の境界の近くに、実際の表面には属さない偽の面ができることがあります。IFDD-Surf は、外部節点だけに囲まれた MC セルの頂点を見つけ、隣接する部分領域から、同じ座標でのスカラー値と、その値の計算に使った内部節点の数を、MPI の通信で受け取ります。複数の隣接する部分領域から値を受け取った場合は、内部節点の数が最も多い部分領域の値で更新します。この手順により、偽の面を抑えながら、分散データから直接、並列に表面メッシュを生成できます。

4. 数値シミュレーションの結果を、リアルタイムレンダリングの環境につなぐ

生成したメッシュは、頂点と面の情報を保存する PLY 形式(Polygon File Format)か、多くのレンダリング環境が対応する 3 次元モデルの形式である FBX 形式(Filmbox)で書き出せます。たとえば FBX 形式のファイルは、ゲームエンジン Unreal Engine 5 での対話的な可視化に使えます。論文は、この数値シミュレーションの結果とリアルタイムレンダリングの環境との接続を、第 3 の主要な貢献としています。結果を写実的な材質や周囲の環境とともに示せるようになり、仮想現実(VR)や拡張現実(AR)によって物理現象の理解を深められる可能性があると述べています。

性能評価と適用例

Lucy モデルを用いた性能評価

メッシュを用いる手法の結果の代表として、Stanford 3D Scanning Repository の 3 次元スキャンモデル Lucy(節点数 14,027,872)を使いました。モデルを METIS で分割し、偏微分方程式のソルバー Basilisk で、部分領域ごとに符号付き距離場を作りました。計測の条件は、MC セルの幅がモデルの座標系で 1 と 2、符号付き距離場の解像度が各軸 128 分割と 256 分割、MPI プロセスの数が 1、2、4、8、16、32 です。各条件を 3 回計測し、実行時間の平均を評価に使いました。MC セルの幅が 1 のとき、MC セルの総数は 798,425,600 個です。計算機は、Intel Xeon Gold 6248(2.5 GHz、20 コア)を 2 個(計 40 コア)と、768 GB の主記憶を備えたサーバー 1 台です。

Lucy モデルの表面メッシュ
図 2 32 の MPI プロセスで生成した Lucy モデルの表面メッシュ(MC セルの幅 1、解像度 256)。色は部分領域を表します。出典:原論文 Fig. 2(CC BY 4.0)。原論文では、Shuji ら(日本計算工学会論文集、2024 年)からの転載と記載されています。
  • メッシュを部分領域ごとに色分けして、部分領域の境界に偽の面や隙間のない表面メッシュが、並列に生成されたことを確かめました。
  • 1 プロセスでの実行時間の合計は、MC セルの幅 1 で 3880 s(解像度 128)と 4060 s(解像度 256)、幅 2 で 744 s(解像度 256)でした。
  • MC セルの幅が 1 のとき、MC セルの生成(P2)が実行時間の合計の 82〜85 % を占めました。幅を 2 にすると(いずれも解像度 256)、中核部分(P2〜P4 の小計)の時間は 6.2 分の 1 になり、MC セルの生成が占める割合は 42.7 % に下がりました。

粒子法への適用:ダムブレイクの可視化

粒子法への適用例として、流体の表面メッシュの生成と可視化を示しています。対象は、オープンソースの SPH 法のソフトウェア DualSPHysics に含まれるダムブレイク(水柱の崩壊)のベンチマーク問題です。解析は 128,310 個の粒子で、初期粒子間隔は l0=8.5×10−3l_0 = 8.5 \times 10^{-3} m です。MC セルの幅は 0.008 m としました。各時間ステップの表面メッシュを FBX 形式で書き出し、Unreal Engine 5 に読み込みました。

ダムブレイクの可視化
図 3 ダムブレイクの可視化。左は粒子法による解析結果、中央は流体の界面の陰関数表現、右は Unreal Engine 5 による可視化の実演です。出典:原論文 Fig. 4(CC BY 4.0)。原論文では、J-STAGE Data の動画(Shuji ら、2024 年)からの転載と記載されています。
  • メッシュを順に表示して、水の透明感、影、周囲の環境を取り入れた写実的なアニメーションを作りました。
  • 同じ場面を VR ヘッドセットでも表示し、利用者が可視化の空間の中を動き回って、さまざまな視点から現象を観察できるようにしました。

今後の展開

論文は、IFDD-Surf を、VR や AR とリアルタイムレンダリングを用いた、対話的な分析、設計レビュー、防災教育、専門家ではない人とのコミュニケーションの支援へ拡張できると述べています。

Graphical abstract
Graphical abstract

Overview

Large-scale numerical simulations are commonly performed on distributed-memory parallel computers using domain decomposition, in which the computational domain is partitioned into subdomains. Because the resulting data are also distributed across the compute nodes by subdomain, visualization likewise requires a mechanism that processes these distributed data directly, without gathering them on a single node. In addition, because the regions of interest in complex results cannot always be identified in advance, it is essential to generate lightweight surface data that can be readily integrated into interactive visualization environments and inspected from arbitrary viewpoints. Furthermore, a general-purpose visualization framework must handle results from both mesh-based methods, such as the finite element method, and particle-based methods, such as smoothed particle hydrodynamics (SPH), and the two may also be combined in coupled simulations. Because these methods differ in their data structures and boundary representations, establishing a common visualization workflow that is independent of the numerical method is challenging.

This paper presents IFDD-Surf, software that generates surface meshes from the results of large-scale numerical simulations in distributed-memory parallel environments. IFDD-Surf converts simulation results into scalar fields based on implicit representations, such as signed-distance fields and particle-number-density fields, and generates triangular surface meshes with a marching cubes algorithm parallelized with MPI. Each process handles the distributed data of its own subdomain, and communication with neighboring subdomains suppresses the formation of spurious facets at subdomain boundaries. The generated surface meshes are written in the PLY or FBX format and can be used in rendering environments such as Unreal Engine 5. The paper demonstrates a performance evaluation with the Lucy model and the visualization of the results of a dam-break simulation by a particle-based method.

IFDD-Surf (v1.0) is written in Fortran with MPI and is released under the MIT License (code: https://github.com/SoftwareImpacts/SIMPAC-2026-170; developer documentation: https://github.com/nqomorita/IFDD_Surf). The implemented methods and their evaluation are based on the authors' earlier work (Transactions of JSCES, 2024).

Key points

1. Surface generation independent of the numerical method through implicit representations

IFDD-Surf represents the target surface as an isosurface of a scalar field defined in space. The input consists of the coordinates of the computational points belonging to each subdomain and the scalar value, based on an implicit representation, assigned to each point. For results of mesh-based methods, a signed-distance field is used. For an object domain Ω\Omega with surface ∂Ω\partial\Omega, the following field, which is negative inside the object and positive outside it, is defined.

f(x)={−d(x,∂Ω)(x∈Ω),+d(x,∂Ω)(x∉Ω)(1)f(\boldsymbol{x}) = \begin{cases} -d(\boldsymbol{x}, \partial\Omega) & (\boldsymbol{x} \in \Omega), \\ +d(\boldsymbol{x}, \partial\Omega) & (\boldsymbol{x} \notin \Omega) \end{cases} \tag{1}

Here, f(x)f(\boldsymbol{x}) is the signed distance at point x\boldsymbol{x}, and d(x,∂Ω)d(\boldsymbol{x}, \partial\Omega) is the minimum distance from point x\boldsymbol{x} to surface ∂Ω\partial\Omega. Because Eq. (1) is zero on the surface, the surface can be extracted as the isosurface with a threshold of zero.

For results of particle-based methods, a particle-number-density field is used. The particle number density is a weighted count of the particles in the neighborhood of an evaluation point x\boldsymbol{x}.

n(x)=∑jw(∣x−xj∣),w(r)={1−r/re(0≤r≤re),0(r>re)(2)n(\boldsymbol{x}) = \sum_{j} w(|\boldsymbol{x} - \boldsymbol{x}_j|), \qquad w(r) = \begin{cases} 1 - r/r_e & (0 \leq r \leq r_e), \\ 0 & (r > r_e) \end{cases} \tag{2}

Here, n(x)n(\boldsymbol{x}) is the particle number density at point x\boldsymbol{x}, xj\boldsymbol{x}_j is the position of particle jj, w(r)w(r) is the weight function of the distance rr, and rer_e is the influence radius, which is set to re=3.3l0r_e = 3.3 l_0 for an initial particle spacing l0l_0. Because the particle number density is high within the fluid and approaches zero outside it, the isosurface can be extracted by specifying a threshold corresponding to the free surface.

By converting results into implicit scalar fields in this way, the same processing pipeline can be applied to the results of mesh-based methods, particle-based methods, and coupled simulations that combine them. The paper regards this independence from the numerical method as the first major contribution of IFDD-Surf, because results of mesh-based and particle-based methods, which often require separate visualization procedures, are connected to a common marching cubes pipeline.

2. Processing domain-decomposed distributed data in parallel without gathering them on a single node

IFDD-Surf assumes overlapping domain decomposition, in which adjacent subdomains redundantly retain the computational points near their shared boundaries. Computational points copied from other subdomains through this overlap are called external nodes, and points originally owned by a subdomain are called internal nodes. Such distributed data can be generated with graph-partitioning libraries such as METIS, but IFDD-Surf does not depend on any particular partitioning tool and can be applied to arbitrary overlapping decompositions.

Each MPI process generates and processes MC cells (the cells used in the marching cubes algorithm) within its assigned subdomain, without gathering the distributed data on a single node. The processing consists of five phases (Figure 1). Each process performs input and domain setup (P1), generates its local MC cells (P2), assigns scalar values and corrects them at subdomain boundaries (P3), generates a triangular mesh by the marching cubes algorithm (P4), and writes the mesh to a file in the PLY or FBX format (P5).

Workflow of IFDD-Surf
Figure 1. Workflow of IFDD-Surf. Operations with solid outlines are executed in parallel on the subdomain assigned to each MPI process. Dashed outlines denote the simulator and rendering tools external to IFDD-Surf. The arrows are annotated with the data transferred between the phases. Source: Fig. 1 of the original paper (CC BY 4.0).

The paper regards this parallel processing, designed specifically for domain-decomposed data, as the second major contribution. Because each process exchanges only the required boundary information with neighboring subdomains, visualization data can be generated while preserving the distributed data layout produced by the simulation.

3. Suppressing spurious facets at subdomain boundaries

Generating isosurfaces independently in each subdomain can produce spurious facets near subdomain boundaries that do not belong to the actual surface. IFDD-Surf identifies the MC-cell vertices surrounded exclusively by external nodes and receives from neighboring subdomains, via MPI communication, the scalar values at the same coordinates together with the number of internal nodes used to compute those values. When values are received from multiple neighboring subdomains, the value from the subdomain with the largest number of internal nodes is selected for the update. This procedure suppresses spurious facets while allowing surface meshes to be generated in parallel directly from distributed data.

4. Connecting simulation results to real-time rendering environments

The generated meshes can be written in the Polygon File Format (PLY), which stores vertex and face information, or in the Filmbox (FBX) format, a three-dimensional model format supported by many rendering environments. For example, FBX files can be used for interactive visualization in the Unreal Engine 5 game engine. The paper regards this connection between numerical simulation results and real-time rendering environments as the third major contribution. It states that results can be presented with photorealistic materials and surrounding environments, which may enhance the understanding of physical phenomena through virtual reality (VR) and augmented reality (AR).

Performance evaluation and application

Performance evaluation with the Lucy model

As input representative of mesh-based simulation results, the three-dimensional scan model Lucy from the Stanford 3D Scanning Repository (14,027,872 nodes) was used. The model was partitioned with METIS, and a signed-distance field was generated for each subdomain with the partial differential equation solver Basilisk. The measurement conditions were MC-cell widths of 1 and 2 in the model coordinate system, signed-distance-field resolutions of 128 and 256 subdivisions along each axis, and 1, 2, 4, 8, 16, and 32 MPI processes. Each condition was measured three times, and the mean execution time was used for the evaluation. For an MC-cell width of 1, the total number of MC cells was 798,425,600. The computer was a single server with two Intel Xeon Gold 6248 processors (2.5 GHz, 20 cores each; 40 cores in total) and 768 GB of main memory.

Surface mesh of the Lucy model
Figure 2. Surface mesh of the Lucy model generated with 32 MPI processes (MC-cell width 1, resolution 256). Colors indicate subdomains. Source: Fig. 2 of the original paper (CC BY 4.0). The original paper states that this figure is reproduced from Shuji et al. (Transactions of JSCES, 2024).
  • Coloring the mesh by subdomain confirmed that the surface mesh was generated in parallel without spurious facets or gaps at subdomain boundaries.
  • The total serial execution times were 3880 s (resolution 128) and 4060 s (resolution 256) for an MC-cell width of 1, and 744 s (resolution 256) for a width of 2.
  • For an MC-cell width of 1, MC-cell generation (P2) accounted for 82 % to 85 % of the total execution time. Increasing the width to 2 (both at resolution 256) reduced the time of the core subtotal (the sum of P2 to P4) by a factor of 6.2 and reduced the proportion of time spent on MC-cell generation to 42.7 %.

Application to a particle-based method: visualization of a dam break

As an application to a particle-based method, the paper demonstrates surface-mesh generation and visualization for a fluid flow. The test case is the dam-break benchmark problem (the collapse of a water column) included with the open-source SPH software DualSPHysics. The simulation used 128,310 particles with an initial particle spacing of l0=8.5×10−3l_0 = 8.5 \times 10^{-3} m. The MC-cell width was set to 0.008 m. The surface mesh at each time step was exported in the FBX format and imported into Unreal Engine 5.

Visualization of the dam break
Figure 3. Visualization of the dam break: (left) particle-method simulation results, (center) implicit-function representation of the fluid interface, and (right) visualization demonstration using Unreal Engine 5. Source: Fig. 4 of the original paper (CC BY 4.0). The original paper states that this figure is reproduced from a J-STAGE Data video (Shuji et al., 2024).
  • Displaying the meshes sequentially produced a photorealistic animation incorporating water transparency, shadows, and the surrounding environment.
  • The same scene was also displayed through a VR headset, allowing users to move within the visualization space and observe the phenomenon from different viewpoints.

Outlook

The paper states that IFDD-Surf can be extended to interactive analysis, design review, disaster education, and communication support for non-specialists using VR/AR and real-time rendering.