|
[Sponsors] |
Switchig from chtMultiRegionSimplefoam to chtMultiRegionFoam |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
June 14, 2017, 03:51 |
Switchig from chtMultiRegionSimplefoam to chtMultiRegionFoam
|
#1 |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Hello all,
I have a case that is running fine in chtMultiRegionSimpleFoam in steady-state. Now I am trying to run the same case (with steady-state BCs) in transient using chtMultiRegionFoam (I will switch to transient BCs later on). So far this is a desaster. What I did: 1. Use the case without any changes but run "chtMultiRegionFoam" instead of "chtMultiRegionSimpleFoam". This gives me mass conservation for time 1. However, as expected courant numbers are way to high for PISO and the simulation is crashing after a few time steps. 2. Next step was to reduce time-stepping to 1e-4. This gives me max. courant of 0.43. However, this calculation gives significant mass inconsistency between my in- and outlet and massively to high pressure drop after the first time step. It ends up with unphysical high velocities after a few time-steps. I realized that reducing time step further (1e-6) makes everything even worse which I don't really understand. However, larger time steps (1e-2) gives better but not perfect behavior. Has anybody observed similar effects? I have no explanation for this nor an idea what can be done to overcome this to get a stable solution. Regards bastil Last edited by bastil; June 14, 2017 at 11:05. |
|
June 14, 2017, 09:02 |
|
#2 |
Senior Member
Join Date: Sep 2013
Posts: 353
Rep Power: 21 |
Please post your fvSchemes and fvSolution files.
|
|
June 14, 2017, 10:34 |
|
#3 |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
See attached for both fluid (it's a liquid) and solid.
Inbetween I increased nOuterCorrectors from 1 to 10 to switch from PISO to pimple. This improves the continuity error (seems to improve due to available under-relaxation) but gives me divergence typically when solving velocity. |
|
June 14, 2017, 11:27 |
|
#4 |
Senior Member
Join Date: Sep 2013
Posts: 353
Rep Power: 21 |
While your files are all over the place I can't spot anything obviously wrong in them. There are things in there like a momentumPredictor in a solid, which is not read since there is no flow being solved, but nothing that makes a crash inevitable. Your schemes are fine. You might want to try changing your div(phi,U) scheme to upwind. The celllimited version you are using is fine though. Since you did not change anything in 0 and constant as I understood it is only the start up phase.
How long did it take your steady state solution to converge to reasonable levels? Did you try initializing your transient simulation with the steady state one? When and how does it crash? Can you post a log file of your run? |
|
June 14, 2017, 16:44 |
|
#5 |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Yes, it is the start-up phase that is causing issues.
The steady-state solution took about 2000 Iters to converge. However, it was only the solid temperature that was quite slow. Flow field convergence was notably quicker. I can post a log-file but this will take some time, I am out for a few days now. Mostly the crash happens at the beginning of a new timestep before solving velocities. I have a quite verbose log-file that gives me min and max field values for pressures, temperatures and velocities. After increasing nOuterCorrectors to 10 there is nothing obviously wrong about them before the crash occurs. Before that, mass conservation was not ok. I tried initializing from steady-state without any success. I suspect this has something to do with different pressure levels: I use pressure "0" at the outlet for steady-state which I changed to "1e5" for transient. From my understanding the incompressible solver is pressure-normalized ("0") whereas the transient one requires absolute pressures. |
|
June 14, 2017, 18:40 |
|
#6 |
Senior Member
Join Date: Sep 2013
Posts: 353
Rep Power: 21 |
There is likely your error. You forgot to change the pressure in both files, p and p_rgh to 1e5 in the initial field. You could use the zero in the transient solver as well as in the steady state one 1e5 though. It depends on your settings in thermoPhysicalProperties. If you set rhoConst there you are not solving for density and can hence use the normalized 0 pressure.
|
|
June 14, 2017, 18:53 |
|
#7 |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
No I did that. I have p and p_rgh "1e5" for the transient (chtMultiRegionFoam) case. I had "0" for steady-state (chtMultiRegionSimpleFoam). And that is - I guess - why an initialization is causing more troubles than starting from scratch.
|
|
June 26, 2017, 10:20 |
|
#8 |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Attached is a log-File for a "pimple-like" run. I am currently re-running using 1e-4 timestep and piso and will post this log as well.
|
|
June 26, 2017, 11:19 |
|
#9 |
Senior Member
Join Date: Sep 2013
Posts: 353
Rep Power: 21 |
The obvious thing in your log file is the drastic temperature drop from iteration 1 onwards. A common error with these solvers. Usually due to poor turbulence modelling, here i am not sure though. You can use automatic time step selection in your controlDict.
Code:
maxCo 0.1; maxDi 1e-3; adjustTimeStep true; |
|
June 26, 2017, 16:27 |
|
#10 |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
maxC0 0.1 only makes sence with PISO-like settings otherwise it may take years to run. However, it is also my first aim to get it running PISO-like (nOuterCorrectors=1).
momentumPredictor is off as this is the case in the tutorial es well. I am not really sure what it does but will turn it on. |
|
June 27, 2017, 06:14 |
|
#11 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
Hi guys,
just a few hints:
Good luck.
__________________
Keep foaming, Tobias Holzmann |
|
June 28, 2017, 04:59 |
|
#12 | ||
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Quote:
Quote:
Attached is a log-file where I did the following changes compared to the previous one:
Edit: so far I tried the following without success: 1. Reduce time-step from 1e-4 to 1e-5: Same behavior, calculation runs 5e-5s instead of 5e-4s 2. Increase nOutercorrectors from 1 to 2 to make use of under-relaxation (factor 0.5): Helps a little but not to much. |
|||
June 28, 2017, 06:28 |
|
#13 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
Hi Bastil,
its a bit difficult to get any insight to your case and the physics behind that. The region named - kopf_al (I think its some aluminum block - engine?) and your water has a very low temperature. I guess it is fine right? The error you get is based on the Temperature evaluateion - recalculate T from h. This is based on the fact that some cell makes trouble. You can see it that your Co explodes to > 500 and thus, I think the velocity gets extreme high, the pressure drops and the evaluation in the thermodynamic model fails. What you could do:
__________________
Keep foaming, Tobias Holzmann |
|
June 28, 2017, 11:39 |
|
#14 | ||||
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
I am currently trying to complie 4.x
Quote:
Code:
Create polyMesh for time = 0 Time = 0 Mesh stats points: 511755 faces: 4343955 internal faces: 4106445 cells: 2027153 faces per cell: 4.1686 boundary patches: 9 point zones: 0 face zones: 3 cell zones: 3 Overall number of cells of each type: hexahedra: 0 prisms: 341769 wedges: 0 pyramids: 19 tet wedges: 0 tetrahedra: 1685365 polyhedra: 0 Checking topology... Boundary definition OK. Cell to face addressing OK. Point usage OK. Upper triangular ordering OK. Face vertices OK. Number of regions: 1 (OK). Checking patch topology for multiply connected surfaces... Patch Faces Points Surface topology ... Checking geometry... Overall domain bounding box (-0.2795 -0.159141 -0.264175) (0.261 0.238676 0.099) Mesh (non-empty, non-wedge) directions (1 1 1) Mesh (non-empty) directions (1 1 1) Boundary openness (1.43513e-17 5.98081e-18 -2.31787e-16) OK. Max cell openness = 6.67657e-16 OK. Max aspect ratio = 43.2037 OK. Minimum face area = 2.22653e-08. Maximum face area = 9.52577e-05. Face area magnitudes OK. Min volume = 2.47071e-12. Max volume = 2.8834e-07. Total volume = 0.0176281. Cell volumes OK. Mesh non-orthogonality Max: 86.7125 average: 20.3952 *Number of severely non-orthogonal (> 70 degrees) faces: 2309. Non-orthogonality check OK. <<Writing 2309 non-orthogonal faces to set nonOrthoFaces Face pyramids OK. ***Max skewness = 4.6416, 1 highly skew faces detected which may impair the quality of the results <<Writing 1 skew faces to set skewFaces Coupled point location match (average 0) OK. Failed 1 mesh checks. End Quote:
Quote:
Quote:
Last edited by bastil; June 29, 2017 at 04:08. |
|||||
June 28, 2017, 12:39 |
|
#15 |
Senior Member
Join Date: Sep 2013
Posts: 353
Rep Power: 21 |
I thought checking the mesh was to obvious of an answer. I am proven wrong once again. A nonOrthogonality of 90 is invalid. Getting a stable solution with a value of 87 is extremely challenging. checkMesh -allTopology -allGeometry will likely fail additional checks. I'd highly recommend creating a mesh that it is worth computing on. Because this is definitely a mesh problem. Changing the version won't do you any good in this case.
Otherwise you might want to increase nOuterCorr to something big like Tobias mentioned and use the same relaxation as in your simple solution. You can afterwards lower it. ResidualControl for automatically ending this loop however was only recently added by him. As he stated PIMPLE uses a Final flag in fvSolution. So relaxationFactors for the last loop would be hFinal for example. |
|
July 12, 2017, 06:25 |
|
#16 |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Ok. I will try to improve the mesh. What are the recommended limited for a transient chtMultiRegionFoam case?
|
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
heat transfer, multiple regions, chtMultiRegionFoam? | Ohlzen-Wendy | OpenFOAM Pre-Processing | 13 | February 8, 2022 08:17 |
Error in thermophysical properties (chtMultiRegionFoam) | mukut | OpenFOAM Pre-Processing | 28 | November 23, 2021 07:34 |
What does this error when use solver chtMultiRegionFoam mean | sajad6 | OpenFOAM Running, Solving & CFD | 7 | October 6, 2014 08:38 |
FOAM FATAL IO ERROR for chtMultiRegionFoam | xiaoyoyo | OpenFOAM Running, Solving & CFD | 0 | May 8, 2012 17:49 |
Embed explicitSetValue in chtMultiRegionFoam | samiam1000 | OpenFOAM | 2 | April 18, 2012 06:14 |