## 2 Materials and Methods
### HEC-RAS Hydrodynamic Mathematical Model  
HEC-RAS (version 6.6) is an open-source hydraulic modeling software developed by the U.S. Army Corps of Engineers for simulating water flow through natural rivers and channels. The software enables users to perform various types of hydraulic analyses, including one-dimensional steady and unsteady flow modeling, two-dimensional unsteady flow modeling, coupled 1D-2D unsteady flow routing, sediment transport computations, and water quality modeling [24].  
The two-dimensional unsteady flow solver in HEC-RAS implements an implicit finite volume algorithm, allowing for larger computational time steps compared to explicit methods. The software accommodates both unstructured and structured computational meshes, with the former being the primary design focus. For computing flow fields in 2D meshes, HEC-RAS offers two computational approaches: the full momentum (Saint-Venant) equations and the diffusion wave model. The first of these mathematical models was used in this study.  
The governing 2D Saint-Venant equations in their non-conservative form are expressed as:  
Continuity equation:  
\[\frac{\partial H}{\partial t}+\frac{\partial(hu)}{\partial x}+\frac{\partial( hv)}{\partial y}=q \tag{1}\]  
Momentum equations:  
\[\frac{\partial u}{\partial t}+u\frac{\partial u}{\partial x}+v\frac{\partial u }{\partial y}=-\frac{\partial H}{\partial x}+v_{t}\left(\frac{\partial^{2}u}{ \partial x^{2}}+\frac{\partial^{2}u}{\partial y^{2}}\right)-c_{f}u+fv+\frac{ \tau_{\text{{\tiny{max}}}}}{\rho h} \tag{2}\]  
\[\frac{\partial v}{\partial t}+u\frac{\partial v}{\partial x}+v\frac{\partial v }{\partial y}=-\frac{\partial H}{\partial y}+v_{t}\left(\frac{\partial^{2}v}{ \partial x^{2}}+\frac{\partial^{2}v}{\partial y^{2}}\right)-c_{f}v+fu+\frac{ \tau_{\text{{\tiny{avg}}}}}{\rho h} \tag{3}\]  
where  
\(t\)--time (s);  
\(u\), \(v\)--velocity components in \(x\) and \(y\) directions (m\(\cdot\)s\({}^{-1}\));  
\(q\)--source/sink flux term (m\({}^{3}\cdot\)s\({}^{-1}\cdot\)m\({}^{-2}\));  
\(H\)--water surface elevation (m asl);  
\(h\)--water depth (m);  
\(g\)--gravitational acceleration (m\(\cdot\)s\({}^{-2}\));  
\(v_{t}\)--horizontal eddy viscosity coefficient (m\({}^{2}\cdot\)s\({}^{-1}\));  
\(c_{f}\)--bottom friction coefficient (-);  
\(f\)--Coriolis parameter (s\({}^{-1}\));  
and terms like \(\tau_{\text{{\tiny{m}}}}\)/\(ph\) represent surface wind stresses in the \(x\) and \(y\) directions, respectively, and are crucial in simulations of wind surges in shallow reservoirs such as lagoons.  
In order to solve the set of Equations (1)-(3), the initial and boundary conditions are needed. The initial condition was determined by the hydrostatic state, with the horizontal water table corresponding to the initial water level in the Gulf of Gdansk and Vistula Lagoon. The boundary conditions were chosen in the following way. At open boundaries of the Gulf of Gdansk, the sea water level (representing storm surges) was forced. The other boundaries are located along the shore line of the lagoon and they were treated as closed boundaries. The observed wind direction and speed at the Nowa Pasleka meteorological station (Figure 1) were used as the input data for the simulation. The inflow of rivers entering into the lagoon was neglected.