CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Conjugate heat transfer and reactingFoam (chtMultiRegionReactingFoam) (https://www.cfd-online.com/Forums/openfoam-solving/176881-conjugate-heat-transfer-reactingfoam-chtmultiregionreactingfoam.html)

edaymo August 29, 2016 21:19

Conjugate heat transfer and reactingFoam (chtMultiRegionReactingFoam)
 
Hello,

If anyone is interested in a solver with conjugate heat transfer + gas phase reaction capabilities, I've posted to github a hybrid of chtMultiRegionFoam and reactingFoam called chtMultiRegionReactingFoam. Steady state and transient solvers for OpenFOAM 4 and the current OpenFOAM-dev version are available (along with tutorials) at:

https://github.com/TonkomoLLC

I hope this is useful for your work. Feel free to contact me if you have any questions or comments.

Best regards,

Eric D.
Tonkomo, LLC
Twitter: @TonkomoLLC,
email: info at tonkomo.com

arvindpj August 30, 2016 11:15

Thanks!
 
I was waiting for this feature. I will test and report.
-Jay

melabbassi February 27, 2017 09:57

1 Attachment(s)
Hi Eric,

Thank you for your contribution. I have studied the solver (OpenFOAM 3) this month and benchmarked the implementation of reaction in the cht-version against rhoReactingFoam which is also based on p_rgh. So only 1 region and no conjugate heat transfer. As a test case I modelled the Sandia D flame with 2-step reaction mechanism of Westbrook and Dryer.

With the steady state version I initially couldn't get ignition. Even after adjusting the relaxation factors and setting the initial internal field temperature to 2000 K. The maximum temperature immediately drops to inlet values. I found out that the convention with the SIMPLE algorithm to use a timestep of 1 s was the issue. Unlike the navier stokes equations for steady state problems, the energy and species equations are largely dependent on time, which is probably taken from the 'virtual' timestep. Choosing high timesteps allows little energy release. By adjusting the time step to a much lower value (so that max Courant nr is about 0.2), reaction was finally possible.

Attached you'll find a plot of the temperature progression along the rotation axis. Maximum temperature and temperature rise are similar, but reaction starts a little bit more upstream with chtMultiRegionSimpleFoam. Still, it is a very good result.

The transient version of the solver is less robust. I needed 4 nOuterCorrectors instead of 1 with rhoReactingFoam to get the simulation going, leading to 4 times longer runtime. Can it be due to the pimple algorithm that is implemented differently?

Best,
Mohamed

edaymo February 27, 2017 15:57

Hi, Mohamed,

Thank you very much for such a detailed review of chtMultiRegionReactingFoam! This is great feedback, especially on your solution technique for the steady state solver and the benchmark findings.

rhoReactingFoam and chtMultiRegionReactingFoam (directly based on chtMultiRegionFoam for the PIMPLE algorithm) do indeed have different formulations for PEqn, but I do know know offhand if this the root cause of the nOuterCorrectors issue you are report. I am happy to look at your test cases in more detail if you wish to send them to me. To start with, I would want to repeat with OpenFOAM 4.x or OpenFOAM-dev. The OpenFOAM 3.x version you are using is a "beta" version of the chtMultiRegionReactingFoam solver and it was not as thoroughly tested as the versions on github.

I also note that since my initial August 2016 post I have placed on our github site two new solvers: "multiRegionReactingFoam" and "multiRegionReactingPimpleCentralFoam" (the latter based on https://github.com/unicfdlab/hybridCentralSolvers). I have tested multiRegionReactingFoam more extensively against reactingFoam and I would be very curious to know if this solver meets your expectations.

I look forward to further feedback. Thank you again for your insightful reply.

Best regards,

Eric

melabbassi March 1, 2017 09:10

Thanks for the clarity! That explains certain bugs I encountered in your beta version. I should have updated to OF 4 sooner, but it was good training exercise for me to be honest.

I will send you the case files for chtMultiRegionReactingFoam and rhoReactingFoam. Thank you very much for your effort! I will also run them again on OF 4.

The reason I used the p_rgh based solvers was because I wanted to make a consistent comparison and wasn't aware of the psi based multiRegionReactingFoam. Thanks for uploading it!

I'll keep you updated.

skibenochek April 24, 2017 13:13

Hello!
 
Thank you for your work! Can I use your solver with OpenFoam 2.3.0?

edaymo April 24, 2017 14:14

Re: Hello!
 
Hi,

Thanks for the feedback!

The same programming principles apply for coding a CHT+reaction solver for OpenFOAM 2.3.0, but i think you will find that the solvers on my GitHub page will not compile as-is for OF2.3.

I've got a version of the CHT+reaction solver for OpenFOAM 3.0.x that I haven't gotten around to putting on GitHub yet, but I have not yet created one for OF 2.3/OF2.4.

Please contact me directly (e.g., private message, or info at tonkomo.com) if you would like my assistance to port this CHT+reaction solver to OF2.3. Thanks!

Best regards,

Eric

Swagga5aur October 2, 2017 11:01

OFV5 multiregionsimplereactingfoam error
 
Hello Eric

First of all I would like to thank you for this solver and the continuous work, as I used it for my master thesis concerning modelling a reformation process with external heating.

I noticed an error in the OF 5.0 multiRegionSimpleReactingFoam with respect to the createFluidFields.H dictionary missing the following line

Code:

    reactionFluid[i].setTurbulence(turbulence[i]);
after the following code

Code:

    Info<< "    Adding to turbulence\n" << endl;
    turbulence.set
    (
        i,
        compressible::turbulenceModel::New
        (
            rhoFluid[i],
            UFluid[i],
            phiFluid[i],
            reactionFluid[i].thermo()
        ).ptr()
    );

Prior to this addition I got a turbulence Ptr error when trying to solve a turbulence reaction model.

Just wanted to let you know :)

Best regards
Lasse

edaymo October 2, 2017 15:48

Re: OFV5 multiregionsimplereactingfoam error
 
Dear Lasse,

Thank you very much for the bug report. Indeed, you are correct, and all of the multiRegionSimpleReactingFoam solvers (OF4, 5, dev, 1706, 1612+) have been updated with the reported fix to setTurbulence. I checked the other solvers (e.g., transient multiRegionReactingFoam, chtMultiRegionFoam, etc.) just to be sure, but I didn't find this bug outside of mutliRegionSimpleReactingFoam.

I really appreciate your bringing this matter to my attention. I'm also really happy to learn that this solver helped with your Master's thesis, and that you got good results with it.

Best regards,

Eric

Swagga5aur October 2, 2017 16:15

Hello Eric,

No problem, glad to be of help.

I am experiencing some convergence issues with the multiRegionSimpleReactingFoam compared to the transient solvers multiRegionReactingFoam and reactingFoam.

Not sure if something else is missing in the solver but I'll look into it and post if I find any issues :).

I believe the issue may be with the implementation of the OF5.0 EDC combustion model.

Best regards,
Lasse

edaymo October 2, 2017 16:28

Hello, Lasse -

I don't typically use the steady state solver, rather, I tend to use the transient solver with LTS.

One idea is to try the same problem with simpleParcelReactingFoam, which is a single region, steady state solver with chemistry, albeit with rhoReactingThermo. Assuming you can come up with reasonable BC's for a non-CHT case, this approach might narrow down whether the problem is with the multiRegion solver, or if the problem is with some other model or the setup.

Good luck and feel free to contact me if I can be of assistance.

Best regards,

Eric

sante_junior April 1, 2023 01:36

Hi Mr. El Abbassi
I read with great attention your exchanges with Eric Daymo and your work on conjugate heat transfer through a rotary kiln. I was very impressed with your results. I am looking to reproduce a work almost identical to yours in a cement kiln using local refractory materials where I will use biogas and LES as a turbulence model.

Please can you share your test cases with me so that I can use them as a tutorial?

Sincerely Sante Junior BISSAĻ

dlahaye April 2, 2023 16:33

We documented the reverseBurner tutorial test case and made our report available at https://mega.nz/file/eBcxWKgJ#CXhpWd...5O3CHRBqIX6XKk . Possibly there is valuable information here.

Kind wishes, Domenico.

sante_junior April 4, 2023 01:13

Quote:

Originally Posted by dlahaye (Post 847457)
We documented the reverseBurner tutorial test case and made our report available at https://mega.nz/file/eBcxWKgJ#CXhpWd...5O3CHRBqIX6XKk . Possibly there is valuable information here.

Kind wishes, Domenico.

Hi Domenico
Thank you for your quick reply. I will take a closer look.
Sincerely, Sante Junior BISSAI

sante_junior April 23, 2023 03:58

1 Attachment(s)
Quote:

Originally Posted by sante_junior (Post 847537)
Hi Domenico
Thank you for your quick reply. I will take a closer look.
Sincerely, Sante Junior BISSAI

Hi Domenico Lahaye
Your document has helped me a lot. But I am facing a new dilemma. I have two regions (fluid and solid) but when I run my case, the second region is not read and my calculation spits out and generates me errors.
I attach the image of the error to my message.

I really need your help

edaymo April 23, 2023 17:24

Hi,
If I read your printStack correctly, it seems the problem is with one of your patches, and the exact reason fo the solver crash is that there is no field named phi (phi is the mass flux, kg/m2/s). For a solid we do not expect convection and thus it is not surprising that there is no field named phi. The printStack also refers to the inletOutlet BC, which is not a good BC for a solid region, since inletOutlet requires the surfaceScalarField phi... that as mentioned does not exist in a solid region.
I hope this analysis is helpful.
Best regards,
Eric

mactone June 19, 2023 22:25

Hi Eric,

Thank you for sharing the code. In the reverseBurner case, simple burner interacting with wall can be solved. I wonder what's the difference between this chtMultiRegionReactingFoam with official openfoam9 chtMultiRegionFoam?

If the solid is composed of multiple layers of materials, how to set it? Any tutorial or examples?

Thank you.

edaymo June 19, 2023 23:22

Hi Mactone,

chtMultiregionReacting foam is outdated: it really only served a purpose through OpenFOAM 5.x. In OpenFOAM 6 chemical reaction capability was added to chtMultiRegonFoam and it's capability is the same as chtMultiRegionReactingFoam.

I also maintained multiRegionReactingFoam also at TonkomoLLC's GitHub site until this year (psiReactionThermo, p instead of p_rgh equation). However, now OpenFOAM-dev (what I presume will be called OpenFOAM 11 in a month or two) has the ability to mix and match conjugate heat transfer, chemical reactions, buoyancy and so much more through the use of modules. Thus, OpenFOAM "11" will surely have the same capabilities as multiRegionReactingFoam.

To answer your other question... If the solid is comprised of multiple thin layers you can use the kappaLayers feature in the conjugate heat transfer boundary condition. If the layers are thicker and you wish to model the solid domain, then I think the old OpenFOAM 6 multiRegionHeater tutorial can show you how to setup multiple adjacent solid layers. I don't think this tutorial has been included in newer versions of OpenFOAM.

Happy foaming!

Best regards,
Eric

mactone June 20, 2023 04:41

Hi, Eric,

Great appreciated for the lightening speed reply.

It looks the OpenFOAM is becoming better and better with your support. Really looking forward OpenFOAM 11, though I use OpenFOAM-v2206 now.

Meanwhile, I can use multiRegionReactingFoam at TonkomoLLC's GitHub site to solve mix and match conjugate heat transfer, chemical reactions, buoyancy problems. Is that correct? It seems the chtMultiRegionFoam could also solve reactingFlow, I still don't know the difference between chtMultiRegionFoam and multiRegionReactingFoam.


Last, for the kappaLayers, I've used the boundary below for the furnace wall in the reactingFoam, though using the externalWallHeatFluxTemperature will change the combustion chamber temperature, the simulation results only show the fluid temperature. If I use multiRegionReactingFoam, I could get the transient temperature change of the furnace wall?

Code:

Walls
{
        type            externalWallHeatFluxTemperature;

        mode            coefficient;

        Ta              constant 300.0; // ambient temperature [K]
        h              constant 10.0; // Heat transfer coefficient [W/m^2/K]
        thicknessLayers (0.05 0.02); // Layer thicknesses [m]
        kappaLayers    (0.04  50); //Layer thermal conductivities [W/m/K]
      // It's isowool-1260 5cm (0.04 W/m/K) + steel plate 2cm (50 W/m/K)

        kappaMethod    fluidThermo;

        value          $internalField;
    }


mactone June 20, 2023 05:17

Quote:

Originally Posted by edaymo (Post 852078)
Hi Mactone,

chtMultiregionReacting foam is outdated: it really only served a purpose through OpenFOAM 5.x. In OpenFOAM 6 chemical reaction capability was added to chtMultiRegonFoam and it's capability is the same as chtMultiRegionReactingFoam.

I also maintained multiRegionReactingFoam also at TonkomoLLC's GitHub site until this year (psiReactionThermo, p instead of p_rgh equation). However, now OpenFOAM-dev (what I presume will be called OpenFOAM 11 in a month or two) has the ability to mix and match conjugate heat transfer, chemical reactions, buoyancy and so much more through the use of modules. Thus, OpenFOAM "11" will surely have the same capabilities as multiRegionReactingFoam.

To answer your other question... If the solid is comprised of multiple thin layers you can use the kappaLayers feature in the conjugate heat transfer boundary condition. If the layers are thicker and you wish to model the solid domain, then I think the old OpenFOAM 6 multiRegionHeater tutorial can show you how to setup multiple adjacent solid layers. I don't think this tutorial has been included in newer versions of OpenFOAM.

Happy foaming!

Best regards,
Eric


Hi, Eric,

I try to use the reverseBurner case in tutorial with multiRegionReactingFoam.
It showed FOAM FATAL ERROR:
Code:

Unknown patchField type compressible::turbulentTemperatureRadCoupledMixed for patch type mappedWall
It's the error due to T boundary condition, I am not sure it gas or solid side error.

I wonder if you could provide me a sample case file for multiRegionReactingFoam and multiRegionSimpleReactingFoam respectively.

Great appreciated.

Best,
Mactone


All times are GMT -4. The time now is 04:05.