Having trouble with starting mfix exa

Hi developers!

I’m trying to simulate biomass char combustion in 40m furnace using PIC method. I tested in mfix and I want to convert into mfix exa.
Can I use mfix exa by just installing it with superbuild option?
I want to use stl file for furnace geometry and use my gpu for calculation.

I followed the ‘Building and Running MFIX-Exa’ (Building and Running MFIX-Exa on an ubuntu laptop)
but I got stuck at using the csg library. I’m sure I did something wrong so I want to start over step by step from the beginning.
How should I start?
Thank you.

This is the error message that I got.

After projection (with small dt modification):
max(abs(u/v/w/p)) = 0 0 0 0
Evolving particles on level: 0 … with fluid dt 0.0001439861301
Segfault
See Backtrace.0 file for details

MPI_ABORT was invoked on rank 0 in communicator MPI_COMM_WORLD
with errorcode 11.

NOTE: invoking MPI_ABORT causes Open MPI to kill all MPI processes.
You may or may not see output from other processes, depending on
exactly when Open MPI kills them.

First of all, can you confirm that you were running the case benchmarks/05-cyl-fluidbed/Size0001?
Second, can you paste your Backtrace.0 file in here.

Yes I was working on that case.

Host Name: hyu3
=== If no file names and line numbers are shown below, one can run
addr2line -Cpfie my_exefile my_line_address
to convert my_line_address (e.g., 0x4a6b) into file name and line number.
Or one can use amrex/Tools/Backtrace/parse_bt.py.

=== Please note that the line number reported by addr2line may not be accurate.
One can use
readelf -wl my_exefile | grep my_line_address’
to find out the offset for that line.

0: ./mfix(+0x6f6e78) [0x55b3a0032e78]
?? ??:0

1: /lib/x86_64-linux-gnu/libc.so.6(+0x42520) [0x7fd09b71e520]

2: ./mfix(+0x4036f4) [0x55b39fd3f6f4]
?? ??:0

3: ./mfix(+0x668cc1) [0x55b39ffa4cc1]
?? ??:0

4: ./mfix(+0x6fbcd) [0x55b39f9abbcd]
?? ??:0

5: /lib/x86_64-linux-gnu/libc.so.6(+0x29d90) [0x7fd09b705d90]

6: /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x80) [0x7fd09b705e40]

7: ./mfix(+0x7a1b5) [0x55b39f9b61b5]
?? ??:0

===== TinyProfilers ======
main()
mfix_solve
REG::DEM PARTICLE SOLVE
mfix_dem::EvolveParticles()
particles_computation

This occurred when I tried to use geometry.csg file.

well that’s not terribly helpful… Are you on an Ubuntu OS? Did all of the libraries install correctly?

Yes I’m using Ubuntu OS and I installed all libraries correctly. I solved the csg problem by adding
mfix.geometry = “csg” line

But I’m having trouble in setting the PIC simulations. There is no information in mfix-exa documentation - Solids model - PIC model settings.

Ah, that’s annoying. Sorry, this slipped our checks because the case it’s really a csg case, but we make it easy to turn into one. I’ll add that to my original post.

re PIC docs, yes, it’s still on our TODO list. As you are aware, this was a development code that is currently becoming a production code. As such, we still have some missing pieces. Here is a “default” PIC inputs block as a starting point:

#_______________________________________________________________________
# PIC model settings
#
pic.solve = solid0

pic.verbose = 1

pic.max_iter = 3

pic.beta = 3.0
pic.pressure_coefficient = 100.0

pic.close_pack = 0.60
pic.parcels_per_cell_at_pack  =  17.90493  

pic.small_number = 1.0e-8

pic.damping_factor = 0.40
pic.damping_factor_wall_tangent = 0.9
pic.damping_factor_wall_normal  = 0.6

pic.velocity_reference_frame = 0.50

pic.advance_vel_p = 0.5

pic.initial_step_type = nth_eps
1 Like

Thanks for your kind reply.

But what do you mean ‘missing pieces’ ??
Am I able to run PIC char combustion simulation by using gpu and user defined codes with this current Mfix-exa version?

Missing piece here being PIC documentation.

re PIC char combustion simulation… that is a complicated question. First let me warn you that there is a problem in the chemistry portion of the code that @RobertoPorcu is feverishly working on. If you run it right now, it will not give correct results. But I expect that might be sorted out by the next release. Second, setting it up will be challenging because we really haven’t put anything out there about how to use the UDFs yet. I have a very simple one for CO2 adsorption that I can share. @YupengXu has one for biomass gasification that he may be able sanitize and share. If you give us the reactions you are trying to model, one of the three of us might be able to help (but no promises).

1 Like

Okay I got it.
I will ask you more if I have questions while I study mfix-exa.
Just in case, I’ll upload my mfix file that I want to convert into mfix-exa. I really need someone’s help.
biomass yang PIC 2.zip (80.0 MB)
Thank you so much.

Hi,
I am Junsung’s PI. Could you please share with him or me the basic example for CO2 absorption? This will allow him to practice compiling the solver with UDF first. Please send the file via email to dlee46@hanyang.ac.kr.
Thank you!

I’ll just post it here for the benefit of everyone/anyone. Thanks to @RobertoPorcu for fixing my mistake, this reasonably recreates the results from our paper and Li et al.'s paper that was originally from the experiment of Janssen (MS thesis). If you tweak IC of the solid temperature and BC of the gas and wall temperature, you can make it match the experiment better, but, IMO, this is close enough for all of the uncertainties present in this work.

A couple of warnings

  • The reaction rate UDF will change at the next release, it’s already changed in develop. You can copy the relevant lines of code over into the new blank UDF in the future, but if you just try to replace it with this one, you won’t be able to compile.
  • We still think there is a bug in the chemistry part of the code that hasn’t been resolved yet.

Li-Janssen.zip (18.4 KB)

1 Like

ah, I should add that I am running this on 24 cores because I don’t really have an incentive to use less than 128. But you can set amr.max_grid_size_x = 1024 and run on 8 cores without slowing down much at all. Or you can set amr.max_grid_size_y = 1024 and run on just 3 cores, it’s slower but still reasonable.

1 Like

Thank you so much!!
Additional question: does mfix-exa use gpus as a dafault?? Or do we need to change some settings?
I’m currently working on my PIC - cold flow simulation but it looks like it only use cpus.

The code has to be built by specifying your GPU type as an option, please see our documentation. The HPC specific build instructions are getting a little stale, but still may be useful to you as well.

1 Like

How can I set the parcel weight in mfix-exa? Do we have to calculate it by using cell size and pic.parcels_per_cell_at_pack value?

+) Should I write a new topic for additional questions, or is it okay to continue commenting as I’m doing now?

You got it. @jmusser set it up like that so that if you have a distribution of particle sizes, you will get a distribution of stat. weights, ie increasing particles per parcels with decreasing dp.

(you can keep posting in this thread to keep it all together)

I’m trying to run this simple pyrolysis example. But the error message says that “Fluid molecular weight was not specified”.
Do I need to specify the fluid’s molecular weight in this setting?
Pyrolysis.zip (4.4 KB)

I solved this. I annotated the model options line. My mistake.