1 Introduction

Understanding droplets and droplet dynamic processes is very important in many areas of nature and technical systems. Modern research expands knowledge utilizing high-resolution computer simulations and experimental measurements producing a very large amount of data. However, these data need to be analysed and visualized to allow gaining insights. Also in the context of droplets, flow visualization is the adequate approach to do so. Traditionally, flow visualization focused on single-phase flow, but of course, observing droplets involves at least two phases, adding additional complexity to the analysis and visualization task.

In this work, we mainly analyse datasets resulting from simulations carried out with the Free Surface 3D (FS3D) [2] software. FS3D is a Computational Fluid Dynamics (CFD) solver, which employs the Volume of Fluid (VOF) method [9]. The resulting data are defined on a grid, where each cell stores the volume fraction of each phase in addition to a velocity vector. The VOF method does not inherently track an interface between phases but reconstructs it in each time step based on the VOF-field using piecewise linear interface calculation (PLIC). For interpretability, PLIC is incorporated in the visualization for surface representation [13].

Fig. 1
figure 1

©2013 IEEE. Reprinted, with permission, from [13]

Left: Standard PLIC reconstruction of a droplet interface. Right: Generalization of the PLIC surface to a higher-order approximation. The colour-scale shows the maximum discontinuity \(\delta _{\text {max}}\) to neighbouring cells.

2 Surface Reconstruction from Multiphase Volume of Fluid Simulations

The interface between different phases is probably one of the most interesting and mostly considered quantities when analysing the result of multiphase fluid simulations. Unfortunately, the VOF method does not track an interface and therefore it needs to be reconstructed. This is not only required during the simulation but also for the visualization. The reconstruction of an interface from a VOF-field can be interpreted as an isosurface extraction problem. However, traditional isosurface extraction introduces a reconstruction error. This can especially be seen by observing cells that are defined as interface cells according to the VOF method, but for which the isosurface lies completely outside of these cells. Therefore, fluid engineers should prefer to view the surface reconstructed with the PLIC method, as this is the standard method used within the simulation code, even if this reconstruction has the drawback of not being continuous. An example of a PLIC surface is shown in Fig. 1.

The work of Karch et al. [13] presented a visualization approach as well as a generalization of the PLIC method as a higher-order approximation of the interface. While this still maintains the piecewise characteristic, the surface becomes much smoother as can be seen in Fig. 1 (right).

A more recent challenge are simulations including three instead of just two phases or species. In such simulations, a second volume fraction field is required. Unfortunately, this makes it much harder to calculate a gradient in these fields. The gradient is required for the PLIC algorithm. According to this algorithm a PLIC patch within a cell is placed by using the negative gradient as patch normal. Further these patches are then placed iteratively to find a position such that the cell volume below the interface matches exactly the volume fraction of the cell. By using two VOF-fields, we now have the problem when looking up neighbouring cells for the calculation of partial derivatives for the gradient, these cells might be occupied with the second field and therefore no values would be available. To handle such cases, classification of the species within a \(3 \times 3 \times 3\) stencil around each cell is required to apply special calculations depending on the setup. These special cases are already handled within FS3D [15], see also Potyka et al. in this volume during simulation and the normals for the PLIC surface in these cells are stored as additional resulting data. For the visualization part, we implemented respective cell classification and take these additional normals into account. Further, the handling of three species requires an extension to the classic PLIC surface placement algorithm to work on tetrahedral cells instead of just cuboid cells, because in cells with all three phases some space is already occupied by the third species. An example of such a result is shown in Fig. 2.

Fig. 2
figure 2

PLIC surface visualization with ParaView for a three-phase simulation. Coloured are the different classes of species setups used within FS3D to determine special cases where the precomputed normals must be used

Fig. 3
figure 3

©2017 IEEE. Reprinted, with permission, from [11]

A space-time graph for a dataset with colliding droplets. Time increases in downward direction. a Droplet surfaces are shown for the time steps \({0.021\,\mathrm{\text {s}}}\), \({0.026\,\mathrm{\text {s}}}\), \({0.039\,\mathrm{\text {s}}}\), \({0.050\,\mathrm{\text {s}}}\), \({0.060\,\mathrm{\text {s}}}\), \({0.075\,\mathrm{\text {s}}}\) and \({0.084\,\mathrm{\text {s}}}\). b Space-time graph, where the red lines mark the time steps from a

