WaveGFD: Data and methods for numerically solving the wave equation using a meshless Generalized Finite Differences Scheme

WaveGFD is a repository inspired by the development and analysis of meshless finite difference schemes for the wave equation in highly irregular domains, such as polygonal approximations of geographical regions. These methods' innovative approach allows to address the complexity of solving partial differential equations in highly irregular regions. They stand out for their precision and efficiency. The proposed methodology overcomes the limitations of conventional techniques, promising applicability in a broad spectrum of complex physical problems. The repository includes the methods necessary to find approximations to the solution of the wave equation, a set of test data consisting of clouds of points whose complexity varies from the unitary square (for comparison purposes) to regions that approximate actual geographic areas, examples of use, and results obtained with the proposed data and methods. WaveGFD considers the importance of having methods suitable for efficient implementations (i.e., that can be executed rapidly without the need for extensive and powerful computers) that can obtain satisfactory results when solving problems that may arise in different areas of engineering, such as civil and structural engineering (analysis of the vibrations in buildings and bridges), aerospace engineering (studies of the aeroelasticity of aircraft wings), electrical and telecommunications engineering (models of the propagation of electromagnetic waves), among others.


a b s t r a c t
WaveGFD is a repository inspired by the development and analysis of meshless finite difference schemes for the wave equation in highly irregular domains, such as polygonal approximations of geographical regions.These methods' innovative approach allows to address the complexity of solving partial differential equations in highly irregular regions.They stand out for their precision and efficiency.The proposed methodology overcomes the limitations of conventional techniques, promising applicability in a broad spectrum of complex physical problems.The repository includes the methods necessary to find approximations to the solution of the wave equation, a set of test data consisting of clouds of points whose complexity varies from the unitary square (for comparison purposes) to regions that approximate actual geographic areas, examples of use, and results obtained with the proposed data and methods.WaveGFD considers the importance of having methods suitable for efficient implementations ( i.e. , that can be executed rapidly without the need for extensive and powerful computers) that can obtain satisfactory results when solving prob-lems that may arise in different areas of engineering, such as civil and structural engineering (analysis of the vibrations in buildings and bridges), aerospace engineering (studies of the aeroelasticity of aircraft wings), electrical and telecommunications engineering (models of the propagation of electromagnetic waves), among others.
© 2024 The Author(s

Data collection
The authors generated all the data for this dataset.
To obtain the irregular clouds of points that are geometrical approximations to real geographical locations, the selection of the study regions was made considering the demands of the academic community as well as the interests of the authors, thus selecting the regions CUI (Cuitzeo Lake, Mexico), DOW (Pátzcuaro Lake, Mexico.Southern zone), MIC (State of Michoacán, Mexico), PAT (Pátzcuaro Lake, Mexico), and ZIR (Zirahuén Lake, Mexico) due to local interest of the authors, and the regions BAN (Banderas Bay), BLUE (Blue Lagoon), ENG (United Kingdom), GIB (Strait of Gibraltar), HAB (Havana Bay), TIT (Titicaca Lake), TOB, (Toba Lake), UCH (Uchinskoye Reservoir), and VAL (Valencia Lake) as internationally known examples.In all cases, Google maps was used to obtain satellite images of the regions of interest.Subsequently, the borders of the regions were drawn by using the "Contour Creator" software, within UNAMalla.The boundary coordinates were scaled and normalized to fit in the unit square [0 , 1 ] × [0 , 1 ] .Subsequently, using the "GFD Cloud Generator" software, freely published on GitHub by the authors, the respective clouds of points were obtained for each one of the regions.The authors designed and implemented the methods in Python, following the ideas presented in the related research article.Data source location • Institution: Universidad Michoacana de San Nicolás de Hidalgo.

Value of the Data
• The dataset includes a collection of clouds of points for testing problems and comparing results.The clouds are labeled, showing each interior node and boundary node.Labeling allows the problem's boundary conditions to be correctly adjusted and gives information about the interior nodes where the solution of the corresponding equation should be computed.
• The clouds of points in this dataset can be freely used to test finite difference, finite volume, finite element methods, among other techniques for solving partial differential equations.Their use is not limited to the numerical solution of the wave equation; they can be used as a test set for many different equations and problems that do not require the structure of a structured mesh.• The methods in the repository allow to compute approximations to the solution of the wave equation in highly irregular regions using clouds of points such as those in the dataset.Furthermore, small changes can be quickly adjusted to solve other partial differential equations that model the behavior of different physical phenomena.• Other methods in the repository allow one to quickly calculate the mean square error for the computed numerical solutions, appropriately graph different types of problems on the attached data set, and find the neighboring nodes of each node in a cloud of points, which is of utmost importance for the correct use of meshless generalized finite difference schemes.

Background
Building this repository of data and methods is motivated by two goals: to advance the understanding of how methods for the numerical solution of partial differential equations in irregular regions operate without the need for a mesh structure and to have a set of data that can be used to compare the performance of different methods.
On the one hand, the theoretical basis of generalized finite difference methods allows their application to numerically solve a wide variety of partial differential equations in irregular regions; however, in general, their use has been limited to areas that could be meshed with logically rectangular meshes; The methods in this repository allow their application to numerically solve the wave equation without requiring a given mesh structure.In addition, the methods presented in this repository allow to graph the results obtained by the methods directly and calculate the mean square error for numerical solutions.
In addition, having an established test data set allows direct comparisons with the proposed methods.It also provides a starting point for comparing different types of solvers in the same regions to determine the most effective and precise techniques.
Therefore, this repository is valuable for expanding and applying other methods developed to solve partial differential equations, particularly for hyperbolic equations like those presented in [1][2][3][4][5].
Methodologically, compiling these data and methods involved meticulous documentation in finite difference and finite element schemes, as well as the use of different software techniques to obtain the test data.Various algorithms and methods were implemented to ensure that the data can be applied to other engineering problems involving the solution of partial differential equations.
The final objective of this repository is to provide versatile methods and data for researchers and professionals, aiming to promote collaboration and contribute to generating advances in the field of numerical solutions of partial differential equations through robust and computationally cheap methods.

Data Description
This repository comprises 609 files, divided into three main directories and subdirectories.The structure of the repository presented is simple and makes it easy to track the information.At the outset, the directory tree has the structure shown in Fig. 1 , where the Data, Results, and Methods files are directly separated.
Of the total files, 11 files are files with Python methods, which are in the root directory and the "Scripts'' directory: • /Example_1.py .This file presents an example of the application of the generalized finite difference method for the wave equation using initial and boundary conditions: • /Example_2.py .This file presents an example of the application of the generalized finite difference method for the wave equation using initial and boundary conditions: • /Example_3.py.This file presents an example of applying the generalized finite difference method for the wave equation, simulating a water drop as an initial and reflective boundary condition.which will be used by the generalized finite difference method.
The "Data'' directory contains two subfolders, "Clouds'' and "Holes.''Each subfolder contains three folders, each with 16 clouds of points for different regions.Each region consists of four files: two figures (in EPS and PNG format) that graphically show the distribution of the nodes in each cloud of points and their labeling to determine the border nodes and the interior nodes, as shown in Fig. 2 ; and the region's data (in CVS format); this data is stored in two files: * _p.csv and * _tt.csv .These files contain the coordinates of the nodes and a triangulation correlation, respectively.Tables 1 and 2 show an example with some of the data from the "TIT'' cloud in folder 2.  The "Results'' directory contains three directories: "Example 1", "Example 2", and "Example 3".Each of these directories contains two subdirectories, "Clouds'' and "Holes,'' which, in turn, contain one directory for each of the test regions (BAN, BLU, CAB, CUA, CUI, DOW, ENG, GIB, HAB, MIC, PAT, TIT, TOB, UCH, VAL, ZIR).Within each test region directory, it is possible to find nine files with PNG graphics showing the results of the corresponding test at three different time levels ( t = 0 s, 0.5 s, 1 s), as in Figs.3-5 ; in these results, the value of the solution for each problem is shown on the z-axis.In addition, there are three videos in mp4 format containing test results at different time levels.

Experimental Design, Materials and Methods
In this work and within the repository, there are two types of data and information: the data of the clouds of points as test regions for meshless methods and a generalized finite dif- ference method for numerically solving the wave equation in irregular regions using a meshless approach; it is essential to describe how both were obtained.

Clouds of points for different space regions
The process for creating the clouds of points in the repository was the same for all regions except for the CAB and CUA regions, which are not geometric approximations of real geographic locations and can be used to compare the results with mesh-based methods.
To exemplify the process, how the point clouds were obtained for the TIT region (Lake Titicaca) is shown.
1.The geometry of the geographic region will be based on the geometries found on maps for public use.In this case, an image of the region of interest is taken from Google Earth ( Fig. 6 ). 2. Once one has an image of the region, it can be imported into the "Contour Creator" Software included with "UNAMalla" ( Fig. 7 ).3. Within Contour Creator, drawing the region's border by placing different points is possible.
These points can be placed in as much detail as desired ( Fig. 8 ). 4. As an optional step, a mesh that smoothens the boundaries can be generated directly in UNAMalla.5.The file containing the region border can now be processed using the "Cloud Generation" package, which the authors published for free on GitHub.

Cloud generation package
The "Cloud Generation'' package is a free-access package on GitHub ( https://github.com/gstinoco/Cloud-Generation ), published by the authors of this work.It allows the generation of clouds of points, with uniform and non-uniform distributions, from a region's boundary or mesh.
In all cases presented in this repository, the border of the region obtained from Contour Creator was used directly to create the point clouds.The process is as follows.
1.The region's boundary is imported from a ".con'' file (from Contour Creator), a ".mat'' file (from MATLAB), or a ".csv" file.2. The regions were scaled to enter the unit square [0 , 1 ] × [0 , 1 ] , using the following formula: max (x,y ) −min (x,y ) , p iy = p iy −min (y ) max (x,y ) −min (x,y ) Where p ix and p iy represent the coordinates of each node in x and y , respectively; min (x ) and min (y ) are the maximum value of in the x and y directions, respectively; max (x, y ) = max (max (x ) , max (y ) ) , and min (x, y ) = min (min (x ) , min (y ) ) . 3. Once the regions have been scaled, the maximum distance between two consecutive nodes is calculated; this distance will be considered the average distance between the region's nodes.4. With the border nodes, a dmsh polygon is generated; This polygon will serve as the input to create a dmsh triangulation [ 7 ]. 5. Once the region's nodes are obtained, it is essential to correctly label each one, differentiating between boundary and interior nodes.To do this, a buffered polygon is created with the original nodes, and it is checked which of the triangulation nodes are on this polygon or in its buffer.All the nodes that meet the previous condition will be labeled as boundary nodes ( Fig. 9 ).6.These nodes can be used as a first cloud of points with a uniform distribution; However, node randomization can also be performed to avoid "regular'' clouds.7.In randomization, each node moves randomly between 0 % and 5 % of its original position to create clouds with a non-uniform distribution of nodes ( Fig. 10 ). 8. Non-simply connected clouds can also be generated and randomized.When generating the dmsh triangulation, it is possible to "subtract" the region where a "hole" is present inside the boundary.From here, the process is the same as before.Examples of this procedure are depicted in Figs.11 and 12 .

A meshless approach for generalized finite difference methods
The presented meshless approach for generalized finite difference methods arises from the idea of computing a numerical solution for the wave equation problem: subject to the conditions  where is the region of interest.Since a second temporal derivative is introduced in the equation, a centered scheme can be used for temporal discretization; for an arbitrary node p 0 = (x 0 , y 0 ) ; this discretization would be of the form: It is important to note that, in this scheme, two time steps are necessary; then, following the idea presented in [ 1 ], the second time step (which would require step 0 and step −1) can be  where A , B , C, D , E, and F are given functions.For an arbitrary cloud of points, the value of Lu an arbitrary node p 0 = (x 0 , y 0 ) can be approximated using values of u at some neighbor nodes p i = (x i , y i ) , i = 1 , 2 , . . ., q .Thus, a finite-difference scheme can be applied in p_0 as a linear combination L 0 u = 0 u( p 0 ) + 1 u( p 1 ) + . . .+ q u p q = q i =0 i u( p i ) , (5) where 0 , 1 , . . ., q are suitable weights.
Applying this linear for the linear operator

Fig. 11 .
Fig. 11.Uniform cloud of points for ZIR region with a hole.

Fig. 12 .
Fig. 12. Non-uniform cloud of points for ZIR region with a hole.
• /Wave_2D.py.Main repository file.It contains the methods necessary to compute a numerical solution to the wave equation.• /

Scripts/Errors.py. Presents
the methods necessary to compute the mean square error of the calculated numerical solutions.•/Scripts/Gammas.py.It contains the routine necessary to calculate the Gamma values for the generalized finite difference method.• /Scripts/Graph.py.This file contains the methods for generating solution graphs and, where appropriate, saving them as images or videos in .mp4format.• /Scripts/Neighbors.py.It allows searching for the neighbors of each node in a cloud of points,