You are on page 1of 10

ON THE SIMULATION OF FOCUSED WAVES WITH OPENFOAM &

WAVES2FOAM

THOMAS VYZIKAS(1), DIMITRIS STAGONAS(2), EUGENY BULDAKOV(2) & DEBORAH


GREAVES(1)
(1) University
of Plymouth, Plymouth, UK,
thomas.vyzikas@plymouth.ac.uk
(2) UniversityCollege London, London, UK,
d.stagonas@ucl.ac.uk

Abstract

The paper examines the simulation of focusing wave groups of different steepness in the open-
source Computational Fluid Dynamics (CFD) package OpenFOAM and its freely available
library waves2Foam.The accurate focusing of unidirectional wave groups at a predetermined
point and time is achieved by employing a newly developed methodology that has already
been successfully tested in a physical wave flume. The analytic comparison with experimental
results highlights the capacity of the broadly used numerical wave tank (NWT) in simulating
focused waves and sets the basis for future rectification of the model.

Keywords: OpenFOAM; waves2Foam; Numerical wave tank; Focused wave groups; Extreme waves

1. Introduction

OpenFOAM is an open-source CFD software package, which is extensively used as a solver of


partial differential equations. It is widely used in industry and research as a robust and
advanced C++ code. OpenFOAM solves 3D domains, considers multiphase flows with several
turbulence models, enables practically unlimited parallelization and allows user modification
at all levels to satisfy specific needs. Its characteristics made it a popular tool for simulating free
surface flows and more specifically for studying wave-structure interaction problems. Two
different toolboxes have been recently released by Higuera, et al. (2013) and Jacobsen, et al.
(2012) that allow the generation and absorption of free surface waves with different
approaches. Both these libraries are based on the interFoam solver that couples the Reynolds
Averaged Navier-Stokes (RANS) equations and incompressible continuity equation for two
immiscible fluids with the Volume of Fluid method (VoF) for tracking the interface between
water and air, i.e. the free water surface.

Focused waves are often used in both physical and numerical studies as a representative
condition for extreme waves. Extreme waves have been proven to be catastrophic for offshore
structures and shipping and the profound understanding of their formation and
hydrodynamics, as well as the estimation of their impacts on structures, are of vital importance
for the offshore industry (Zhao, et al., 2010). A common way believed to trigger randomly the
generation of extreme waves in the ocean is wave-wave interactions. Random extreme wave
generation through long runs is not preferred though, due to the limitations of physical and
numerical models, such as the limited length of the flume, the reflections and computational
time. Instead, focused waves are mostly used, since they allow deterministic replication of the

1
extreme event in a short time. A focused wave can represent the average shape of an extreme
wave profile randomly generated from a specified energy spectrum (Tromans, et al. 1991).

In practice though, challenges arise when modelling steep focusing wave groups, due to the
shifting of the focal time and location from the predetermined values, caused by the nonlinear
wave-wave interactions (Ning, et al., 2009). Many methodologies have been suggested so far
that improve the focusing of the wave group, mainly by adjusting the phases of its
components. In many cases, however, the focal location and time of the physical and numerical
model did not coincide (Westphalen, et al., 2012) and often that of the numerical model needed
to be shifted to show satisfactory comparison with the physical experiment. This becomes an
important challenge, as more CFD codes are used to generate extreme waves and study their
interaction with structures.

In this work, a newly developed methodology by Stagonas, et al. (2014) that allows accurate
focusing of extreme waves is employed and a comprehensive comparison between physical
and CFD results for focused wave groups is presented. This methodology has already been
successfully tested in a physical wave flume, and here, for first time it is applied on a NWT
designed with OpenFoam. Initial and boundary conditions are implemented using the
waves2Foam library. Linear, weakly nonlinear and strongly nonlinear focused wave groups
that form a Pierson-Moskowitz (PM) are generated. The in-depth analysis and comparison
performed in this study aims to show the applicability of the methodology in a NWT and
reveal any potential weaknesses of these commonly used solvers and boundary conditions.
Further research will define the source of the differences between the physical and numerical
tank and evaluate the capacity of the specific CFD package to simulate focused waves.

2. The methodology for focusing wave groups

