Please note that the content of the MESH User Support space continues to be updated as we transition to new tools.
Support and contact: MESH@ec.gc.ca | GitHub: https://github.com/MESH-Model
IEEE errors using GNU compiler
When running MESH compiled using the GNU compiler (e.g., gcc, gfortran, the gcc implementation of mpifort), you might see a note printed after running a simulation:
Program has terminated normally.
Note: The following floating-point exceptions are signalling: IEEE_UNDERFLOW_FLAG IEEE_DENORMAL
Normal exceptions
IEEE_UNDERFLOW_FLAG is triggered when the result of an expression exceeds the precision of the variable being assigned the value. For most MESH variables this means a number smaller than E-38. This exception will also trigger IEEE_DENORMAL. This pair of flags can be triggered by parts of CLASS and WATDRN. The underflow error is typically inconsequential and should have no impact on the results of the simulation. It can be ignored.
Bad exceptions
New versions of MESH are tested against these exceptions: IEEE_OVERFLOW_FLAG, IEEE_INVALID_FLAG, and IEEE_DIVIDE_BY_ZERO. If a run finishes with any of these exceptions triggered, you should debug the setup to identify errors in the configuration files, including MESH_drainage_database.r2c.
IEEE_OVERFLOW_FLAG is triggered when the result of an expression exceeds the precision of the variable being assigned the value. For most MESH variables this means a number larger than E+38. This exception will also trigger IEEE_DENORMAL.
IEEE_INVALID_FLAG is triggered by invalid operations, such as trying to take sqrt(-1.0). This can occur by bad parameterization and/or invalid drainage properties.
IEEE_DIVIDE_BY_ZERO is triggered when a number is divided by zero. This is more likely to occur by invalid drainage properties than bad parameterization. A common cause of the error is a cell that has invalid drainage properties, with drainage area, grid area, channel length, and/or channel slope set to zero.