A Simple Numerical Modelling of Refraction and Shoaling Wave Using VBA Excel

Wave propagation from the deep water to the shoreline experiences a transformation process. Their transformation, frequently, affects coastal processes such as erosion and sedimentation. In addition, their wave force can also damage the coastal infrastructure. There are three processes of wave transformation that should be modelled, namely, shoaling, refraction, and wave breaking. It is difficult to calculate the wave transformation manually due to the complexity of computation. Therefore, it should be handled using such commercial software, which is mostly very expensive. In order to cope with the problem, a simple numerical model of wave transformation, based on the finite difference method, is carried out using VBA Excel as a programming language. The advantage of using VBA Excel is the easy accessibility due to its integration with Microsoft Office. The aim of this project is to create a simple software for modelling refraction and shoaling waves that can be developed for educational purposes. The outcome of making this software is to meet the availability of wave modelling software in supporting the development of education and teaching in the ocean engineering field. The results of the numerical model are verified using the modelling results of Horikawa and Koutitas.


Introduction
In this paper, wave transformation modelling of combined refraction and shoaling based on a mild slope equation is carried out using time-independent finite difference method written in Visual Basic for Application (VBA). The aim of this paper is to develop a simple software that is useful for educational purposes in learning and understanding the wave propagation process in the open sea. In general, it can be admitted that developing software by the lecturers for commercial purposes is quite rare in Indonesia. Only a few people devote themselves to it. One of them, for example, is Triatmadja, who developed commercial software Waternet for pipe network modelling [1]. Therefore, an effort to start making and developing software products is an important task.
Koutitas and Radianta have developed a two dimensional numerical model for the refraction and shoaling wave using finite difference methods based on the wave number and wave energy conservation [2,3]. Koutitas applied simple iterative calculation for obtaining wave length (L), while Triatmadja used an explicit equation to estimate wave number (k) proposed by Hunt [2][3][4]. Le Roux, et al. developed WAVECALC software, i.e., an Excel-VBA spreadsheet to calculate the parameters using linear-Airy equation without using partial waves differential equation discretization [5]. Hutahean conducted various simulation related to 2D wave refraction and difcraction based on linear and nonlinear term in unsteady state condition [6,7].

Methods
The governing equation of the wave refraction and shoaling is the modified form of the mild slope equation [2,3,8]. The two-dimensional numerical method used in this present software is timeindependent finite difference for giving the steady state solution [2,3]. The model is designed only for refraction, shoaling, and breaking in the open sea without any obstacles during its propagation from the deep sea to the shoreline.
An iterative Newton Raphson method is applied to compute the wave number, where the first derivative of wave dispersion relation is required. The wave breaking criterion uses simple approximation, where the maximum possible steepness is H/d=0.78 [2]. The wave height and angle on the open boundary should be assumed, whereas the value of the shoreline boundary is set as zero (null). In addition, the bathymetry data must be in positive value. This program is written using VBA which is integrated in Microsoft Excel as part of the registered Office 365. The model result is then compared and validated to other models from the previous researchers [2,9].  The angle of wave propagation is in degrees (°) due to more convenience for the users. The angle of perpendicular to the coastline is set as 90° as the axis. An angle less than 90° means that the direction of the wave is tilted from the left of the axis, while an angle which is greater than 90° denotes that the direction of the wave is tilted from the right of the axis.  Figure 3 illustrates that each cell (A1 to K11) represents a grid of discretization. The first column (A1-A11) and the last column (K1-K11) denote the deep sea (deep water boundary) and shallow water depth (shoreline boundary), respectively. Therefore, in this present software, the wave propagates from

Result and Analysis
The first validation is to compare the present model result with Horikawa's result [9]. Figure 3 shows three panels consisting of the bathymetry data, and the results, i.e., wave height and wave angle. Figure  4 illustrates the vectors of wave height that represent the transformation process, i.e., refraction, shoaling, and breaking wave. The parameter data input for the first validation are: H0 = 0.02 m, T= 1.2 s, dx = dy = 0.1 m, bottom slope = 1/50, deep sea = 0.12 m, wave angle = 60°. The columns and rows presented in Figure 4 were reduced in order to fit and easily read in this paper size.  In order to further verify the comparison, the location of the breaking line should be investigated. Therefore, the wave height profile along the wave propagation is retrieved and presented in Figure 6. It can be seen that the breaking line, where the wave height starts to break, is located at 4.5 m from the open sea boundary, which is consistent with the Horikawa's result [9].    The second validation is to compare the present model result with Koutitas's result [2]. Figure 7 shows the bathymetry as input data and the model results, i.e., wavelength, wave height, and wave angle that has been calculated numerically in VBA and shown in Excel spreadsheet. The parameter data used are: H0 = 1 m, T= 10 s., dx = dy = 10 m, deep sea = 10 m. Figure 8 displays the vector of wave height that represents the wave transformation from the deep sea to the shoreline, i.e., refraction, shoaling, and breaking wave.

Discussion
The model performance shows that the present program is reliable, where from the comparison to others researcher's results shows a relatively good agreement. Those results indicate that the present software is capable of modelling refraction, shoaling, and breaking waves.
The advantage of using the present software compared to other software is that the users can see all parameters results which were calculated in each grid, which is represented by the cell of the sheet in Excel. As a result, the users are not only able to see the result of the wave height that is symbolised in vector arrow format, but also see the other parameters such as wave number, wavelength, wave celerity, wave group celerity, and the wave angle. In that way, the users can easily observe the transformation of wave propagation from deep water to the shallow water until reaching the coastline.
On the other hand, the output of other software is usually only one parameter such as wave height or wave celerity, and they do not have facility or tool to observe all parameters in the computational domain.

Conclusion
The development of simple software for modelling refraction, shoaling, and breaking was carried out based on a mild slope equation using two-dimensional finite difference method, written in VBA Excel. Based on the performance, the software is capable of modelling refraction, shoaling, and breaking waves. The comparison result between the present programs with the other previous researchers' result is in close agreement.