As mentioned in the introduction, the deterministic definition of the focal location and time for
steep nonlinear wave groups, either in physical, or in numerical model is a challenging
research area. The steeper the group is, the greater the discrepancies from the theoretical focal
location and time are. Out of the several approaches that have been developed to tackle these
issues, three main methodologies can be identified: i) Rapp and Melville (1990), ii) Chaplin
(1996) and iii) Schmittner, et al. (2009) that were based on i) linear theory to determine the
phases in order to achieve the desired focusing, ii) an iterative process to bring the wave
components in phase by adjusting their phases and iii) an improved iterative method for
modifying both the components’ phases and amplitudes, respectively. These methods might
perform well with linear groups, however, as the steepness of the group increases, the quality
of the focusing decreases.

The new methodology used in this study provides accurate focusing even for strongly
nonlinear wave groups that satisfy realistic energy spectra. The later is considered as a
comparative advantage from previous methods, because it allows the examination of marine
structures in real-sea extreme wave conditions. The distinctive characteristic of the method is
the fact that the target spectrum for the focusing is linearised, which is a natural choice, since
the full nonlinear spectrum is uniquely defined by its linear part. To extract the linear
component of the spectrum, four wave groups with phase shifts of 0, π, π/2 and 3π/2rad,
which correspond to crest focused wave, through focused wave, positive and negative slope
focused waves respectively (Fig. 1), need to be simulated. The linear part is extracted using a
suitable linear combination of the four simulated spectra measured at the focal location. The
extracted spectrum is then compared with the target spectrum and a new spectrum with

2
corrected amplitudes and phases is calculated at the focal location. The later spectrum is
propagated “backwards” to the inlet boundary with the linear dispersion relation and the four
wave groups with the phase shifts mentioned above are simulated. This iterative process is
applied until the linear wave components have zero phase difference at the focal location and
the measured linearised spectrum matches the target one.

Figure 1. Timeseries of the surface elevation relative to the focusing time for the four
wave groups simulated (crest, trough, positive and negative slope focused waves),
normalized by the amplitude of the crest focused wave group.

3. The numerical wave tank

3.1 Geometry and computational mesh

The NWT is designed as a numerical mirror of the physical wave flume of UCL laboratory in
order to allow direct comparison between the numerical and physical results. The physical
flume is 20x1.2x1m, equipped with two piston type wave makers, located at each end of the
flume, capable of generating unidirectional waves and absorbing reflected waves with force
feedback active absorption. The numerical flume represents a cross section of the physical
flume, but it is shorter in order to save computational resources. The quasi-3D, one cell thick,
computational domain is 16x0.7m. The focal location and the water depth were 7.8m and 0.5m
respectively, identical in the numerical and physical model.

The computational mesh is fixed and consists of three horizontal layers: a uniform finer layer
around the free surface and two other non-uniform layers that become coarser towards the top
and bottom end of the NWT. Fig.2 illustrates the grading of the computational mesh and the
fluid phases. The white line at 0.0m represents the free water surface. The cells are four times
bigger than those used in the simulations. The free surface is monitored with 11 wave gauges
spread across the flume at identical positions in the numerical and physical wave flume.

Figure 2. The computational mesh and the fluid phases.


3.2 Wave generation and absorption

The waves2Foam library is distributed with an incorporated option to generate focused waves
according to PM or JONSWAP spectra. For the current study though, the “combinedWaves”
method is used that allows the linear superposition of individual wave components at the inlet
boundary, in order to generate irregular waves (Jacobsen, 2011). This method is preferred as
more versatile, since it allows the generation of arbitrary spectra, which is essential for the
correction process. The surface elevation and velocity components are calculated for each wave
component separately and their summation results to the imposed surface elevation and
velocities on the inlet boundary. The individual wave components can be generated using
either linear or up to 5th order Stokes theory. Here, second order Stokes theory is used, since
steep waves are simulated (Vyzikas, et al., 2013). The input signal is reconstructed on the inlet
boundary from the predetermined PM spectrum using a large number of 263 wave
components for better accuracy, which focus at 7.8m downstream of the inlet and at 64s.

