Hi Code Saturne develop team:
I am simulating a vertical channel downward flow with inlet at the top face (named "top") and outlet at the bottom face (named "bot"), the turbulence model I am using is the k-omega SST model. At each iteration, I need to copy the outlet face (named "bot") velocity field and impose it at the inlet face (named "top"). The vertical distance between the top inlet face and the bottom outlet face is 0.0162m. My mapped inlet subroutine is attached, am I doing it correctly?
Regards!
Jundi
Question about the mapped inlet subroutine
Forum rules
Please read the forum usage recommendations before posting.
Please read the forum usage recommendations before posting.
Re: Question about the mapped inlet subroutine
Hi:
Sorry that I forgot to include the subroutine, this is the mapped inlet subroutine that I used.
Regards!
Jundi
Sorry that I forgot to include the subroutine, this is the mapped inlet subroutine that I used.
Regards!
Jundi
- Attachments
-
- cs_user_boundary_conditions-mapped_inlet.f90
- (7.83 KiB) Downloaded 275 times
-
- Posts: 4079
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Question about the mapped inlet subroutine
Hello,
It seems OK at a quick glance. Do the results match what you expect ?
Regards,
Yvan
It seems OK at a quick glance. Do the results match what you expect ?
Regards,
Yvan
Re: Question about the mapped inlet subroutine
Hi Yvan:
The result doesn't meet my expect, I've checked the outlet and inlet velocity contour, and they are total different, I have exactly the same mesh at the outlet and the inlet, it seems that Code Saturne did not copy the outlet velocity field to the inlet.
Regards!
Jundi
The result doesn't meet my expect, I've checked the outlet and inlet velocity contour, and they are total different, I have exactly the same mesh at the outlet and the inlet, it seems that Code Saturne did not copy the outlet velocity field to the inlet.
Regards!
Jundi
-
- Posts: 4079
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Question about the mapped inlet subroutine
Hello,
Did you run a sufficient number of iteratons ?
Regards,
Yvan
Did you run a sufficient number of iteratons ?
Regards,
Yvan
Re: Question about the mapped inlet subroutine
Hi Yvan:
Yes, I've run for several thousand iterations, from the monitoring point, the values are converge and stay constant. But still, the outlet and inlet velocity field is different. I guess there are some problems in my subroutine.
Regards!
Jundi
Yes, I've run for several thousand iterations, from the monitoring point, the values are converge and stay constant. But still, the outlet and inlet velocity field is different. I guess there are some problems in my subroutine.
Regards!
Jundi
Re: Question about the mapped inlet subroutine
Hi Yvan:
I guess I know what cause the problem. The contour shows the streamwise velocity of the channel (downward flow, inlet from the top and outlet from the bottom), because of the ribs on the left wall, there are re-circulations near the rib wall. If the subroutine copy the outlet velocity field and impose it to the inlet, it will cause problem, because the inlet boundary condition only allow "inject" but not "extract". Do you have a solution on this? How to copy the outlet velocity field to the inlet in such flow, to make it periodic? Thanks for the time.
Regards!
Jundi
I guess I know what cause the problem. The contour shows the streamwise velocity of the channel (downward flow, inlet from the top and outlet from the bottom), because of the ribs on the left wall, there are re-circulations near the rib wall. If the subroutine copy the outlet velocity field and impose it to the inlet, it will cause problem, because the inlet boundary condition only allow "inject" but not "extract". Do you have a solution on this? How to copy the outlet velocity field to the inlet in such flow, to make it periodic? Thanks for the time.
Regards!
Jundi
-
- Posts: 4079
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Question about the mapped inlet subroutine
Hello,
For this case, using a true periodicity condition and a momentum source term to ensure the bulk flow velocity is probably the cleanest solution (this is what we do for our own "ribs" case, with the attached file).
Best regards,
Yvan
For this case, using a true periodicity condition and a momentum source term to ensure the bulk flow velocity is probably the cleanest solution (this is what we do for our own "ribs" case, with the attached file).
Best regards,
Yvan
- Attachments
-
- cs_user_source_terms.f90
- (10.18 KiB) Downloaded 259 times
Re: Question about the mapped inlet subroutine
Hi Yvan:
I was doing the periodic case with the momentum source term previously, but in this case, I have a constant heat flux on the rib wall, if I do the "true" periodic case, I need to impose a heat sink, which is impossible, because my geometry is an eccentric channel with ribs, the mass flux in different circumferential position is hugely different. Is there a method to impose a negative velocity at the inlet, so that the mapped inlet subroutine can be impose.
Regards!
Jundi
I was doing the periodic case with the momentum source term previously, but in this case, I have a constant heat flux on the rib wall, if I do the "true" periodic case, I need to impose a heat sink, which is impossible, because my geometry is an eccentric channel with ribs, the mass flux in different circumferential position is hugely different. Is there a method to impose a negative velocity at the inlet, so that the mapped inlet subroutine can be impose.
Regards!
Jundi
Re: Question about the constant mass flow rate
Yvan Fournier wrote: ↑Fri Apr 13, 2018 4:35 pm Hello,
For this case, using a true periodicity condition and a momentum source term to ensure the bulk flow velocity is probably the cleanest solution (this is what we do for our own "ribs" case, with the attached file).
Best regards,
Yvan
Hi Yvan,
Is it possible to impose constant mass flow rate with this subroutine in code_saturne v6? It seems not working due to error ''can't open module file setup.mod''.
Best regards,
Marco