Search code examples
modelica

How to represent not a number in Modelica


I have a piece of code in Modelica, where I have to assign 1 to the variable if its output from calculation is 0/0 or inf. I have found how to represent infinity through Modelica.Constants.inf. However, I could not find how to represent 0/0, I have searched for NaN but I could not find it. Please help me..


Solution

  • Is not possible yet, see the discussion here: https://trac.modelica.org/Modelica/ticket/2048