Fig. 4
figure 4

©2017 IEEE. Reprinted, with permission, from [11]

Space-time graph for a larger dataset with additional mapping of angular momentum to colour.

3 Analysis of Breakup and Coalescence

Multiphase flow analysis and visualization often focus on the phase interface surface. However, in several applications droplet breakup and coalescence events occur which are very interesting because of the underlying physics. Karch et al. [11] introduce a space-time graph representation that allows exploring such events in a structured way. An example is shown in Fig. 3. There, a 3D spatial view (Fig. 3a) and a 2D parametric view (Fig. 3b) are combined. The 3D spatial view provides context to the position and surface shape of a feature. Next to this, the 2D parametric view shows the graph structure providing connectivity information of feature instances between time steps. For this work, initially, the different features need to be tracked. This includes spatial and temporal tracking. Spatial connectivity is obtained by finding face-connected cells with a volume fraction \(f>0\). Temporal tracking is achieved by tracking particles seeded within each cell of a feature to the next time step and match the resulting positions to spatial features within this time step. To provide additional context in the visualization, the space-time graph is rendered as a Sankey diagram, where the volume of a droplet determines the width of the graph edges (Fig. 3b). Further, these edges can be extended to map additional quantities of single droplets, for example, angular momentum, to colour (Fig. 4).

4 Visual Analysis of Droplet Dynamics in Large-Scale Multiphase Spray Simulations

Large jet simulations generate terabytes of data containing thousands of droplets and ligaments resulting from atomization processes. This makes it a laborious task to find interesting behaviour of single outlier droplets as well as finding general behaviour patterns in the overall droplet set. These difficulties not only cover the interactive analysis task itself from a user perspective but also the fact that processing such large amounts of data is not easy when targeting a highly interactive system. We try to overcome these problems by introducing a new visual analysis system utilizing modern machine learning and clustering techniques [8].

Our method uses multiple preprocessing steps to calculate useful physical quantities and other indicator values assisting the user in the following analysis process. Starting from the raw simulation output, the first step is to extract droplets from the VOF-field. This is achieved by using face-connected component labelling on grid cells that contain the fluid phase. In the next step, for each droplet instance, a vector of physical quantities is calculated as a reduced abstract description of this droplet instance. The quantities are volume, surface area, surface area to volume ratio, angular momentum, velocity, momentum, angular velocity, total energy, kinetic energy, rotational energy, and residual energy. In addition, we store a geometric surface representation, which later will be used for rendering.

To observe single droplets over time, we need to track the individual droplet instances between the time steps of the simulation. This is done by tracing virtual particles using the velocity field, according to the method introduced by Karch et al. [11]. The result is a graph containing temporal dependencies between all droplet instances in all time steps of the simulation. From this, we can easily detect and exclude all split and merge events in order to focus on the actual behaviour of single droplets.

Fig. 5
figure 5

Overview of our visual analysis system (adapted from [8]). On top is the 3D surface view, where the droplets are shown in the spatial context represented by their surfaces. Additionally, quantities can be mapped to colour and a timeline of single selected droplets can be displayed. Middle shows the quantity relation view. Here techniques such as parallel coordinate plots and a scatterplot matrix allow presenting a large number of data points. Bottom is the flow view, which is a fully integrated ParaView instance allowing detailed flow analysis of a single droplet selected within the surface view

We utilize hierarchical clustering according to Ward’s method [10] on the droplets within the abstract physical quantity space as a method to detect general behaviour patterns. Hierarchical clustering has shown the best results in practice, compared to density-based clustering algorithms such as DBSCAN [6]. The underlying problem is, that the distances between data points vary depending on the type of cluster and DBSCAN will only detect a single large cluster with very similar droplets. All other droplets will be single outliers and no further clustering structure can be found among them. Unfortunately, hierarchical clustering has worse algorithmic scaling performance and limits the number of data points to be clustered at a time. Therefore, we applied the clustering to time-averaged droplet quantities instead of using each individual droplet instance.

Fig. 6
figure 6

Analysis example using scatterplot matrices to investigate the relation between radius (distance to jet centre) and velocity (adapted from [8]). Selection in the scatterplot (red) (a, c, e) is linked to the 3D surface view and can be used to only display selected droplets (b, d, f). The dataset shows two clusters of different velocity (a, c) (next to a few outliers e), which are related to the radius

