3
$\begingroup$

I have a question about SWAN wave model, I tried to ask it at the SWAN mailing list, but with no luck, so I'm asking here.

First of all I have to admit I'm not a professional SWAN user. All the knowledge of SWAN I have I have received from the user manual and google. Neither am I an oceanologist, so I can't say I really understand what the model does. However, I need to use it.

I used GridBuilder to generate the grid, that is why I'm using curvilinear grids (the grid is actually a rectnagle, but GridBuilder generates only curvilinear grids when exporting for SWAN).

I'm trying to compute wave properties using this task:

PROJECT 'p1' 'r1'
SET NAUTICAL
MODE DYN TWODimensional
PROP BSBT

CGRID CURVILINEAR 90 86 EXC -9999 CIRCLE 10 0.03 0.55 40
READGRID COORDINATES 1 'data.grd' 4 0 0 FREE
INPGRID BOTTOM CURVILINEAR 0 0 90 86 EXC -9999
READINP BOTTOM 1 'data.bot' 4 0 FREE

GEN2
WIND vel=20 dir=270
BLOCK 'COMPGRID' NOHEADER 'results.mat' LAY 3 XP YP BOTLEV WIND HSIG HSWELL VEL WATLEV DEPTH PER WLEN OUT 20200101.000000 5 MIN

COMPUTE NONSTAT 20200101.000000 10 SEC 20200101.003000
STOP

If I understand the syntax correctly, then SWAN should compute wave propagation during 2.30 hours using wind with speed 20 m/s that blows from the West. However, when I check the results in MATLAB, I see that HSIG is about 0.0012 or something like that. This looks strange to me, since I'd expect waves to be much higher when the wind speed is 20 m/s which is a gale wind.

I have computed the same properties for a whole day and the results are almost equal. These are the lines of the second task that differ from the first one:

BLOCK 'COMPGRID' NOHEADER 'results.mat' LAY 3 XP YP BOTLEV WIND HSIG HSWELL WATLEV VEL DEPTH PER WLEN OUT 20200101.000000 30 MIN

COMPUTE NONSTAT 20200101.000000 10 MIN 20200102.000000

However, period is about 2.0126634 and wave length is 5.0730591. This parameter combination looks strange to me.

Did I miss something while composing the task? Thank you for help in advance.

data.grd: https://pastebin.com/RnsRssiY data.bot: https://pastebin.com/zbg4eySL

$\endgroup$
  • 1
    $\begingroup$ I don't know SWAN well enough to read the input file, or two know it's quirks very well, but one thing I'd suggest is to check what timestep you're using. One of the strengths/weaknesses of SWAN (delete according to viewpoint) is that it's numerically stable at (nearly?) any timestep, but if the TS is too long it may not give the right answers. $\endgroup$ – Semidiurnal Simon Jan 19 at 21:31
  • $\begingroup$ Hi, @SemidiurnalSimon ! I tried to compute the output in stationary mode, which AFAIK, assumes there is no timestep at all, and the result was the same. $\endgroup$ – Xanx Jan 20 at 20:51
5
$\begingroup$

You need to use the following line in your model setup:

COORDINATES SPHERICAL

Otherwise SWAN will try to calculate wave properties on a curvilinear grid with coordinates provided in meters. In your present case, the computational area is 0.47 m x 0.24 m instead of degrees longitude and latitude.

| improve this answer | |
$\endgroup$
  • $\begingroup$ Hello Ingvar! Thanks for the answer. I tried adding this line and it worked, now the waves are is 1-2 meters high. I will check everything and accept your answer. Can you please tell me how you have determined that the area is so small? I used GridBuilder and selected a relatively large area. $\endgroup$ – Xanx Feb 13 at 21:16
  • $\begingroup$ Hi! I should have clarified - your coordinates are correct and the area is large enough when you use the option COORDINATES SPHERICAL (0.47 degrees lon x 0.24 degrees lat is approx 27 km x 27 km). Otherwise SWAN assumes you are providing coordinates in meters (0.47 m x 0.24 m). $\endgroup$ – Ingvar Lukas Feb 14 at 6:48
  • 1
    $\begingroup$ Oh, now I see. SWAN uses meters by default but GridBuilder has generated spherical meshes for me. $\endgroup$ – Xanx Feb 14 at 8:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.