|
[Sponsors] |
motorBike tutorial doesn't work out-of-the-box |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
December 23, 2009, 09:35 |
motorBike tutorial doesn't work out-of-the-box
|
#1 |
Member
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 16 |
Hi all,
The motorBike case didn't work out for me, sadly. At first, meshing seemed to have worked out. (Is it appropriate to check the visualisation of vtkCompositeIndex for observing of the refinement level? I thought I read that, just don't remember where...) After the run (nothing changed in the dicts, just read!), I visualized the write steps of velocity U as wireframe in ParaFoam and the velocity seems to be 0 everywhere at first glance. At write step 5 (equals time 500s) the velocity seems to be 0 at most points except for several points, where the velocity seems to be the maximum value (unbelievable high values like 4e37!). Why is that? I thought, the tutorial should present a case that is working (assumption: no changes made by the learner)? What did I do wrong here? I noticed, the residuals at endTime (i.e. 500, deltaT=1) are much higher than the tolerance settings, so the solver stopped iterations due to endTime rather than due to a "good" result. Is it just a matter of more iterations (don't think so personally)? Further observation showed the following: In the 0/p file, the dimensions for p is set to [0 2 -2 0 0 0 0], what would be equivalent to (m*m)/(s*s) which is obviously not a pressure unit... How come? Anyway, the pressure is set to uniform 0... The snappyHexMesh log gives the following: Code:
Undo iteration 0 ---------------- Checking faces in error : non-orthogonality > 65 degrees : 0 faces with face pyramid volume < 1e-13 : 0 faces with concavity > 80 degrees : 0 faces with skewness > 4 (internal) or 20 (boundary) : 0 faces with interpolation weights (0..1) < 0.02 : 0 faces with volume ratio of neighbour cells < 0.01 : 0 faces with face twist < 0.02 : 1 faces on cells with determinant < 0.001 : 0 Detected 0 error faces on boundaries that have been merged. These will be restored to their original faces. Detected 1 error faces in mesh. Restoring neighbours of faces in error. Edge intersection testing: Number of edges : 1005921 Number of edges to retest : 0 Number of intersected edges : 42360 Constructing mesh displacer ... Checking mesh manifoldness ... Outside of mesh is multiply connected across edges or points. This is not a fatal error but might cause some unexpected behaviour. Writing 34 points where this happens to pointSet nonManifoldPoints Code:
Calculating patchDisplacement as distance to nearest surface point ... Wanted displacement : average:0.00364437 min:6.64418e-09 max:0.0203723 Calculated surface displacement in = 0.8 s --> FOAM Warning : Displacement (0.00473027 -0.00277192 0.0110628) at mesh point 99138 coord (0.506196 0.0692469 0.180362) points through the surrounding patch faces Smoothing displacement ... Iteration 0 Iteration 10 Iteration 20 Displacement smoothed in = 7.09 s Code:
Edge intersection testing: Number of edges : 1022449 Number of edges to retest : 204569 Number of intersected edges : 58574 Snapped mesh : cells:318771 faces:1022449 points:383614 Cells per refinement level: 0 934 1 1720 2 5040 3 9472 4 131655 5 23602 6 146348 Writing mesh to time constant Written mesh in = 24.46 s. --> FOAM Warning : From function layerParameters::layerParameters(..) in file autoHexMesh/autoHexMeshDriver/layerParameters/layerParameters.C at line 377 Reading "/home/kretzschmar2/OpenFOAM/kretzschmar2-1.6/run/tutorials/incompressible/simpleFoam/motorBikeSingleCore/system/snappyHexMeshDict::layers" from line 184 to line 452 Layer specification for minZ does not match any patch. Suggestions? Cheers Wolle P.S.: A merry christmas and a happy new year to all the forum users. Hope to read you next year... |
|
December 25, 2009, 10:26 |
|
#2 | ||
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Season Greetings Wolle,
First of, you didn't mention if you are using OpenFOAM 1.6 or 1.6.x. Nor if it's the 32 or 64bit version, and/or which gcc version you are using... since that could also affect the results By my experience, the 1.6 version doesn't converge, but the 1.6.x does. Additionally, the 64bit version seemed to give a better mesh in much less time than the 32bit version. Quote:
Quote:
Best regards and a Merry Christmas and a Happy New Year to you too Woole Bruno |
|||
December 26, 2009, 14:43 |
|
#3 | |
New Member
Join Date: Apr 2009
Posts: 26
Rep Power: 17 |
Quote:
Ask |
||
January 4, 2010, 09:14 |
|
#4 | |||
Member
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 16 |
Hi Bruno,
Quote:
Quote:
Quote:
Cheers & a happy new year Wolle |
||||
January 4, 2010, 09:16 |
|
#5 |
Member
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 16 |
||
January 4, 2010, 10:09 |
|
#6 | |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Hi Wolle and Happy New Year
Quote:
As for building the 1.6.x from git, I haven't had problems in 32 and 64bits versions of Ubuntu. Although I didn't use the cookbook, I did it all by hand and I was targeting cross-compilation in Linux for Windows (see here). I've been following that cookbook thread, but haven't had the time to test things and make sure what is going on there... Anyway, compared with the cookbook for Ubuntu, I've also installed the following packages: Code:
byacc bison texinfo Best regards, Bruno |
||
January 4, 2010, 10:59 |
|
#7 | ||
Member
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 16 |
Hi Bruno,
Quote:
Quote:
Cheers and thanks for your help Wolle |
|||
January 4, 2010, 11:14 |
|
#8 | |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Hi Wolle,
Quote:
Oh, and don't forget to install those packages I mentioned before trying to recompile OpenFOAM Best regards, Bruno |
||
January 6, 2010, 04:21 |
|
#9 |
Member
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 16 |
Hi all,
especially for others who might have the same problem, I'm going to post, what I found out on this problem. As Bruno mentioned, the 1.6 version of the motorBike tutorial seems not to reach convergence. One can monitor this by a programme called pyFoamPlotRunner included in a tool collection called PyFoam. pyFoamPlotRunner calculates plots (via gnuplot) of the residuals and other solver output on runtime of the solver. I attach a screenshot made after the run of pyFoamPlotRunner/simpleFoam ended. As one can clearly see, the residuals for the components of U, k and omega stay way above the defined tolerance, which is 1e-8 for each of the variables and can be found in the system/fvSolution file. To proceed, I obtained the git version of OpenFOAM 1.6.x just to get the 1.6.x version of the tutorial. I run this with OpenFOAM-1.6 (as git 1.6.x version still wont compile) and check both case versions for differences in the meantime. ... Last edited by Wolle; January 6, 2010 at 04:41. |
|
January 6, 2010, 04:40 |
|
#10 |
Member
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 16 |
... while checking the different versions of the motorBike case, one comes across the file 0/turbulentBoundaryField, which obviously doesn't exist in the 1.6.x version of the case.
Differences are found in the 0/k and 0/omega files. 1.6: 0/k includes the 0/turbulentBoundaryField file, while the 1.6.x version contains the relevant information directly. However, the relevant information differs between the versions. 1.6-0/k respectively 1.6-0/turbulentBoundaryField: Code:
lowerWall { type kqRWallFunction; } "motorBike_.*"l { type kqRWallFunction; } Code:
lowerWall { type kqRWallFunction; value $internalField; } "motorBike_.*"l { type kqRWallFunction; value $internalField; } 1.6-0/omega respectively 1.6-0/turbulentBoundaryField: Code:
lowerWall { type kqRWallFunction; } "motorBike_.*"l { type kqRWallFunction; } Code:
lowerWall { type omegaWallFunction; value $internalField; } "motorBike_.*"l { type omegaWallFunction; value $internalField; } Another difference is, that the 1.6 version contains a file constant/turbulenceProperties, which doesn't exist in the 1.6.x version. This file obviously activates turbulence calculation based upon a SpalartAllmaras turbulence model in the 1.6 version. I suppose turbulences are not calculated upon a model, but directly upon the locally refined mesh in the 1.6.x version, is that right? All other files are identical. Cheers Wolle |
|
January 6, 2010, 08:03 |
|
#11 | |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Quote:
You can find the history here: http://repo.or.cz/w/OpenFOAM-1.6.x.g...orBike/0/omega Regards BastiL |
||
January 6, 2010, 08:28 |
|
#12 |
Member
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 16 |
Hi Bastil,
okay then, but why is the constant/turbulenceProperties file missing? Cheers Wolle |
|
January 6, 2010, 11:22 |
|
#13 |
Member
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 16 |
Hi all again!
Finally, the run of the 1.6.x case version on OF-1.6 seems to be more successful. But I'm still confused with some results. See in my first screenshot, the motorbike presented as pressure by cells. The values at the scale do at least seem to be reasonable. See in the second screenshot the same picture, just with velocity by cells. Third is velocity by points (where does that purple come from???). On both screenshots scales, the magnitude of maximum velocity seems to be reasonable again. But why is velocity zero almost everywhere? A fourth screenshot shows streamlines generated from vector U, see the settings on the left. The streamlines show, that there IS velocity, why doesn't the regular view (velocity by points/cells) show something like that around the motorbike or at least nearby? (Center point for stream line generation is approx. where the mouse pointer is located). Fifth screenshot is just a detail to show, that velocity isn't zero _everywhere_ on the bike... (velocity by points, wireframe). I'd expected the velocity to be around 20m/s nearby the bike (Sorry, forgot to include the scale in the screenshot.The yellowish green on the floor equals approx. 20m/s)? Why isn't that? One can see, that the floor ("lowerWall") shows exactly this - velocity is around 20m/s there - and both have the same settings in 0/k and 0/omega files? Cheers Wolle EDIT: About convergence... not yet below the tolerance settings but waaay better, than the 1.6 case: Code:
Time = 500 smoothSolver: Solving for Ux, Initial residual = 4.27648e-05, Final residual = 2.04875e-06, No Iterations 4 smoothSolver: Solving for Uy, Initial residual = 0.000843881, Final residual = 4.0716e-05, No Iterations 4 smoothSolver: Solving for Uz, Initial residual = 0.000906448, Final residual = 4.27539e-05, No Iterations 4 GAMG: Solving for p, Initial residual = 0.00336481, Final residual = 0.000116042, No Iterations 2 time step continuity errors : sum local = 1.77245e-05, global = 2.52181e-07, cumulative = -0.000389702 smoothSolver: Solving for omega, Initial residual = 1.03476e-05, Final residual = 6.90257e-07, No Iterations 3 smoothSolver: Solving for k, Initial residual = 0.000147569, Final residual = 1.11085e-05, No Iterations 3 ExecutionTime = 8794.01 s ClockTime = 9769 s End |
|
January 6, 2010, 18:03 |
|
#14 | |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Quote:
Regarding the velocities I can not really see this in your screeshots, but you should expect to get for point data(!): 20 m/s on the floor ("lowerWall") - as you do. 0 m/s on all stationary non-slip walls (!) not 20 m/s. So this seem reasonable too, as far as I can see. Regards. |
||
January 7, 2010, 05:12 |
|
#15 | |
Member
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 16 |
Hi Bastil and thanks for your replies.
Quote:
Maybe it's also a problem of imagination? I think of it as a motorbike in a wind tunnel. Floor and bike are fixed and air is blown from front to back. So I'd say, the velocities measured near the fixed objects should be around 20m/s, but not zero? What's wrong with my imagination of the problem? Cheers & Thanks for your patience Wolle |
||
January 7, 2010, 12:38 |
|
#16 | |||
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Quote:
Quote:
Quote:
Regarding velocities: This strongly depends where to measure. The velocity directly on the surface is zero (slip-condition, this is what you see when you use point values!) and we get a (turbulent) boundary layer profile until we leave the boundary layer. Hope this makes it clear. Regards BastiL |
||||
January 11, 2010, 08:12 |
|
#17 | ||
Member
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 16 |
Hi Bastil,
Thanks for your enlightment, I don't know, why I didn't realize this. Quote:
Quote:
Cheers & Thanks again for your reply Wolle |
|||
January 11, 2010, 18:36 |
|
#18 | ||
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Quote:
Quote:
Regards |
|||
January 12, 2010, 02:36 |
|
#19 | ||
Member
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 16 |
Hi Bastil,
Exactly.. Quote:
Quote:
So thanks again, I think I've got a pretty good imagination of what one can do. Sadly, I've got to focus on different things at the moment... I'll get back to it later, I think. Cheers Wolle |
|||
April 16, 2010, 06:03 |
motorbike case
|
#20 |
New Member
Prasanth V
Join Date: Mar 2010
Posts: 6
Rep Power: 16 |
I have also got a working case of motorbike 1.6.x git . I am including stream tracer plot
|
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Simulate heat transfer of heat sink in a box... | chien87 | CFX | 8 | February 8, 2011 04:50 |
STAR-CD Tutorial | shekhar aryal | STAR-CD | 4 | March 22, 2010 04:25 |
junction box routine and CEL function | bornspur | CFX | 2 | February 3, 2009 03:24 |
Immersol Simulation of a Heated Box | Dong | Phoenics | 0 | March 2, 2006 22:20 |
Rotor/stator tutorial, and how to... | gilberto | CFX | 5 | January 21, 2002 10:41 |