Fluids

Fluids

Topics related to Fluent, CFX, Turbogrid and more.

scalar mass conservation issues

    • grayg34
      Subscriber

      I am using a UDS equation to model scalar transport inside a chamber. I am using a udf for a custom flux function. The flux consists of F_FLUX to get the standard convective flux plus a constant value representing secondary effects on the scalar.

      The chamber has one inlet with a specified velocity of the primary flow and specified scalar concentration of 1, and one outlet. The primary flow is constant propert air which I have converged to a steady state solution in a previous simulation. I am only solving the scalar equation in a transient simulation. I am calculating the mass balance relative to the scalar mass flow rate at the inlet. I have writen an udf report to calculate the mass storage rate of the scalar in the chamber. 

      When I run the simulation on an orthogonal cartesian mesh the mass conservation of the scalar equaton is very good (imabalance <1e-8 %). When I run the simulation on a polyhedral mesh the mass imbalance is approximately 1.3%. I have tried reducing the timestep size, increasing the iterations per timestep, changing the discritization methods and changing the multigrid to F-cycle as suggested in the user manual. None of the above have improved the mass conservation. I have checked the steady state mass balance of the primary flow on the polyhedral mesh and it is well converged. 

      I have run the transient simulation without the udf flux, using the default 'mass flow rate' instead. The scalar mass conservation on the polyhedral mesh in this configuration is approximately 0.03%, much higher than the cartesian mesh but still acceptable. 

       

      Are there any suggestions for improving the mass conservation on the polyhedral mesh? 

    • Federico
      Ansys Employee

      Hello Geoff, 

      how is your mesh quality for the poly mesh?

    • grayg34
      Subscriber

       

      I believe the mesh quality is okay. I have attached a screean shot of the mesh on the center plane. The geometery is a simple rectangular cavity. Is there any particular mesh quality metric you would like to see? 

      The mesh was originally created in STAR-CCM+, exported as a tecplot file, then the tecplot was imported into Fluent.

      I have also tried a version of the poly mesh seen below without any prism layers and the mass conservation was even worse than with the prism layers.

      • Federico
        Ansys Employee

        Generally, we recommend maximum Surface skewness < 0.7-0.8 and minimum Orthogonal Quality > 0.1

    • grayg34
      Subscriber

      There are 12 out of 478k cells with an orthogonal quality below 0.1 and no skewness exceeding 0.7.

      I will try refining the mesh within Fluent but the current mesh quality appears reasonable. 

       

      • Federico
        Ansys Employee

        Based on this information, my first suggestion would be to improve the mesh. This doesn't necessarily mean you need to refine it, but rather that you should seek to achieve good quality throughout.

    • grayg34
      Subscriber

      I have made some minor changes to my udf code and how it calculates the flux at boundaries and that seems to have improved the mass imbalance, especially on the poly mesh. The mesh does not appear to have been the root cause. 

Viewing 4 reply threads
  • The topic ‘scalar mass conservation issues’ is closed to new replies.