When I enable energy equations code stops after dem setting

Hi, here is my case.I ran this case with mfix-21.4.
movingbed.zip (529.2 KB)
When I enable the energy equations code stops after dem setting.


It works fine if I uneable energy equations.
I want to know how to solve it.
Thank you!

This is an interesting case.

I see that you are using DMP. Whenever you have a DMP job failure, the first thing to try is running in serial.

When I run serial, I get these errrors:

shot-2022-03-24_12-42-35

the solver reports 2026 errors, this is a huge number! Part of the issue is that the solver is reporting this for each particle, leading to a large number of error messages. But another issue is that if this error is fatal, the solver should have terminated after the first error.

The solver is complaining that the mass fractions for the species in solids phase 2 (coal) don’t add up to 1. But you have no species defined! I think in this case, the test should be skipped.

The popup tells us that the message is coming from line 143 of des/set_ic_dem.f. Looking at the relevant section of code:

! Check that the species mass fractions are specified.
         IF((ENERGY_EQ .AND. C_Ps0(M) == UNDEFINED) .OR.               &
            SPECIES_EQ(M)) THEN
            IF(.NOT.COMPARE(sum(DES_X_s(NP,1:NMAX(M))),ONE)) THEN
               WRITE(ERR_MSG, 2001) trim(iVal(NP)), trim(iVal(M))
               CALL LOG_ERROR()
            ENDIF
         ENDIF

 2001 FORMAT('Error 2001: The initial species mass fraction for ',     &
         'particle ',A,/'does not sum to one. Verify that the IC ',    &
         'region containing this particle',/'has the solids species ', &
         'mass fractions defined: IC_X_s(ICV,',A,',:).')

So the error message is a bit misleading, it does not match the test in the code - the test is only checking for the sum of IC_X_s == 1 when species eq are enabled, OR energy equations are enabled and C_Ps0 (constant specific heat) is undefined. The problem is not that the species mass fractions don’t add up to 1, the problem is that there are no species at all, AND there is no value to use for specific heat for the phase. If you’re not defining species, you have to specify constant values for the phase properties.

If you get a message referring to a variable like C_Ps0 and you don’t know what it means, click the ‘search’ icon search

to bring up the keyword browser
shot-2022-03-24_12-55-52

then “Locate control” will take you to the relevant part of the GUI.

you have to change that to “Constant” and supply a value. (Or define the phase in terms of species and mass fractions). If you don’t use species, you probably will need to specify a few other values for the phase (mol wt, etc)

– Charles

1 Like

Also, please note that if you click on the underlined file name in the error message ( des/set_ic_dem.f in this case), the editor window will jump to the file and line in question. Then you can see exactly what code is triggering the error.

1 Like