Welcome, Guest
Username: Password: Remember me

TOPIC: Divergence with salinity

Divergence with salinity 7 months 3 weeks ago #43320

  • AVL
  • AVL's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 3
  • Thank you received: 1
Hello Opentelemac,

I'm working on simulating the salinity in the estuary of the Loire with TELEMAC2D.
In the Atlantic, the boundary is a level prescribed and upstream I've tried two cases: prescribed discharge and prescribed level.
Also, the model contains some culverts and a constant evaporation during the simulation.
The fact is that the salinity is diverging after some hours of simulation, the value become highly negative (GRACJG (BIEF) : EXCEEDING MAXIMUM ITERATIONS: 1000 RELATIVE PRECISION: NaN
GRACJG (BIEF) : EXCEEDING MAXIMUM ITERATIONS: 200 RELATIVE PRECISION: NaN).
I've trying several parameters in the cas file for the salinity, trying to delete culverts, to initialize the salinity in the whole domain, to modify the scheme for the resolution of the equations, sometimes I can postpone the divergence but the duration of the calculation is around 2 months and at any given time it's diverging.
Furthermore, I've tried to delete the evaporation and to reduce the duration of the simulation to 7 days and it's working but if I move a parameter of the salinity the simulation may diverge.
Maybe the evaporation cannot be taken into account when there is some salinity?
Do any of you have a suggestion for improvement?

PS: I cannot put the mesh and the bathymetry on the net but you can access to my cas, liq and conlim files.
In the cas file, the slash lines have been tested.

AVL
Attachments:
The administrator has disabled public write access.

Divergence with salinity 7 months 3 weeks ago #43330

  • pham
  • pham's Avatar
  • OFFLINE
  • Administrator
  • Posts: 1460
  • Thank you received: 563
Hello,

Which release do you use?

I have not had any experience in using DENSITY EFFECTS = YES, in particular combined with culverts + evaporation.

I would first try 3 combos and see if they work or not:
- DENSITY EFFECTS = YES + culverts without evaporation (RAIN OR EVAPORATION = NO),
- DENSITY EFFECTS = YES + no culvert + evaporation (RAIN OR EVAPORATION = YES),
- DENSITY EFFECTS = NO + culverts + evaporation (RAIN OR EVAPORATION = YES). For this last combo, salinity would be a passive tracer, maybe easier.

When getting NaN (Not a Number), what is recommended in other posts (you can use the search engine of this forum) is to use debug options. Computations will be longer but when getting a NaN, it stops and may give you the line where this NaN first appears:
See e.g. the S10.gfortran.debug configuration in the $HOMETEL/configs/systel.edf.cfg configuration file, in particular the flag fflags_debug_gfo for gfortran compiler.
fflags_debug_gfo: -g -Wall -fcheck=all -fbacktrace -fbounds-check -finit-integer=-1 -finit-real=nan -ffpe-trap=invalid,zero,overflow

It will show in which subroutine the issue/nan/segfault occurs, the first suspicious line and may help you to change something in your computation.

Anyway, if modelling salinity in an estuary, I would recommend you to rather move to TELEMAC-3D.

Hope this helps,

Chi-Tuan
The administrator has disabled public write access.
Moderators: pham

The open TELEMAC-MASCARET template for Joomla!2.5, the HTML 4 version.