I'm trying to use Code_Saturne with : passive scalar transportation, a fluid density which depends on this scalar and a mass source term. I don't get the expected results, can you please give me some help ?
My case contains a passive scalar, I'll call
I try to compute a gas (number 2) evolving in another gas (number 1) which is the reference. Thus the fluid density is based on user subroutine usphyv, using this relation
The flow in my duct is already established and
I want to add a mass source term of gas number 2. I've used the ustsma subroutine : I called GETCEL to catch cells and with VOL_SOURCE the total volume of caught cells :
Code: Select all
DO IELTSM = 1, NCESMP
! Mass source term
SMACEL(IELTSM,ipr(IPHAS)) = 1.2266d-3 / VOL_SOURCE
ITYPSM(IELTSM,isca(1)) = 1
SMACEL(IELTSM,isca(1)) = 1d0
ENDDO ! DO IELTSM = 1, NCESMP
It seems like my mass source term don't care about my usphyv law, is that true ? Did I make a mistake using ustsma subroutine ?
I've tried it on Code_Saturne 2.0.0rc1 and 2.3.1.
Thank you for any help you might bring me !
Quentin