|
[Sponsors] |
November 25, 2014, 06:54 |
defining sphere inside a cube model
|
#1 |
Member
Join Date: Oct 2014
Posts: 42
Rep Power: 12 |
Good Morning everyone!
I'm and trying to make a model which consists on a cube with a sphere inside, and a fluid which will flow along the cube. I achieved to do it with a cube inside a cube (as I commented in another post) but of course it is much more difficult with the sphere. As I didn't know how to make a sphere, I read many post about it and I did it with snappyHexMesh at the end. Then, I assigned boundary conditions and run with 'buoyantBoussinesqSimpleFoam'. Everything worked fine until I entered in OpenFoam. I don't have any problems to see initial conditions, but when I press play this error message appears: PHP Code:
PHP Code:
http://freakshare.com/files/4oe8sdmy...phere.zip.html If you could tell me the solution to my problem or at least guide my in some direction to solve would be great Thank you in advance |
|
November 25, 2014, 09:30 |
|
#2 | |
New Member
Sindre Tosse
Join Date: Sep 2014
Posts: 6
Rep Power: 12 |
Usually, you can get a good idea of where something went wrong by looking at the error.
Quote:
|
||
November 25, 2014, 09:33 |
|
#3 |
Member
davide basso
Join Date: Jan 2012
Posts: 48
Rep Power: 14 |
Hi Wien,
If you open your mesh in paraFoam you can see that the problem is that you don't have any sphere at all inside your cube. That's because, I suspect, the castellated mesh is too coarse to snap to the sphere try something like this: Code:
refinementSurfaces { sphere { level (2 2); /* regions { secondSolid { level (5 5); } } */ patchInfo { type wall; } } } |
|
November 25, 2014, 10:12 |
|
#4 |
Member
Join Date: Oct 2014
Posts: 42
Rep Power: 12 |
Good afternoon!
First of all thank you both for your answers. @ stosse: I deleted previous other time folders, and in fact my starting time is 0 in controlDict. When you say uniform fields, do you refer to every single variable? @ rolloblues: I applied that change, but it didn't work. In fact I do have the sphere in the model. If I write in my terminal blockMesh and then snappyHexMesh", time folders 1, 2 and 3 are created. If I run OpenFoam I can see perfectly the sphere after pressing play. The problem comes when I run after that buoyantBoussinesqSimpleFoam. In the terminal doesn't appear any error during the calculation time. I restart OpenFoam, I select the Volume Fields I want to analyse and I press play again. It is in that specific moment when the error I commented before appears, and I don know why. I hope I have explained better my problem. Thank you in advance! |
|
November 25, 2014, 10:14 |
|
#5 |
Member
davide basso
Join Date: Jan 2012
Posts: 48
Rep Power: 14 |
My bad, sorry, I didn't noticed the other folders
|
|
November 26, 2014, 03:03 |
|
#6 | ||
New Member
Sindre Tosse
Join Date: Sep 2014
Posts: 6
Rep Power: 12 |
Uniform field means that the variable (U, p, etc.) has the same value in all cells. You set this in the starting time folder (3 in your case, since 1 and 2 are mesh generation steps) by setting something like (for U):
Quote:
For the start time, you have to change startFrom to startTime in controlDict if you want to use the specified start time. The default is to use the latest available time. I would recommend keeping the default setting, and deleting unwanted results before you rerun simulations. That way, you don't end up with results from multiple runs in the same case directory (if the write times are not exactly equal), or accidentaly run from a mesh generation step By the way, if you use the -overwrite flag on snappyHexMesh, Quote:
|
|||
November 26, 2014, 04:37 |
|
#7 |
Member
Join Date: Oct 2014
Posts: 42
Rep Power: 12 |
Good Morning,
I read what you told me and I consider it makes sense! It is logic that the first 3 steps are taken to create the sphere and the buoyantBoussinesqSimpleFoam simulation should start from that point, and not from 0. So that is why I changed startFrom from startTime to latestTime (keeping startTime 0) and I didn't delete the 1,2,3 time folders. I copied the 0 files in "3" and of course I was required to add commands about "sphere" in each of them. Again it doesn't imply any problem and the simulation runs perfectly. However, I have another error exactly at the same point than before, after pressing play in the simulation. This time the error is: PHP Code:
I can again see the sphere but not the T, U, p... field evolution. I attach al link with the modified .zip in case someone could help me. http://freakshare.com/files/q6mpmadd...phere.zip.html Thank you in advance |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Use of k-epsilon and k-omega Models | Jade M | Main CFD Forum | 40 | January 27, 2023 08:18 |
UDF for defining granular viscosity in mixture model | priyanka.asp | Fluent UDF and Scheme Programming | 7 | May 19, 2019 19:16 |
[Other] How to mesh inside a sphere? | ssss | OpenFOAM Meshing & Mesh Conversion | 5 | October 27, 2014 10:36 |
[ANSYS Meshing] Question about mesh generation for a pipe inside a cube | lnk | ANSYS Meshing & Geometry | 0 | July 10, 2012 13:28 |
Setting up: Cube, 2 holes, high pressure inside | shangzung | OpenFOAM | 0 | October 30, 2009 12:27 |