Lock-up


\begin{picture}(18,0.12)
\thicklines
\put(0,0){\line(1,0){17}}
\put(0,0.1){\line(1,0){17}}
\end{picture}

             |    STATionary  [time]                             |
COMPute   ( <                                                     > )
             |                              | -> Sec  |          |
             | -> NONSTat  [tbegc] [deltc] <     MIn   > [tendc] |
                                            |    HR   |
                                            |    DAy  |

\begin{picture}(18,0.12)
\thicklines
\put(0,0){\line(1,0){17}}
\put(0,0.1){\line(1,0){17}}
\end{picture}

This command orders SWAN to start the computation(s).


If the SWAN mode is stationary (see command MODE), then only the command COMPUTE should be given here (no options!).
If the SWAN mode is nonstationary (see command MODE), then the computation can be

To verify input to SWAN (e.g., all input fields such as water depth, wind fields, etc.), SWAN can be run without computations (that is: zero iterations by using command NUM STOPC MXITST = 0).


In the case MODE NONSTATIONARY several commands COMPUTE can appear, where the wave state at the end of one computation is used as initial state for the next one, unless a command INIT appears in between the two COMPUTE commands. This enables the user to make a stationary computation to obtain the initial state for a nonstationary computation and/or to change the computational time step during a computation, to change a boundary condition etc. This also has the advantage of not using a hotfile since, it can be very large in size.


For small domains, i.e. less than 100 km or 1 deg, a stationary computation is recommended. Otherwise, a nonstationary computation is advised.


For a nonstationary computation, a time step of at most 10 minutes is advised. (When you are choosing a time step larger than 10 minutes, the action density limiter (see command NUM) becomes probably a part of the physics.)


Also, the time step should be chosen such that the Courant number is smaller than 10 for the fastest (or dominant) wave. Otherwise, a first order upwind scheme is recommended in that case; see command PROP BSBT. If you want to run a high resolution model with a very large time step, e.g. 1 hour, you may apply multiple COMPUT STAT commands.


For a sufficiently small time step ($\leq$ 10 minutes), no more than 1 iteration per time step is recommended (see command NUM ... NONSTAT [mxitns]).


STATIONARY a stationary computation is to be made.  
[time] time level for which the stationary run is to be made, the format is:  
  1 : ISO-notation 19870530.153000  
  2 : (as in HP compiler) '30$-$May$-$87 15:30:00'  
  3 : (as in Lahey compiler) 05/30/87.15:30:00  
  4 : 15:30:00  
  5 : 87/05/30 15:30:00'  
  6 : as in WAM 8705301530  
  This format is installation dependent. See Implementation Manual or ask the  
  person who installed SWAN on your computer. Default is ISO-notation.  
NONSTATION a nonstationary computation is to be made.  
[tbegc] the start date and time of the nonstationary computation, format see [time].  
  Default: the time read from a hotfile (see command INIT HOTSTART), or the  
  end time [tendc] of the previous nonstationary computation or the [time]  
  of the previous stationary computation in the same SWAN run (if any).  
[deltc] the time step of the nonstationary computation, the unit is indicated in the  
  next option:  
  SEC unit seconds  
  MIN unit minutes  
  HR unit hours  
  DAY unit days  
[tendc] the end time of the nonstationary computation, format see [time].  


\begin{picture}(18,0.12)
\thicklines
\put(0,0){\line(1,0){17}}
\put(0,0.1){\line(1,0){17}}
\end{picture}

                 | -> FREE
HOTFile 'fname' <
                 | UNFormatted

\begin{picture}(18,0.12)
\thicklines
\put(0,0){\line(1,0){17}}
\put(0,0.1){\line(1,0){17}}
\end{picture}

This command can be used to write the entire wave field at the end of a computation to a so-called hotfile, to be used as initial condition in a subsequent SWAN run (see command INITIAL HOTSTART) This command must be entered immediately after a COMPUTE command.


The user may choose the format of the hotfile to be written either as free or unformatted. If the free format is chosen, then this format is identical to the format of the files written by the SPECOUT command (option SPEC2D). This hotfile is therefore an ASCII file which is human readable.


An unformatted (or binary) file usually requires less space on your computer than an ASCII file. Moreover, it can be readed by a subsequent SWAN run much faster than an ASCII file. Especially, when the hotfile might become a big file, the choice for unformatted is preferable. Note that your compiler and OS should follow the same ABI (Application Binary Interface) conventions (e.g. word size, endianness), so that unformatted hotfiles may transfer properly between different OS or platforms. This implies that the present and subsequent SWAN runs do not have to be carried out on the same operating system (e.g. Windows, Linux) or on the same computer, provided that distinct ABI conventions have been followed.

'fname' name of the file to which the wave field is written.  
  Note: for parallel MPI runs, more than one hotfile will be generated depending  
  on the number of processors (fname-001, fname-002, etc.).  
FREE the user indicates that the hotfile is written with free format.  
  This option is default.  
UNFORMATTED the user indicates that the hotfile is written unformatted.  


\begin{picture}(18,0.12)
\thicklines
\put(0,0){\line(1,0){17}}
\put(0,0.1){\line(1,0){17}}
\end{picture}

STOP

\begin{picture}(18,0.12)
\thicklines
\put(0,0){\line(1,0){17}}
\put(0,0.1){\line(1,0){17}}
\end{picture}

This required command marks the end of the commands in the command file. Note that the command STOP may be the last command in the input file; any information in the input file beyond this command is ignored.

The SWAN team 2024-03-19