CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > SU2

How to understand the Recombination Tables in CMutationTCLib.cpp??

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree2Likes
  • 1 Post By wallym
  • 1 Post By CatarinaGarbacz

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 16, 2023, 02:45
Default How to understand the Recombination Tables in CMutationTCLib.cpp??
  #1
New Member
 
Cherith Lavisetty
Join Date: Jan 2023
Location: Urbana, IL
Posts: 11
Rep Power: 4
Cherith is on a distinguished road
Could someone explain how to write the recombination tables for a specific mixture in CMutationTCLib.cpp in SU2. I would like to use a carbon mixture and their mechanisms which we have compiled in the Mutation library but couldn't figure out how to write the recombination tables.

Can someone take the example of the Air-5 mixture and explain what each element in the matrix refers to and how the values of the constants decided.

It would be really helpful if someone can explain it soon, Thanks in Advance .

[ATTACH][ATTACH]Recombination tables in CMutation.jpg[/ATTACH][/ATTACH]
Attached Images
File Type: jpg air-5 mixture.jpg (13.0 KB, 11 views)
File Type: jpg Mechanism of air-5.jpg (34.9 KB, 10 views)
Cherith is offline   Reply With Quote

Old   July 17, 2023, 07:20
Default
  #2
Member
 
Catarina Garbacz
Join Date: Jun 2020
Posts: 30
Rep Power: 6
CatarinaGarbacz is on a distinguished road
Hello Cherith.


My colleague Jacob implemented this, I'll ask him to reply here.

Catarina
CatarinaGarbacz is offline   Reply With Quote

Old   July 17, 2023, 12:51
Default
  #3
New Member
 
Cherith Lavisetty
Join Date: Jan 2023
Location: Urbana, IL
Posts: 11
Rep Power: 4
Cherith is on a distinguished road
Thank You!
Cherith is offline   Reply With Quote

Old   July 25, 2023, 18:45
Default
  #4
Senior Member
 
Wally Maier
Join Date: Apr 2019
Posts: 124
Rep Power: 8
wallym is on a distinguished road
Hi Cherith,
Are you referring specifically to the catalytic wall recombination?

If so, the tables are formulated as follows:

CatRecombTable(Species#,0) = +1, -1, or 0
This determines if the species is created, destroyed or nothing happens. For these models the recombination assumes all monoatomic species (N and O) would recombine into N2 or O2.

So CatRecombTable(3,0) = 1 essentially is saying the 4th species is created...which in Mutation++ notation is N2.


CatRecombTable(#Species,1) determines the species corresponding to its creation or destruction.

So in the example above:
CatRecombTable(3,0) = 0 is basically saying the N2 species that is created depends on the recombination of species #0..which is N.

I hope this helps,
Wally
wallym is offline   Reply With Quote

Old   September 21, 2023, 18:44
Default
  #5
New Member
 
Cherith Lavisetty
Join Date: Jan 2023
Location: Urbana, IL
Posts: 11
Rep Power: 4
Cherith is on a distinguished road
Thank You So Much for the clarification.

Also I wanted to ask if Implicit Time Integration is available yet for the Simulations using Mutation++??

Sincerely
Cherith
Cherith is offline   Reply With Quote

Old   September 22, 2023, 07:37
Default
  #6
Member
 
Catarina Garbacz
Join Date: Jun 2020
Posts: 30
Rep Power: 6
CatarinaGarbacz is on a distinguished road
Implicit time integration is not available with Mutation++
CatarinaGarbacz is offline   Reply With Quote

Old   April 12, 2025, 06:06
Default
  #7
New Member
 
Yufan CHEN
Join Date: Apr 2025
Location: Hong Kong
Posts: 14
Rep Power: 2
yufan is on a distinguished road
Quote:
Originally Posted by CatarinaGarbacz View Post
Implicit time integration is not available with Mutation++
Hello Catarina!

I am the beginner of SU2, I got a little bit curious about why this not available, seems the native SU2 library with NEMO-NS solver is able to use implicit method. Is this caused by API of mutation++? Can i add the MARS entry species into native SU2 lib to make implicit method works?

Best Regards
Yufan
yufan is offline   Reply With Quote

Old   April 12, 2025, 09:07
Default
  #8
Senior Member
 
Wally Maier
Join Date: Apr 2019
Posts: 124
Rep Power: 8
wallym is on a distinguished road
Hi Yufan,

The mutation++ does not yet have the required Jacobians for the implicit solver to work. I believe the developers of M++ are working on creating these.

And yes, you should be able to create new species and reaction tables for the Martian atmosphere. As a fair warning, the native implicit solver can be quite unstable and is actively being investigated.

Wally
yufan likes this.
wallym is offline   Reply With Quote

Old   April 13, 2025, 11:21
Default
  #9
New Member
 
Yufan CHEN
Join Date: Apr 2025
Location: Hong Kong
Posts: 14
Rep Power: 2
yufan is on a distinguished road
Quote:
Originally Posted by wallym View Post
Hi Yufan,

The mutation++ does not yet have the required Jacobians for the implicit solver to work. I believe the developers of M++ are working on creating these.

And yes, you should be able to create new species and reaction tables for the Martian atmosphere. As a fair warning, the native implicit solver can be quite unstable and is actively being investigated.

Wally
Hello Wally,

I am very glad to see your reply! Your work is very impressive!

I actually a little bit confused about the gas model of Mars_19(mutation++), I change the setting of a case that can be worked successfully with air_5 (mutation++)
from:

GAS_MODEL= air_5
GAS_COMPOSITION= (0.0, 0.0, 0.0, 0.77, 0.23)

to:

GAS_MODEL= Mars_19
GAS_COMPOSITION= (0.0, 0.0,0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.262, 0.0, 0.0, 0.132, 0.0, 0.526, 0.0, 0.08)

after i run with the code, the terminal output error exit information with:

Error in "CNEMOEulerSolver::CNEMOEulerSolver(CGeometry* , CConfig*, short unsigned int, bool)":
-------------------------------------------------------------------------
Oops! The CNEMOEulerSolver static array sizes are not large enough.
------------------------------ Error Exit -------------------------------

It is very weird that I choose NEMO_NAVIER_STOKES solver, but the error information is from CNEMOEulerSolver, and it seems the database of Mars_19 is not directly available in the SU2-NEMO solver? This suffered me a lot >_<, are there any suggestions to solve this?

Best Regards
Yufan
yufan is offline   Reply With Quote

Old   April 14, 2025, 06:41
Default
  #10
Member
 
Catarina Garbacz
Join Date: Jun 2020
Posts: 30
Rep Power: 6
CatarinaGarbacz is on a distinguished road
Hi Yufan


when I first posted about implicit not working it was in 2023, and NEMO developers have been working on it so I lot of progress has been done since then.

When using mutation++, the mixture does not need to be available within SU2.

In your case, you use mutation++ with Mars19 - this is ok.

The issue is, when using 19 species (instead of 5) you will have a total of 24 conserved variables (n_species + momentum_x+ momentum_y + momentum_z + total_energy + vibrational_energy).


SU2 is programmed to have a MAXNVAR < 24, see for example file CSysMatrix.hpp:
HTML Code:
  enum : size_t {    MAXNVAR = 20  }; /*!< \brief Maximum number of variables the matrix can handle. The static                 size is needed for fast, per-thread, static memory allocation. */
This is just a protection so you can go into the code, search for every instance of defining MAXNVAR (there might be other files) and make sure it's larger than your total number of variables, in this case 24.


(and just for clarifying better, CNEMONavierStokes uses the implementation in CNEMOEulerSolver as it is an extension of it, hence why the error refers to the Euler class)
yufan likes this.
CatarinaGarbacz is offline   Reply With Quote

Old   April 15, 2025, 07:19
Default
  #11
New Member
 
Yufan CHEN
Join Date: Apr 2025
Location: Hong Kong
Posts: 14
Rep Power: 2
yufan is on a distinguished road
Quote:
Originally Posted by CatarinaGarbacz View Post
Hi Yufan


when I first posted about implicit not working it was in 2023, and NEMO developers have been working on it so I lot of progress has been done since then.

When using mutation++, the mixture does not need to be available within SU2.

In your case, you use mutation++ with Mars19 - this is ok.

The issue is, when using 19 species (instead of 5) you will have a total of 24 conserved variables (n_species + momentum_x+ momentum_y + momentum_z + total_energy + vibrational_energy).


SU2 is programmed to have a MAXNVAR < 24, see for example file CSysMatrix.hpp:
HTML Code:
  enum : size_t {    MAXNVAR = 20  }; /*!< \brief Maximum number of variables the matrix can handle. The static                 size is needed for fast, per-thread, static memory allocation. */
This is just a protection so you can go into the code, search for every instance of defining MAXNVAR (there might be other files) and make sure it's larger than your total number of variables, in this case 24.


(and just for clarifying better, CNEMONavierStokes uses the implementation in CNEMOEulerSolver as it is an extension of it, hence why the error refers to the Euler class)
Hi Catarina,

Thank your suggestions very much!

I fixed this probloms by redefined MAXNVAR in CNEMOEulerVariable.hpp from 25 to 35 (a little bit weird cuz my case is 2D problem). And I think the stiffness of the machanism of Mars_19 is quite strong to make the calucation unstable and need to do more settings, I finally add the CO2_5sp and Park1994, johnston2014 machnism to mutationpp folder, and recompile the code to complete the numerical simulation of my CO2 nonequilibrium case.

I used to use Eilmer to do the nonequilibrium simluation. I am very instested in your work in developing implicit method in NEMO-SU2 which may increase the calculation efficiency of steady problem, may i get some test examples/cases of CO2 nonequilibrium to explore more?


Best regards
Yufan
yufan is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to understand the Recombination Tables in CMutationTCLib.cpp?? Cherith SU2 0 July 16, 2023 02:43
How to combine 2 tables and find the maximum slesar85 STAR-CCM+ 0 January 26, 2018 07:03
[OpenFOAM] Can Paraview create tables like in CFD-post (Ansys)? vasava ParaView 9 November 3, 2016 02:01
FlameletFoam tables and OpenFOAM-2.3.x Look-Up-Tables Sermengi OpenFOAM 2 December 19, 2014 06:10
look-up tables Jiri Novak Main CFD Forum 0 June 23, 2006 07:29


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