The wave absorption, as mentioned, in the physical flume is achieved by the paddle, whist in
the numerical flume a dissipation area, namely relaxation zone, is employed. In the relaxation
zone, the solution is partially calculated from RANS equations and from a target value.
Depending on the location in the relaxation zone, there is different weighting at the
computed and target values . The solution in the relaxation zone is calculated as
follows: (Jacobsen, et al., 2012). This allows the employment of the
relaxation zone at the inlet boundary as well, with target values the wave components from
each wave theory. This enables the absorption of any spurious reflections and facilitates the
generation for steep waves, which can potentially create local instabilities on the boundary
otherwise. The effectiveness of the relaxation zone lies on its length. Fig.3 depicts the relaxation
zones and their weighting relatively to the inlet, outlet and focal point. For the outlet boundary
a 6m relaxation zone is used that appears to absorb more than 99% of the incident wave
energy. For the inlet boundary, a 5cm relaxation is used in order to facilitate the transition from
the linearised boundary to the fully nonlinear domain, without occupying much of the domain
and influencing the final result.

Figure 3. The relaxation zone weighting in the NWT. The red colour corresponds to the target solution
and the blue to the computed one. The position of the free surface is indicated by the white line.

3.3 Convergence tests

The convergence of the simulations has been studied both in terms of mesh resolution and time
step. At the beginning, four preliminary tests were run with cell size a) 10x10mm, b) 5x5mm, c)
2.5x2.5mm and d) 1.25x1.25mm around the free surface in order to select the most appropriate
resolution. Resolution (c) was selected, as identical to (d) and with significantly lower
computational time. On the other hand, stability and computational efficiency ware ensured in
the simulation, by selecting an adjustable time step, which was controlled by the Courant–
Friedrichs–Lewy (CFL) condition (OpenCFD®, 2012). At the preliminary study, the values of

4
CFL tested were i) 0.5, ii) 0.25, iii) 0.2 and iv) 0.1, and (iv) was selected for giving identical
results to (iii), without increasing the computational effort.

Resolution (c) and CFL (iv) ware used as a baseline to perform further convergence tests with
the strongly nonlinear group, as an attempt to decrease the computational time for future more
complicated studies. The black lines and bars in Fig.4 represent the baseline case that requires
89hours for 30s of simulation at 16 Intel® Xeon® cores of 2.40GHz of processing power each.
The top part of the same graph shows the comparison of the surface elevation relative to the
focusing time between the different setups. The differences become more obvious when the
error (%) is presented. It is calculated as the difference between the tested and the baseline
setup at each time step divided by the amplitude of the crest. The average error is calculated as
the average of the absolute value of the error (%) for the total length of the timeseries. The best
combination between the average error and the computational cost is considered to be that of
3.33mm and 0.2 CFL, which will be used for future studies.

Figure 4. Comparison of the relative error and computational time between different
convergence setups.

Last but not least, various numerical schemes were examined and the most appropriate
schemes were selected by comparing the converged solution with the physical results, since
there is no documentation according to the authors’ best knowledge about the effects that the
implementation of these schemes might have.

Regarding the time integration scheme, the second order schemes “backward” and
“CrankNicholson” were tested against the default first order scheme, namely “Euler”. The
“backward” scheme was selected as more accurate than “Euler” and more stable that
“CrankNicholson”. Any other changes in the laplacian schemes and PIMPLE algorithm
revealed not important differences and therefore the default values were chosen. The version
of OpenFOAM used for this study was 2.1.x (OpenCFD®, 2012).
4. Results and validation

4.1 Simulation of linear, weakly nonlinear and strongly nonlinear wave groups

The distinguished characteristic of the present study, compared to previous CFD focusing
wave group simulations, is the spectral and harmonic analysis of the numerical result. Since, to
the authors’ best knowledge, such analysis has not been performed with an OpenFOAM-based
model so far. Since the capacity of the model is not well analysed, it was decided to start the
study with linear wave groups and gradually increase the steepness until the limiting breaking
case. All groups correspond to PM spectra with the same peak frequency of 0.6Hz. As it is
apparent the steepness was increased by increasing amplitudes of the wave components. This
resulted to the simulation of linear, weakly nonlinear and strongly nonlinear wave groups
whose linearly predicted amplitude, measured amplitude and steepness at the focal point are
shown in Table 1. In this table, the amplitude is calculated as the difference between the
highest measured surface elevation from the still water level. However, there is no consensus
on how to calculate the steepness of focused wave groups. Here, the wave length of the
focused wave at the focal time is used for the calculation of the number . The methodology for
focusing the waves is applied to each group separately until the linear part of the spectrum is
fully corrected.
Table 1. Linear amplitude estimation and steepness calculation for the focused wave groups.
Linear group Weakly nonlinear Strongly nonlinear
Theoretical amplitude (m) 0.025 0.050 0.090
Measured amplitude (m) 0.026 0.056 0.116
Measured steepness 0.038 0.083 0.172