As a complementary method to focus on individual anomalous droplets, we utilize neural network-based machine learning based on previous work by Tkachev et al. [16]. We define a measure of anomaly in how likely the temporal behaviour of a droplet is predictable with a relatively small neural network. Therefore, we use the separation and collision-free time series of individual droplets. This time series is cut into overlapping fixed-size windows of size k, where we feed the quantity vector of \(k-1\) first subsequent time steps into a neural network, to predict the k-st time step. The norm of the difference between the predicted and actual values are used as the anomaly measurement value. One special aspect of our method is, that we train a separate neural network for each quantity because the quantities seem to vary in how likely they are predictable. This avoids that a less likely predictable quantity influences another one.

Fig. 7
figure 7

The scatterplot matrix also allows the user to interpret the clusters within the physical quantity ranges (adapted from [8]). a Here we can see, that volume is a very significant factor to distinguish different clusters. b Cluster separation can be seen along the velocity dimension as well as the spherical anisotropy dimension

Finally, we include all our precomputed values into an interactive system, as depicted in Fig. 5. The system consists of three different views, each supporting a different task. The 3D surface view provides a spatial context to the droplets and shows their surface. Many filtering options allow for selecting quantity value ranges of interest for aggregating data. Each quantity can be mapped to the droplet surface by colour. In addition, the temporal development of selected droplets is shown next to similar time series. The quantity relation view uses information visualization techniques such as parallel coordinates and scatterplot matrices to present a large number of droplets within the abstract quantity space. This allows searching for general patterns and behaviour types between these quantities. Highly interactive framerates are achieved by using the MegaMol framework [7] as the technical basis for this view. The flow view is a fully integrated ParaView [1] instance, which is used to support a deep analysis of a single selected droplet using the original simulation output.

The system is used to analyse a jet dataset [4, 5] with the help of different tools. First, we can take a look at the quantity relation view to find high-level relations between the quantities. An example of the radius to velocity relation is shown in Fig. 6. Here, the two main clusters within the scatterplot result from a two nozzle setup within the simulation, where the outer velocity is higher than the inner velocity. The linkage between the different tools of the systems allows to easily view selected droplets from the scatterplot within the 3D surface view for spatial and geometric context.

Fig. 8
figure 8

The 3D surface view shows that clusters consist of droplets with similar shapes and sizes (adapted from [8]). All droplets of a cluster are shown with the same surface colour. a All clusters in one view. b–i Each of the 8 clusters shown individually

Automated clustering can pre-filter the droplets into groups of similar quantities and droplet behaviour. The quantity relation view allows to interpret the different clusters and inspect their value ranges (Fig. 7), even if there is no direct physical interpretation. Within the 3D surface view, we can observe a similar size and droplet shape for all droplets of the same cluster (Fig. 8).

The prediction anomaly value is especially useful for highlighting interesting droplets and for hypothesis forming and validation during analysis. We found different droplet internal flow structures for different patterns of anomaly along with the time series of droplets. For example, droplets with a constantly high anomaly value or slowly decreasing value seem to exhibit saddle-type flow patterns. In contrast, low anomaly droplets tend to show a shear flow pattern. We found only one droplet with increasing anomaly (Fig. 9). This is the only droplet we could find where its internal flow exhibits a vortex.

Fig. 9
figure 9

(adapted from [8])

Time series of a single droplet that exhibits increasing anomaly (in top row mapped to colour). Detailed flow analysis with the integrated ParaView instance (bottom row) exhibits a vortex structure within this droplet

5 Geometric Approaches to the Analysis of Jets

Spray simulations result often in complex surface structures. Many droplets and ligaments are rugged and interwoven, making visual analysis hard, especially due to the occlusion. Therefore, existing analysis approaches are based on calculating statics and other quantities such as mass or velocity distributions or by just visualizing subsets of the data by slicing and clipping. All these methods are based on reducing the observed data, which has the drawback of either losing details (as by global statistics) or context (as by slicing or clipping). In this work, we aim to overcome these problems by using geometric transformations to reduce occlusion, while trying to keep relevant structures and minimize distortion effects.

