render_disturbances parameter setting has no effect on a swell.
Swell generally consists of long waves with no fine detail.
Jumping to the swell.dat file, we see that the swell will have an
average (not maximum) amplitude of 4m and an average length of 200m.
This average amplitude is measured from the height of a calm surface,
so the average peak-trough distance will be twice this number (8 meters in this example).
A good rule of thumb is that the height should not exceed 10% of the length, otherwise
the results start to look ``unnatural''.
number_disturbances 1
render_disturbances black
grid_type swell
n_point_x 512
n_points_y 512
dx 5.0
dy 5.0
surface_file swell_surface.dat
generate_file yes
description_file swell.dat
end
The swell.dat file contains:
height 4.
length 200.
long_width 0.25
trans_width 0.13
angle 70
random_number_seed 0
end
The next two numbers in the swell.dat file control the "focus" of the swell.
long_width controls how much variation there is along the direction of travel (longitudinal) of swell, while trans_width controls the variation crosswise (transverse) to the direction of travel. For example, entering 0.01 for both of these number will produce a nearly perfect sine wave moving in the direction of the swell, with no variation in the transverse direction (sort of corrugated effect). Increasing long_width value will break up the sine wave in the direction of travel, but still leave the transverse direction without any variation. Both of these numbers should be greater than (not equal to) zero, and typically less than 1 to generate realistic swells. Then values shown in the example are typical numbers for producing realistic results. The parameter angle sets the direction of travel for the swell, in this case 70 degrees, which is just a bit north of west.
Return now to the ocean file of this example. Since swell is generally large with no fine resolution, we have set a coarse resolution (5m) with a large overall grid size (512 points times 5 m = 2560 meters). This fits with the rule of thumb that the overall grid size should be about 10 times as large as the swell length. Note that once again, grid size is a power of 2. Beyond this we once again provide the name of a file to store the surface in, specify that it should be created rather than read in, and that additional information about the swell is in the file swell.dat.