intro story Coast / Estuary

Coast / Estuary

Coastal systems are among the most dynamic physical systems on earth and are subject to a large variety of forces. The morphodynamic changes occurring to coastlines worldwide are of great interest and importance. These changes occur as a result of the erosion of sediments, its subsequent transport as bed load or suspended load, and eventual deposition. 
 
Estuaries are partly enclosed water bodies that have an open connection to the coast. Estuaries generally have one or more branching channels, intertidal mudflats and/or salt marshes. Intertidal areas are of high ecological importance and trap sediments (sands, silts, clays and organic matter).
Within the Delft3D modelling package a large variation of coastal and estuarine physical and chemical processes can be simulated. These include waves, tidal propagation, wind- or wave-induced water level setup, flow induced by salinity or temperature gradients, sand and mud transport, water quality and changing bathymetry (morphology). Delft3D can also be used operationally e.g. storm, surge and algal bloom forecasting. 
 
On this discussion page you can post questions, research discussions or just share your experience about modelling coastal and/or estuarine systems with Delft3D FM. 
 

** PLEASE TAG YOUR POST! **

 

 

Sub groups
D-Flow Flexible Mesh
DELWAQ
Cohesive sediments & muddy systems

 

 

Message Boards

SWAN source

MG
Markus Gross, modified 8 Years ago.

SWAN source

Youngling Posts: 7 Join Date: 12/10/11 Recent Posts
Hi,

I need to compile SWAN, since the executables that come with Delft3D do not run on my system (IA64). I understand I cannot just plug in a "standard" SWAN executable? Could you please provide me with guidance on which version to use and what changes I have to make? Ideally a patch? That would be great! I downloaded the latest tagged release of delft3d, 5.00.09.1882.

Many thanks in advance!

Regards,

Markus
MG
Markus Gross, modified 8 Years ago.

RE: SWAN source

Youngling Posts: 7 Join Date: 12/10/11 Recent Posts
I have now plugged in an executable I compiled from swan 40.72ABCDE from the "ancient code" section in the swan repository and it is running happily. Not sure yet if it produces sensible results though yet. One thing I worry about is the extension of the output precision of swan in the D3D version (mentioned elsewhere). Does anybody know the details?

Many thanks!

Markus
Adri Mourits, modified 8 Years ago.

RE: SWAN source

Yoda Posts: 1221 Join Date: 1/3/11 Recent Posts
Hi Markus,

I don't think you need to recompile SWAN. I think the 32-bit version is used by accident. Using the 64-bit version may already solve your problem.

After compiling Delft3D-WAVE, an install script is executed, copying not only wave.exe but als copying a set of SWAN executables (32- and 64-bit versions) to the install directory "mycode/bin/lnx/swan". Also script "mycode/src/third_party_open/swan/scripts/swan_install.sh" is copied to "mycode/bin/lnx/swan/scripts/swan.sh". When WAVE is going to execute SWAN, the script named "swan.sh" is executed, assuming it is defined in one of the directories listed in environmentparameter "PATH". This "swan.sh" script contains the lines:
MACHINE_TYPE=`uname -m`

if [ $mpirun -eq 1 ]; then
  if [ ${MACHINE_TYPE} = 'x86_64' ]; then
    SWANEXEC=${D3D_HOME}/swan/bin/swan_4072ABCDE_del_l64_i11_mpi.exe
  elif [ ${MACHINE_TYPE} = 'i686' ]; then
    SWANEXEC=${D3D_HOME}/swan/bin/swan_4072ABCDE_del_l32_i11_mpi.exe
  else
    echo "Error \"uname -m\" does not return x86_64 or i686"
  fi
else
  if [ ${MACHINE_TYPE} = 'x86_64' ]; then
    SWANEXEC=${D3D_HOME}/swan/bin/swan_4072ABCDE_del_l64_i11_omp.exe
  elif [ ${MACHINE_TYPE} = 'i686' ]; then
    SWANEXEC=${D3D_HOME}/swan/bin/swan_4072ABCDE_del_l32_i11_omp.exe
  else
    echo "Error \"uname -m\" does not return x86_64 or i686"
  fi
  #
  # swan40.72AB and newer runs parallel using OpenMP, using the total number of cores on the machine
  # To force the number of parallel processes, remove the "#" in front of the following line and adjust the number
  # export OMP_NUM_THREADS=1
fi

If you replace in this piece of script "x86_64" by "IA64" (or whatever your system returns when executing "uname -m"), the 64-bit SWAN version will be used instead of the 32-bit version.

Summerising:
Find out where the "swan.sh" is located on your system that is being used. It may be overwritten with a default script every time you compile Delft3D.
Edit this "swan.sh" to use the 64-bit SWAN version on your system.

Regards,

Adri
MG
Markus Gross, modified 8 Years ago.

RE: SWAN source

Youngling Posts: 7 Join Date: 12/10/11 Recent Posts
Hi Adri,

many thanks for your reply!

Unfortunately IA64 machines cannot execute EM64T (or AMD64 or x86_64) code. At least not without the compatibility libraries, and I'd rather not do that (don't know if debian ships them even, SuSE used to in the professional distribution)

I had to edit the script already of course, because otherwise it would have not executed anything, even with my "external" SWAN build.

Hopefully I have some time soon to do some more detective work, i.e. look at the files generated, from what I figure the "coupling" is simply done by writing and reading files? So hopefully I can reverse engineer the changes at least with regard to output precision. Would be much easier to simply apply a patch of course ;-)

Sorry for the late reply, but I had already given up hope to get any reply .... so was not actively checking anymore.

Regards,

Markus
Adri Mourits, modified 8 Years ago.

RE: SWAN source

Yoda Posts: 1221 Join Date: 1/3/11 Recent Posts
Hi Markus,

Yes, all communication of data between SWAN, WAVE and FLOW is via files.

Regards,

Adri