The most simple, straightforward approach is to transform the surface representation from cylindrical coordinates to Cartesian coordinates. This allows to view a jet from all sides at the same time, but of course, introduces distortion. Figure 10 shows selected time steps from an animation of this transformation. Nevertheless, in cases where the relative position of structures is more of interest than the actual shape of the objects this method can still be effective to some degree.

With a second method, we try to keep the shape of single droplets persistent. Therefore, we extract droplets and calculate the PLIC surface representation within the original simulation domain in the same way as in Sect. 4. Then, we transform the centre of mass and the orientation of a droplet from cylindrical to Cartesian coordinates. This retains the shape of individual droplets, while only the distance between them is distorted.

Fig. 10
figure 10

a–d Selected time steps of an animation of the jet data undergoing transformation from the original surface view interpreted as cylindrical coordinates to Cartesian coordinates

Fig. 11
figure 11

Jet simulation data transformed from cylindrical coordinates to Cartesian coordinates. The view looks from the nozzle along the flow direction. The jet base is highlighted in green which conveys that a large number of components is still connected to the base

Fig. 12
figure 12

Opposite view direction compared to Fig. 11. The droplets at the bottom originate from the centre of the jet and are distorted sidewards, while the droplets at the top originate from the outer areas and are squashed together. In between is an area of relatively undistorted droplets. Additionally, the droplets are coloured by the spherical anisotropy \(c_s\) using the Viridis colourmap (purple maps to low spherical shape and yellow would highlight an ideal sphere). This allows to visually separate droplets from ligaments

Fig. 13
figure 13

Same view as Fig. 12, but with the droplet position transformation. Now we can see the original shape of each droplet, but still, the distance between the droplets is distorted

We implemented a dedicated tool that allows us to dynamically change the transformation method at interactive speeds during rendering. Figures 11 and 12 show the data undergoing the straightforward coordinate transformation. While some distortion may affect the droplets, this view is especially useful to observe the base of the jet. All sides can be observed at the same time and surface structures and waves can easily be compared, even if they may be located on the opposite side of the jet within the original spatial domain. To focus on the droplets themselves, the droplet-based transformation as shown in Fig. 13 might be more useful. We can see the undistorted droplets next to each other providing spatial context. The disadvantage of this is, of course, that the distances between droplets are distorted.

These methods are still work-in-progress and will be extended in various ways. First, we will investigate a combination of transformations, where the inner droplets are transformed as in Fig. 12, while the outer droplets are only moved as in Fig. 13. The challenge will be to find a smooth transition area, to prevent a prominent visual edge and avoid potentially possible droplet collisions. Next, we will introduce non-linear transformations to find a compromise between fluid and non-fluid phase distortion.

6 Multi-Component Visualization

Karch et al. [12] presented a method for analysing feature separation in advected scalar fields by calculating separation surfaces. The method is based on the idea to track the movement of small fluid portions by representing them as virtual particles which are tracked along the velocity field. In more detail, the method will place virtual particles at a user-defined starting time step within the fluid phase. Then, the particles are advected with the velocity field to a selected end time step. As the particles are used to represent a fluid portion around them, it is now possible to label each particle with the name of the feature in which it is located within the end time step. Now within the starting time step, the labels can be used to extract continuous regions of particles with the same label. The borders between these regions show, where the fluid will separate at a later time step and can be visualized as separation surfaces.

Unfortunately, during direct multiphase simulations often only every nth time step is saved to disk. Due to this relatively coarse temporal resolution, the advected particles will diverge from the actual VOF-field. Therefore, Karch et al. [12] suggested several corrector methods to keep the virtual particles within the VOF-phase.

Fig. 14
figure 14

Separation surfaces within a binary droplet collision (adapted from [12]). The virtual particles are seeded in the starting time step (left) and labelled (here represented by colour) by the separated features in the end time step (right)

Fig. 15
figure 15

(adapted from [12])

Detailed separation surface from the binary collision in Fig. 14

Figure 14 shows the temporal development of the separation surfaces within a binary droplet collision. Figure 15 provides a detailed clip of the separation surfaces within the starting time step.

Fig. 16
figure 16

Crossing separation simulation by Potyka and Schulte (cf. [15], see also Potyka et al. in this volume for further details). Head-on collision of a water-glycerol droplet (yellow) with a silicon oil M5 droplet (blue). It can be seen that the silicon oil droplet flows around the glycerol/water droplet and then splits up

