Why is the amount of CO2 and H2O produced from methane combustion both 0?

I have included the chemistry of methane combustion in my 2D fluidized bed simulation, but the mass fraction and molar fraction of CO2 and H2O in the simulation results are 0. Why is this? Could it be that methane combustion does not produce these two substances?
3.3 2Ddem Gidaspow Fe2O3+O2+CH4-reqiliu - chemistry.zip (60.4 MB)

Defining the chemical reaction equation in the Chemistry pane is not sufficient. You need to code the reaction rate in usr_rates.f and make sure you have checked “Enable user-defined subroutines” in the Model pane and build the custom solver.

Thanks, I would also like to ask how to code the reaction rate?

And will these two build options make any difference when building a custom solver?
image

Yes. You should always enable “Build solver in parallel”, this simply speeds up the build process. But the simulation still runs at the same speed.

Selecting SMP builds a solver which can run on multiple cores, while without that selected you get only serial (single-thread) support. SMP may make some simulations go faster but more threads don’t always lead to more speed (due to the need for threads to communicate and syncronize with each other), see for example this post


And my custom solver build fails, why is that? Thank you!

Thanks for your answer, but I don’t know why I often fail when I build solver in parallel, can you help me to find the problem?

And I can’t find usr_rates.f where to set,can you tell me?Thanks!

What version of MFiX are you running? The error message refers to f2pywrappers which is a library we no longer use. I suspect the problem may be due to non-English characters in your file or file name but since you did not upload a full bug report I cannot say for sure.

I could try to debug the build failure but it would be better if you could upgrade MFiX.

usr_rates.f is a file, not a keyword. Please refer to the MFiX manual for setting up chemical reaction cases, and look at some of the tutorials which include reactions.

Were you looking for this?

As Jeff said: ““Enable user-defined subroutines” in the Model pane”
You can also use the keyword search feature to help locate controls - click on the spyglass icon in the top of the MFiX frame
shot-2023-10-04_09-12-19

Thanks,I’m running version 21.4 of mfix, and I don’t have any non-English characters in my filenames.So how do I fix the solver build failure, can I only upgrade mfix?
And how do I code the file usr_rates.f for reaction rates?Is that the mfix manual in the picture?

The Theory guide is a good document but I’m referring to the MFiX User Manual, which is linked in the MFiX “Help” page, you can either view it online or locally
shot-2023-10-04_10-34-05

The URL is https://mfix.netl.doe.gov/doc/mfix/latest

There are many reasons to upgrade to the latest MFiX, we are constantly developing the code, fixing bugs and adding new features. If you can’t do that for some reason, we do try to support older versions, but this is a lower priority for us.

If you want help with the build failure please go to the main MFiX menu and select “Submit bug report” and upload the .ZIP file here. Thanks.

Thanks,this is my bug report.
2ddem_2023-10-05T095546.387658.zip (58.9 KB)

It would really be best if you could upgrade MFiX, you are missing out on several years of bugfixes and improvements. We do not guarantee support for older versions.

However, I am able to reproduce the compilation failure using mfix 21.4.
There was a change to the f2py utiltity (part of Numeric Python, numpy) which broke the mfix build. As I have mentioned, we have completely transitioned away from using this approach, due to a large number of error messages, failures, incompatibilities, etc.

If you downgrade numpy in the mfix 21.4 environment, it should revert to a working version:

C:> conda activate mfix-21.4
(mfix-21.4) C:> conda install -c conda-forge numpy=1.19

(replace conda command with mamba if using mamba)

Thanks, I read the MFiX manual carefully, but I still don’t know how to set the chemical reaction rate usr_rates.f. Do I need to learn the Fortran language and then write my own code as a subroutine?

I updated the mfix version to 23.4 and it still fails when building the solver! This is my error report, please help me to see what the problem is, developers!
2ddem_2023-10-08T113645.499300.zip (7.2 MB)

  1. Please use “Submit bug report” to create the ZIP file. It will skip certain files. When you zip up the project directory, it includes files like movie files (.mp4) which take up a lot of space and are not needed for troubleshooting.

  2. I’m not sure what version you are running, 23.4 does not exist yet and 23.3 is coming out later this week. I think you are on 23.2.

  3. It looks like you have made a project directory called

D:\Mfix\3.3 2Ddem Gisapow Fe2O3+O2+CH4-requilu - chemistry\

In a perfect world, all software would be able to handle path names containing spaces, but many scripts and programs will fail with this sort of directory name. Especially with the - character in there, this is going to look like a command option (- chemisty) more than a file name.

I suggest trying with a different directory (folder) name.

– Charles

PS

I just tried this with the upcoming 23.3 code, it works, so it looks like perhaps the ‘space-in-name’ bug has been fixed. However you should be aware that file and directory names like this are often a source of problems because they require extra quoting.