Problem when replacing fields during RANS with combustion module on
Posted: Thu Mar 13, 2025 11:18 am
Hello everyone,
I'm trying to run a simulation of a simple combustion case where after a certain number of iterations, calculation of certain fields is "moved" to a certain subroutine, that implements a neural network. The newly computed fields are then used to replace the actual CFD fields inside the code. During that time, all of the dedicated routines for their calculation are turned off (d3pint.f90, pppdfr in d3pphy.f90). What is strange is that each of the modified fields seems to be reset in the following iteration, and the pressure field explodes towards non-feasible values for that instance.
I tracked down the problem to something that happens in the cs_pressure_correction subroutine in navstv.f90 (the one for Navier-Stokes resolution).
Does anybody know what can posssibly cause this issue inside that routine?
I attached a snapshot of the field values on cells present in the log file to show you the variables of interest (the one signed with *ANN_o) together with some other outputs of the same log file to try to give more context. I also attached a copy of the modified routines in cs/src.
Thanks to everybody,
Francesco
I'm trying to run a simulation of a simple combustion case where after a certain number of iterations, calculation of certain fields is "moved" to a certain subroutine, that implements a neural network. The newly computed fields are then used to replace the actual CFD fields inside the code. During that time, all of the dedicated routines for their calculation are turned off (d3pint.f90, pppdfr in d3pphy.f90). What is strange is that each of the modified fields seems to be reset in the following iteration, and the pressure field explodes towards non-feasible values for that instance.
I tracked down the problem to something that happens in the cs_pressure_correction subroutine in navstv.f90 (the one for Navier-Stokes resolution).
Does anybody know what can posssibly cause this issue inside that routine?
I attached a snapshot of the field values on cells present in the log file to show you the variables of interest (the one signed with *ANN_o) together with some other outputs of the same log file to try to give more context. I also attached a copy of the modified routines in cs/src.
Thanks to everybody,
Francesco