Hello Claire,
What do you mean by "debug mode":
- using keyword DEBUGGER = 1, which prints the calls to main subroutines?
- or what nicogodet suggests (as me many times).
For the 1st idea, indeed, you will still get NaN and the computation may continue with many NaN written in the listing.
But with the 2nd solution, as written many times on this forum, if a segmentation fault or a NaN (Not a Number) occurs, you should use a debug configuration with debug options to investigate.
See e.g. the S11.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.
And in particular, the computation will stop as soon as a segfault or a NaN accurs.
Anyway, if you do not want to take into account the diffusion of tracers, using DIFFUSION OF TRACERS = 0 is not a good idea, you should rather let it to its default value (= 1) and set every COEFFICIENT FOR DIFFUSION OF TRACERS to 0. Depending on the advection scheme, DIFFUSION OF TRACERS = 0 may not only vanish diffusion but also source terms.
If your issue still occurs, it would be interesting to know which version you use and provide at least the steering file.
Hope this helps,
Chi-Tuan