Hi,
I've used Code Saturne 2.0.7 for a couple of years to estimate pressure losses in hydraulic valves with generally good results. I've always used "mixing lenght" turbulence model for the good correspondence with experimental results and time of execution.
During the last week I tried to switch to Code Saturne 4 and I performed some comparisons. In particular, with the same mesh (about 280k tetra-elements), I compared the results of:
- saturne 2.0.7 with mixing length
- saturne 4 with mixing length
- saturne 4 with k-eps
and I found very different results: there is about a factor of 3 in the estimation of the Delta P at the ports of the valve.
I used to make runs of about 800-1000 steps with steady state flow, increasing inlet flow rate every 100 steps.
I've attached:
- a graph plotting the pressure read at inlet (P port) and outlet (A port, fixed @5bar). Raw data are in Pascal, but have been scaled in the graph to bar
- the 2 input files (I tried to keep the same parameters...)
I've also seen that, even if the pressure field is much smoother in saturne 4, when I import data in Paraview (Salome) the streamlines of fluid are much better distributed in saturne 2 (in sat 4 seem to stop somewhere... )
- saturne 4 stream: https://dl.dropboxusercontent.com/u/117 ... stream.png
- saturne 2 stream: https://dl.dropboxusercontent.com/u/117 ... stream.png
I could also make the med file results available, but they are pretty big (200 and 500 mb)
Can anyone suggest me some other tests?
Thank you
Claudio
Comparison of Saturne 2 and Saturne 4 results
Forum rules
Please read the forum usage recommendations before posting.
Please read the forum usage recommendations before posting.
Comparison of Saturne 2 and Saturne 4 results
- Attachments
-
- s4_std_ml.xml
- config file for sat4 and mixing length turbulence model
- (7.19 KiB) Downloaded 404 times
-
- PA_40_mod_M1.xml
- config file for Sat2 and mixing length turbulence model
- (6.35 KiB) Downloaded 390 times
-
- Posts: 4208
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Comparison of Saturne 2 and Saturne 4 results
Hello,
Yes, 200 and 400mb is pretty big, so we might not ask for your meshes right away...
Compared "listing" files might help guess at where the difference comes from.
The mixing-length model is not often used in either version (and is not part of the validation test suite), though it should work...
Did you have k-epsilon results for v2.0 for comparison ?
Also, for this sort if application, using improved pressure interpolation (iphydr) may help.
Also, least squares gradients are not used for pressure anymore in 4.0, though you can force this by setting
Finally, I see you used pressure relaxation (I assume to converge). Increasing the number of "sweeps" might be a more costly but safer alternative.
Other colleagues might suggest some additional tests...
Regards,
Yvan
Yes, 200 and 400mb is pretty big, so we might not ask for your meshes right away...
Compared "listing" files might help guess at where the difference comes from.
The mixing-length model is not often used in either version (and is not part of the validation test suite), though it should work...
Did you have k-epsilon results for v2.0 for comparison ?
Also, for this sort if application, using improved pressure interpolation (iphydr) may help.
Also, least squares gradients are not used for pressure anymore in 4.0, though you can force this by setting
in the usipsu subroutine (in cs_user_parameters.f90 user file). This might have some influence in your case.imrgra = -2
Finally, I see you used pressure relaxation (I assume to converge). Increasing the number of "sweeps" might be a more costly but safer alternative.
Other colleagues might suggest some additional tests...
Regards,
Yvan
Re: Comparison of Saturne 2 and Saturne 4 results
Thank you Yvan for your answer.
Here I've attached the listing files of the 3 simulations.
Now I'm running the same experiment with Saturne 2 and K-epsilon turbulence model.
I'll post the results as soon as it finishes.
Then I'll try your other suggestions.
Regards
Claudio
Here I've attached the listing files of the 3 simulations.
Now I'm running the same experiment with Saturne 2 and K-epsilon turbulence model.
I'll post the results as soon as it finishes.
Then I'll try your other suggestions.
Regards
Claudio
- Attachments
-
- listing.tar.gz
- listing of sat 2 and 4 simulations
- (708.32 KiB) Downloaded 391 times
Re: Comparison of Saturne 2 and Saturne 4 results
I've finished the simulation with k-eps and sat2.
I attach listing and comparison of the results.
Claudio
I attach listing and comparison of the results.
Claudio
- Attachments
-
- listing.s2_ke.tar.gz
- listing of simulation with sat2 and k-eps turbulence model
- (240.72 KiB) Downloaded 387 times
-
- Posts: 4208
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Comparison of Saturne 2 and Saturne 4 results
Hello,
Looking briefly at your v2 and v4 k-epsilon files, I saw that in 2.0, you do not use the same steady algorithm (idtvar -1/SIMPLE instead of idtvar 2/SIMPLEC).
Also, the initial density and laminar viscosity are the same, bu not the turbulent viscosity, probably due to ALMAX being set in 4.0 but not in 2.0. This can explain pretty big differences, though I am not sure it explains the whole difference (but it does make the computations difficult to compare from then).
Did you try IPHYDR (improved stratified velocity pressure) yet ?
Regards,
Yvan
Looking briefly at your v2 and v4 k-epsilon files, I saw that in 2.0, you do not use the same steady algorithm (idtvar -1/SIMPLE instead of idtvar 2/SIMPLEC).
Also, the initial density and laminar viscosity are the same, bu not the turbulent viscosity, probably due to ALMAX being set in 4.0 but not in 2.0. This can explain pretty big differences, though I am not sure it explains the whole difference (but it does make the computations difficult to compare from then).
Did you try IPHYDR (improved stratified velocity pressure) yet ?
Regards,
Yvan
Re: Comparison of Saturne 2 and Saturne 4 results
Ccaccia73
Hello. I'm also interested in Code_Saturne and reliability of results obtained with it (for industrial applications). IMHO, calculating the local pressure drop is not so simple as it seems to be. Even commercial solvers may give some different results, although setup looks normal for this kind of tasks (fine mesh, prism layers of mesh cells near walls, SST turbulence, second order spatial discretisation).
Maybe calculation on refined mesh (for example, 1 million of cells) or other turbulence models (SST, RSM) will give results more close to experiment. Pressure loss in a valve is only local so it may be useful to look at particular flow features like recirculation zones and estimate mesh fineness in these areas.
Hello. I'm also interested in Code_Saturne and reliability of results obtained with it (for industrial applications). IMHO, calculating the local pressure drop is not so simple as it seems to be. Even commercial solvers may give some different results, although setup looks normal for this kind of tasks (fine mesh, prism layers of mesh cells near walls, SST turbulence, second order spatial discretisation).
Maybe calculation on refined mesh (for example, 1 million of cells) or other turbulence models (SST, RSM) will give results more close to experiment. Pressure loss in a valve is only local so it may be useful to look at particular flow features like recirculation zones and estimate mesh fineness in these areas.
Re: Comparison of Saturne 2 and Saturne 4 results
Yvan
I've just finished the simulation with IPHYDR and there is no difference between those and the previous ones with same conditions (k-eps and Sat 4) at least in terms of pressure at inlet and outlet. I can post more detailed information if you need. btw it took me almost 'forever' (about 40 hours) to come to an end, while other simulations were much faster. I'm trying to investigate if working conditions were the same.
Antech
Happy to hear from you and maybe exchange opinions. I must say that I have little experience in the field: no particular training nor great budget, just a couple of years of trial and error... For my constraints (hardware and time) 1million cells is not feasible. My company produces hydraulic valves and their main interest is to have some tools that can predict flow-pressure drop relation for proportional valves: which generally means a lot of meshes (different connection, different opening...) and so a lot of simulations. I found a good compromise for the above constraints with Saturne 2: i.e. experimental data are close enough to the simulations for my purposes. Now I'm trying to see if I can replicate this with Saturne 4, mainly because I'm interested in some new features.
I've just finished the simulation with IPHYDR and there is no difference between those and the previous ones with same conditions (k-eps and Sat 4) at least in terms of pressure at inlet and outlet. I can post more detailed information if you need. btw it took me almost 'forever' (about 40 hours) to come to an end, while other simulations were much faster. I'm trying to investigate if working conditions were the same.
Antech
Happy to hear from you and maybe exchange opinions. I must say that I have little experience in the field: no particular training nor great budget, just a couple of years of trial and error... For my constraints (hardware and time) 1million cells is not feasible. My company produces hydraulic valves and their main interest is to have some tools that can predict flow-pressure drop relation for proportional valves: which generally means a lot of meshes (different connection, different opening...) and so a lot of simulations. I found a good compromise for the above constraints with Saturne 2: i.e. experimental data are close enough to the simulations for my purposes. Now I'm trying to see if I can replicate this with Saturne 4, mainly because I'm interested in some new features.
-
- Posts: 4208
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Comparison of Saturne 2 and Saturne 4 results
Hello,
IPHYDR is slower because it requires additional pressure correction steps, but it was safe to check at least once that it does not influence the results...
Did you check the difference in hydraulic diameter (ALMAX) and time scheme ?
In any case, it is better to move to version 4.0, as 2.0 is not maintained anymore, so it is useful to understand why there is a difference.
If you have a smalll mesh (such as a subset of your geometry, with just the near-valve area, and possibly less refined), it could be interesting to check the differences on that one, as checks/comparisons could be run much more quicky (the smaller the mesh, the better, as long as the issue can be reproduced).
Regards,
Yvan
IPHYDR is slower because it requires additional pressure correction steps, but it was safe to check at least once that it does not influence the results...
Did you check the difference in hydraulic diameter (ALMAX) and time scheme ?
In any case, it is better to move to version 4.0, as 2.0 is not maintained anymore, so it is useful to understand why there is a difference.
If you have a smalll mesh (such as a subset of your geometry, with just the near-valve area, and possibly less refined), it could be interesting to check the differences on that one, as checks/comparisons could be run much more quicky (the smaller the mesh, the better, as long as the issue can be reproduced).
Regards,
Yvan
Re: Comparison of Saturne 2 and Saturne 4 results
Thank you Yvan.
In my experience, working with a subset of the mesh (only the near-valve area) leads to difficult convergence, in particular because outlet conditions are not met.
I can definitely work with a slightly coarser mesh and/or the simplest possible geometry, at least for comparison.
In the next few days I'll start checking ALMAX and time scheme for the current mesh.
Claudio
In my experience, working with a subset of the mesh (only the near-valve area) leads to difficult convergence, in particular because outlet conditions are not met.
I can definitely work with a slightly coarser mesh and/or the simplest possible geometry, at least for comparison.
In the next few days I'll start checking ALMAX and time scheme for the current mesh.
Claudio
Re: Comparison of Saturne 2 and Saturne 4 results
Ccaccia73
OK, I see. So many variants is a problem with limited resources like PC (workstation). We usually solve less variants but with finer mesh and, in some cases, with specific physics.
About turbulence modeling. I've read a description of Mixing length and it seems to be the most simple zero-equation model that requires setting of characteristic length corresponding to specific geometry. I'm not a Saturne developer and cannot say what is the reason for difference in various versions with the same models, but I'd prefere SST for this kind of task with prism layers near walls at least for test (to chek if results will correspond to experiment), or, as basic setup, k-epsilon model (with relatively coarse mesh at the wall). Near-wall layers (for SST) are not very "cell-consuming", but they should be added correctly to provide Y+ values for the first layer small enough (about 1.0) in the regions of interest (where the flow may separate).
Another detail is a turbulence characteristics at the inlet (for example, k and epsilon) that may affect the flow downstream significant in real cases. Saturne is smart enough to set them for us (in first approximation) provided we input a hydraulic diameter at the inlet (4*Area/Perimeter). With the zero-equation model (mixing length) you don't need inlet turbulence parameters, but, IMHO, there is no guarantee that this simple model will give precise results.
OK, I see. So many variants is a problem with limited resources like PC (workstation). We usually solve less variants but with finer mesh and, in some cases, with specific physics.
About turbulence modeling. I've read a description of Mixing length and it seems to be the most simple zero-equation model that requires setting of characteristic length corresponding to specific geometry. I'm not a Saturne developer and cannot say what is the reason for difference in various versions with the same models, but I'd prefere SST for this kind of task with prism layers near walls at least for test (to chek if results will correspond to experiment), or, as basic setup, k-epsilon model (with relatively coarse mesh at the wall). Near-wall layers (for SST) are not very "cell-consuming", but they should be added correctly to provide Y+ values for the first layer small enough (about 1.0) in the regions of interest (where the flow may separate).
Another detail is a turbulence characteristics at the inlet (for example, k and epsilon) that may affect the flow downstream significant in real cases. Saturne is smart enough to set them for us (in first approximation) provided we input a hydraulic diameter at the inlet (4*Area/Perimeter). With the zero-equation model (mixing length) you don't need inlet turbulence parameters, but, IMHO, there is no guarantee that this simple model will give precise results.