The difference observed between the theoretical (linear) amplitude and the measured one is a
result of the nonlinear wave-wave interactions. These nonlinear phenomena alter the shape of
the spectrum, by increasing the energy content of the lower and higher harmonics. The later
becomes more obvious in Fig.5, where the timeseries of the three wave groups, normalized by
the amplitude of the strongly nonlinear group, are presented, together with the spectral
analysis for each group. The energy spectra in the same figure are normalized independently
by their own higher value each for the sake of easy comparison.

Figure 5. Comparison of the three wave groups with different steepness.

6
4.2 Analysis of the numerical results

As noted before, for each correction stage of the methodology, four different wave groups are
simulated. The suitable linear combination of the four measured spectra enables the extraction
of the linear, 2nd sum, 2nd difference and 3rd & higher order parts of the nonlinear spectrum.
The measured surface elevation can be then decomposed to the corresponding components, as
shown in the top graph of Fig.6.

The scope of the methodology for focusing waves is to match the measured spectrum with the
target one at the focal location and bring the linear components into phase. In the middle graph
of Fig.6 the spectral comparison between the measured signal, the linear part of the measured
signal and the target spectrum is presented for the strongly nonlinear group. It can be seen that
the linear part of the measured signal is with good agreement with the target spectrum. The
fully nonlinear spectrum has significantly more energy in the lower and higher harmonics than
its linear component. The lower graph shows the phase differences between the components. It
is apparent that the phases of the linear part agree well with the target values of zero phase
difference for the frequencies that correspond to the main body of the linear spectrum.

Figure 6. Analysis of the numerical result at the focal point and comparison with the target
spectrum and phases.

Similar analysis has been performed for the linear and the weakly nonlinear groups, with
much better matching with the target spectrum. The discrepancies observed after the peak
frequency in the middle graph in Fig.6 are almost absent for the lower steepness groups.
However, it was decided to present the strongly nonlinear group in order to demonstrate the
applicability of the methodology and the model in this complicated case. The results presented
in the section for the strongly nonlinear group are a product of five consecutive corrections of
the methodology.
4.3 Comparison with the physical model

A similar correction and analysis to the one described in §4.2 has been conducted
independently for the results of the physical experiment at the focal location. In this section, the
comparison between the physical and the numerical model is presented and the differences are
highlighted. The signal is truncated from -3s to +3s relatively to the focal time and the results
are compared at exactly the same location (7.8m). Again, only the comparison for the strongly
nonlinear group is discussed, as being the most complicated case.

The comparison between the physical and numerical model is shown in Fig.7. At the left part
of the figure the timeseries of the measured surface elevation is presented and at the right part,
the comparison between the components of the signal.

Figure 7. Comparison between the numerical and the experimental result at the focal point.

It can be seen from Fig.7 that the linear part of the physical and the numerical models agree
very well. Good agreement has been also achieved for the 2 nd + and 3rd + parts of the signal. On
the other hand, there is a noticeable difference between the 2nd – parts. The numerical model
overestimates the contribution of the 2nd – part before the focusing time. This is believed to be
the main reason that causes the discrepancies observed in the measured surface elevation from
-3s to -1.5s. Further analysis is required to identify the source of this effect.

5. Conclusions and future work

Focused waves are extensively used to measure extreme impacts on marine structures.
However, the focusing of especially strongly nonlinear groups based on realistic spectra has
been a challenging task for physical and numerical models. This paper presented the
application of the newly developed methodology by Stagonas et al. (2014) for accurate focusing
of waves to a numerical model. Different setups of the NWT were examined and the
methodology has proven to be applicable to a numerical model, as well as to a physical one.

8
The comparison between the physical and numerical results shows that they agree well for the
linear, weakly nonlinear and strongly nonlinear wave groups. Their analytic comparison
though, revealed some noticeable differences in 2 nd – part of the spectrum. Despite the later,
there is a very good matching between the measured and the target spectrum. In general, a
numerical flume based on waves2Foam coupled with the methodology for focusing waves
compose a robust tool for studying focused waves and extreme wave events.

