General

General

How can I stop the Fluent solver cleanly from UDF once a certain condition has been met?

    • FAQFAQ
      Participant

      To stop a run based on a certain condition, you can set the number of iterations for the run to zero, by calling the integer RP variable that carries this information. This should stop Fluent more elegantly than a bailout. To do this you have issue the scheme variable RP_Set_Integer command to set the value of ‘sol/iterations’ to 0 so that Fluent thinks the run is over, ie: RP_Set_Integer(“sol/iterations”,0);