Fig. 17
figure 17

Composition of the separation surfaces within the start time step (left two droplets), the advected particles at the end time step (small dots), and separated features at the end time step (right two droplets). We can see that the blue labels are based on the final feature, which contains portions of both initial materials

Currently, this approach is extended to support multiphase simulations with more than two phases or species. For this work, we are using a dataset of Potyka and Schulte [15] simulating a crossing separation (see also Potyka et al. in this volume). This is a head-on collision of a 50% water and 50% glycerol droplet with a silicon oil M5 droplet. The relative collision velocity is 3.17 ms\(^{-1}\) and the radius of both droplets is around 200 \(\upmu \)m. The dataset is shown in Fig. 16. The basic principle of our method works the same as for two phases, but the labelling must now handle multiple phases together and also the correctors need to be adopted. Figure 17 shows very early results using this method on the dataset. As the corrector methods are not fully adopted to three species, we can see that some particles are advected wrongly (marked red in Fig. 17). We expect to significantly reduce the number of such wrongly advected particles once the implementation of these correctors is finished.

7 Two-Phase Flow Visualization on High-Resolution Displays

The surface of jets or similar two-phase simulations is very often highly complex with many detailed small scale structures. The limited size of standard workstation screens forces the users to choose between having an overview or zooming into a smaller region of interest for details. A powerwall [14] as a large-scale high-resolution display has the potential to overcome this limitation. Users can see the full geometric expansion of a dataset and small scale structures at the same time and they can freely move in front of the powerwall to observe the details, while the global context remains. Further, the powerwall can be used by multiple users at the same time, allowing for interactive collaboration.

Using a powerwall for flow visualizations brings various technical difficulties compared to a desktop workstation. The powerwall installed at the Visualization Research Center of the University of Stuttgart is driven by ten 4K projectors and the images need to be rendered in a distributed cluster. Therefore, standard visualization software, cannot simply be used without further adjustments. We have chosen to build on the Unreal Engine [3], as it already supports distributed rendering. This includes synchronising settings and parameters across the render cluster and support for splitting a camera into multiple local tiles, which can later seamlessly be shown as a single image. While the Unreal Engine has the advantage of providing features for utilizing the powerwall and great rendering results, we still need to integrate our multiphase datasets. Both, for performance reasons and simplicity we have decided to externally pre-compute a geometric surface representation of the multiphase simulations using PLIC. This representation is stored in glTF format and can be imported as an asset into the Unreal Engine. Figure 18 shows an example, where two users collaborate and interactively analyse a jet simulation dataset.

With this development, we have demonstrated that with some technical effort the potential of the powerwall can be utilized for multiphase flow visualization. The Unreal Engine is a good technical foundation to set up the cluster environment and to render high-quality images, however, common visualization tools such as filtering, clipping and the handling of additional data values per droplet are not yet supported by the engine and must be implemented. We now aim at evaluating the analysis process and compare it to standard flow visualization techniques on desktop screens. In order to benefit from collaboration, the interaction concept would need to be extended to multiple users such that more than one person is able to control the view.

8 Conclusions

Even after a decade of research and development, interactive visualization of multiphase flow remains a challenging problem. While also single-phase flow visualization techniques continue to make progress, not all of these advances can be easily transferred to multiphase flow. As modelling and simulation of droplet phenomena have evolved over the years within the SFB-TRR 75, so have the requirements for visual analysis. Datasets have grown in size and complexity and many research questions cannot be answered by standard postprocessing tools. In this paper, we have reported on several new visualization techniques resulting from research in the project A01. Most of them are published together with our collaboration partners, others are still work-in-progress. The contributions cover a large span of topics ranging from phase interface visualization, topology representation of breakup and coalescence as well as tracking of separation surfaces, occlusion reduction within complex structures such as jets, assisted analysis and hypothesis forming tools to reveal relevant structures in large datasets, to visualization on high-resolution powerwalls. Concerning the visual analysis of simulations of more than two phases, only first steps have been taken and many options for future research became visible. Machine learning techniques were introduced as a means for identifying droplets with interesting features and we expect more such approaches to be helpful for comparative visualization and exploration of simulation ensembles.

Fig. 18
figure 18

Surface of a jet simulation is rendered on the VISUS powerwall and is interactively explored by two users