The priority for future studies is to identify the reason that causes the difference at the 2nd –
part of the spectrum between the physical and the numerical model. Moreover, different wave
generation methods that are not incorporated in the current release of waves2Foam will be
implemented, namely the second order superposition of wave components and a moving wave
paddle. The impact of the inlet and outlet relaxation zones and the potential contamination of
the signal with spurious effects created in the relaxation zones require high awareness from the
users. Last but not least, there is an ongoing effort to decrease the number of wave components
that reconstruct the signal on the inlet boundary, as another attempt to make the NWT
computationally more efficient.

Acknowledgments

The authors would like to thank the INTERREG IV A project MERiFIC, the school of Marine
Science and Engineering of the University of Plymouth and the EPSRC SuperGen project
SMARTY for the financial support.

References

Chaplin, J.R., 1996. ‘On frequency-focusing unidirectional waves’, International Journal of


Offshore and Polar Engineering, Volume 6, Issue 2, Pages 131-137.
Higuera, P., Lara, L. J. & Losada, J. I., 2013. ‘Realistic wave generation and active wave
absorption for Navier-Stokes Models Application to OpenFOAM’, Coastal Engineering,
Volume 71, Pages 102-118.
Jacobsen, N. G., ©4/12/2011, Homepage of waves2Foam: OpenFOAM wiki - Contrib/waves2Foam,
Available: http://openfoamwiki.net/index.php/Contrib/waves2Foam [10 July 2014]
Jacobsen, N. G., Fuhrman, D. R. & Fredsøe, J., 2012. ‘A wave generation toolbox for the open-
source CFD library: OpenFoam®’, International Journal for Numerical Methods in Fluids,
Volume 70, Issue 9, Pages 1073-1088.
Ning, D.Z., Zan, J., Liu, S.X., Eatock Taylor, R., Teng, B. & Taylor, P.H., 2009. ’Free-surface
evolution and wave kinematics for nonlinear uni-directional focused wave groups’, Oceam
Engineering, Volume 36, Issues 15-16, Pages 1226-1243.
OpenCFD®, 2012. ‘OpenFOAM: The Open Source CFD Toolbox User Guide’. Version 2.1.1, 16
May 2012
Rapp, R.J. and Melville, W.K., 1990. ‘Laboratory measurements of deep water breaking waves’,
Phil. Trans. R. Soc. London A, Volume 331, No. 1622, Pages 735-800.
Schmittner, C., Kosleck S. and Hennig J., 2009. ‘A Phase-Amplitude Iteration Scheme for the
Optimization of Deterministic Wave Sequences’. Proceedings of the ASME 2009 28th
International Conference on Ocean, Offshore and Arctic Engineering, Volume 6, 31 May – 5 June
2009, Honolulu, USA.
Stagonas, D., Buldakov, E. & Simons, R., 2014. ‘Focusing unidirectional wave groups on finite
water depth with and without currents’, Proceedings of the 34th International Conference on
Coastal Engineering ICCE2014, 15-20 June 2014, Seoul, Korea.
Tromans, P. S., Anaturk, A.R., & Hagemeijer, P., 1991. ‘A new model for the kinematics of large
ocean waves – application as a design wave’. Proceedings of the 1st International Offshore and
Polar Engineering Conference, 11-16 August 1991, Edinburgh, U.K..
Vyzikas, T., Ransley, E., Hann, M., Magagna, D., Greaves, D., Simmonds, D., Magar V. &
Conley D., 2013. ‘Integrated Numerical Modelling System for Extreme Wave Events at the
Wave Hub Site’, Proceedings of the ICE conference: Coasts, Marine Structures and Breakwaters
2013, 18-20 September 2013, Edinburgh, U.K..
Westphalen, J., Greaves, D. M., Williams, C. J. K., Hunt-Raby, A. C. & Zang, J., 2012. ‘Focused
waves and wave-structure interaction in a numerical wave tank’. Ocean Engineering,
Volume 45, Pages 9-21.
Zhao, X.Z., Hu, C.H. & Sun, Z.C., 2010, ‘Numerical Simulation of Extreme Wave Generation
Using VOF Method’. Journal of Hydrodynamics,Ser B., Volume 22, Issue 4, Pages 466-477.

10

You might also like