Reducing Simulation Time

I am simulating a 2D reactor in CFD-DEM with a gas-solid reaction. I began by simplifying the project as much as possible. However, when I initiated a simulation using the DMP option on our university cluster for a basic 2D reactor with one reaction and a small number of particles over 1000 seconds, it took approximately 15 days to complete the calculations.

Do you have any advice on how I can reduce the calculation time? Thank you in advance.

Please provide additional details about your simulation: number of cells, number of particles, time step, number of cores etc. You can also attach your project files if you think there is an issue with the setup.

I am currently simulating 500 fixed particles, but my objective is to increase the number of particles. I am working with threads per core=1 and CPUs per task=20, and the time step is set to 10^-2.

Additionally, I am currently simulating only one reaction with a simple rate of reaction. However, in reality, I should incorporate two more reactions with complex rate expressions.

I have attached all the required files.

Thank you.

usr_rates_des.f (3.2 KB)
usr_drag.f (3.1 KB)
usr1_des.f (1.7 KB)
Project-mfix22.3.1.mfx (11.8 KB)

Your project file has:

#!MFIX-GUI BUILD_DMP = 0
#!MFIX-GUI BUILD_SMP = 1

If you have access to a compute cluster, you probably want to run in DMP mode rather than SMP.

Furthermore I’m getting a build error:

[ 99%] Building Fortran object CMakeFiles/udfs.dir/tmp/mouna/usr_rates_des.f.o
/tmp/mouna/usr_rates_des.f:70:14:

   70 |     DES_RATES(Reaction_1) = 8d-4
      |              1
Error: Legacy Extension: REAL array index at (1) [-Werror]

I think you forgot to include 'species.inc'

You can find attached the new file usr_rates_des.f. It does not produce any building errors as I have included species.inc.

Thank you in advance.

usr_rates_des.f (12.0 KB)

Your setup doesn’t seem physical. You setup a constant gas density of 42.5 kg/m^3 at atmospheric pressure and a temperature of 900C, made up -f hydrogen and steam. You should use an ideal gas law. Please double check your fluid properties.

Thank you Jeff.

When using the ideal gas law condition, I encountered the following error: “DT < DT_MIN. Recovery not possible”. what should i do in this case?

Please try the attached.
I switched to ideal gas law and increased the max inlet velocity factor that was driving the time step down. I am also using explicit coupling for DEM, and decreased the spring stiffness, decreased the DES time step factor and increased the neighbor search call so the DEM time step is larger (this is OK since you are freezing particle’s position). Note that the granular temperature is not the same as the thermodynamic temperature. I reset it to zero, although it doesn’t make any difference since you are freezing particle’s position. The attached simulation runs fine until time=1000s, when you turn on the reaction. My guess is the reaction rate is too large.

Project-mfix22.3.1.mfx (13.9 KB)

3 Likes

I tried to decrease the reaction rate, and it worked!

Thank you very much!