CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Car aerodynamics (https://www.cfd-online.com/Forums/openfoam-solving/57934-car-aerodynamics.html)

morfeus80 January 31, 2008 12:11

Hallo, I'm going to validate
 
Hallo,
I'm going to validate OpenFOAM with differents turbolence models for calculation of aerodynamic coefficients of formula cars. Before starting to work with a complete car, I want validate a model of bluff body with car shape, somethin as the Ahmed model. Unfortunately I don't have aerodynamic coefficients of models like this! Someone has a geometry and the relative experimental lift and drag coefficients to make this comparison?
Furthermore because I have experience of this kind of simulation with another commercial sotware but not with OpenFLOW, if someone is working with car aerodynamics, can give me information about the turbolence model is using please?

mighelone January 31, 2008 13:38

Here http://cfd.mace.mancheste
 
Here http://cfd.mace.manchester.ac.uk/ercoftac/ you can find the experimental data relatives to Ahmed body and other test cases.

Registration is required to download data!

Michele

morfeus80 January 31, 2008 16:13

Thanks, that website is very i
 
Thanks, that website is very interesting, but I didn't find what I need because there are pressure data and velocity fields, but nothing about lift and drag. Instead these are the parameters I need to validate my model!

bastil January 31, 2008 17:16

Hi Mattia, may I ask what s
 
Hi Mattia,

may I ask what software you intend to use for meshing?

morfeus80 February 1, 2008 06:25

In the past I used Ansa and Tg
 
In the past I used Ansa and Tgrid, now I have to decide. I thinked to can use the openFoam preprocessor, but it doesn't look very developed...

bastil February 2, 2008 06:47

The OpenFoam preprocessor "blo
 
The OpenFoam preprocessor "blockMesh" is not suited for handling theses complex geometries. I think if you want to use open source you can try to use one of the tet-meshers out there and use polyDualMesh afterwards to convert to polyhedral. However, you nee more or less clean CAD data (geometries) or a clean surface mesh for that, do you have that? Hex-dominant meshes are better than polys and I am still seeking some mesher for that. Tell me if you have one. I am also seeking for some surface mesh repair without havin ggeometry.

Regards

morfeus80 February 3, 2008 09:42

I have the complete geometry o
 
I have the complete geometry of the car, but I need the software to make the surface and volume mesh. According to your opinion what are the best open source software to make mashes on very complex geometries?

gdbaldw February 3, 2008 10:51

Regarding mesher. I needed a
 
Regarding mesher. I needed a quad surface with hex grid, first cell less than 1000 aspect ratio and acceptable skew, first cell at y+ of about 2 to 5. I patched together a script for Blender to specify just this kind of geometry, which exports to Calculix for building a grid, then exports to OpenFOAM. Works great, and I posted the script elsewhere in this forum. In my opinion, it would be an ideal free and open source tool for this problem. I used it for aero analysis of a fuselage. You'd need to be proficient in Blender from blender.org, and also learn Calculix, neither are insurmountable. If interested, I'd suggest finding an online tutorial for "Blender subsurf" and mastering this modelling technique (using quads only), then download Calculix and learn how to generate and export a simple geometry to OpenFOAM using the Calculix tutorial. After that, you are good to go. Download the Blender script I had posted and start generating 3-D compound/convex hex grids in a matter of hours or a few days depending on the level of complexity. Ahmed would take less than a day, but you'd need to invest many days in learning the technique.

By the way, there is another thread in this forum regarding attempts to model Ahmed. As I recall from the other thread there already exists OpenFOAM models of Ahmed. I'd be interested in lift/drag results you generate.

Doug

bastil February 3, 2008 17:41

Mattia, is the geometry cle
 
Mattia,

is the geometry clean or not (holes, overlappings, small faces,...)?
If your geometry is more or less clean you could try using netgen or salome to create surface and volume meshes (tets). Afterwards use dualPolyMesh to convert to poly if desired.

Concerning the blender method I think it has the drawback that you can not import existing CAD data to blender, can you? Nevertheless, I do not think that this will give you meshes for really complex car geometries with all features and maybe underhood. How compplex is your geometry?

gdbaldw February 3, 2008 23:17

True, the Blender method is be
 
True, the Blender method is best when new geometry is created. Ahmed could be quickly created in Blender. In theory it can also work with STL, since Blender can import STL format. I haven't needed to take that step.

Doug

lucchini February 4, 2008 03:50

Dear Mattia, are you workin
 
Dear Mattia,

are you working with OpenFOAM for car aerodynamics in Italy? Could you possibly contact me by e-mail ( tommaso . lucchini @ polimi . it)?

Thanks a lot, bye

Tommaso

bastil February 4, 2008 16:55

I Think blender in combination
 
I Think blender in combination with STL is possible if the stl is more or less clean. However stl from CAD packages normally are not. I hav a lot of dirty stl files I want to mesh with open source and so far I have no solution for this with accepable efford.

Regards

gdbaldw February 4, 2008 21:58

BastiL, If you are up to do
 
BastiL,

If you are up to doing some modest Python coding, Blender with STL could work. I haven't the need, else I'd look into it. For my needs, I coded a Python script to create a Calculix input file from multiple subsurf manifolds extending from the body to the far field. In order to adapt this script for STL, the first subsurf manifold would closely follow the STL geometry, and become the template for projecting the STL faces onto each subsequent manifold. Then, in Calculix, each STL triangle would be subdivided into three quads before generating a hex grid for export to OpenFOAM. The only significant additional coding needed is to map STL vertices to the nearest manifold subsurf face.

Doug

gdbaldw February 4, 2008 22:05

BastiL, By the way, Blender
 
BastiL,

By the way, Blender has a new feature that could help with cleaning bad STL. While in edit mode, you can Select "Non-Manifold" edges, which I have found selects only those edges that are not connected to exactly two faces.

Doug

morfeus80 February 5, 2008 04:07

BastiL, my geometry is very c
 
BastiL,
my geometry is very complex and I'll have to clean it.

luca_g February 5, 2008 04:13

Ciao Mattia, I can suggest
 
Ciao Mattia,

I can suggest you the following links (among many others you will find on the web) to papers related to computations on the Ahmed body. They all include pictures taken from the original Ahmed's SAE paper (which I don't have) reporting the experimental drag figures. No measure of downforce however, as far as I know, and it is anyway very low.

http://tmdb.ws.tn.tudelft.nl/worksho...B2000_NNFM.pdf

http://www.edpsciences.org/articlesp.../gillieron.pdf

http://www.imft.fr/GDR2502/journee24...Guilmineau.pdf

About the experimental drag figure I'm quite sure they are either "windtunnel corrected" values or the measures where done in a large tunnel with very low blockage and at 60m/s. On the contrary, the subsequent measurements (see first paper) where done on a small tunnel with 4% blockage at 40m/s and no drag figures are reported.

So it seems to me that to come closer to the experimental drag a large computational domain must be used, whereas a confined test section should be more appropriate to compare to the velocity profiles of the second experiment.

Luca

morfeus80 February 5, 2008 04:59

Luca, Thanks for the advice,
 
Luca,
Thanks for the advice, I'll start to work at this and as soon as I'll have some results, I'll give you.

Ciao!

bastil February 15, 2008 17:30

Mattia, are there some news
 
Mattia,

are there some news concerning mesh tools? I am srill seeking for well suited open source tools and would be happy about hints.

BastiL

morfeus80 February 16, 2008 08:22

BastiL, I have read this week
 
BastiL,
I have read this week the topic about Mesh3D, it's open-source and looks interesting. But I hadn't time to test it so far.
In this days I'm working with a mesh I alredy had an I'm testing several turbulence models and solvers. As soon as I'll reach good results, I'll start to work on the pre an post processors.

bastil February 17, 2008 05:52

Mattia, i have seen that, t
 
Mattia,

i have seen that, too. Looks interesting but has two drawbacks:
* Windows only
*32 Bit only

I Think this is not the way to go for large aerodynamic meshes.
I am also interested in your solver experiences. Is it possible to share them? What solvers? SimpleFoam?

morfeus80 February 18, 2008 15:03

I finished to run the first si
 
I finished to run the first simulation with simpleFoam and the realizableKe model for turbulence. I made 1700 iterations and I hadn't covergence problems, but the flow field I visualized is very far from reality.
I don't know if the problem can be caused by the fvSchemes, I'll try to change them.
Do you have any hints? Is there anybody has experience in simulation with this kind of turbulence model?

bastil February 19, 2008 15:11

How does the field look like?
 
How does the field look like? What are your solver settings? Residuals?

juho February 20, 2008 08:34

Hello Here are some work in
 
Hello

Here are some work in progress pictures of my not quite yet converged practise case:

http://www.students.tut.fi/~peltol20/it500.png

http://www.students.tut.fi/~peltol20/it500_2.png

simpleFoam
standard k-epsilon
3,1 million tetrahedral elements

vinz February 20, 2008 08:51

Hi Juho, Would it be possib
 
Hi Juho,

Would it be possible to know the grid generator you used to create this simulation?
Do you have experimental or other software numerical results to compare some parameters like drag coefficient on your model?
Anyway, interesting start, and I'm waiting forward to see your converged solution.

Regards,

Vincent

juho February 20, 2008 09:15

No data, it's an imaginary car
 
No data, it's an imaginary car I drew. Just learning to use OpenFOAM and some qualitative results on how geometry changes affect things. Velocity is 30m/s forgot to say.

Next I should try to figure out how to use liftDrag I guess.

The mesh is made in Gambit, my school has a license. Here's what checkMesh says:

=================================================

Domain bounding box: (-5.6 0.031 -1.10134e-15) (12.4 3.031 2.4)
Boundary openness (-3.90098e-17 3.3708e-16 -1.22955e-16) OK.
Max cell openness = 1.79272e-16 OK.
Max aspect ratio = 8.64372 OK.
Minumum face area = 2.77654e-06. Maximum face area = 0.114004. Face area magnitudes OK.
Min volume = 2.783e-09. Max volume = 0.0111914. Total volume = 127.35. Cell volumes OK.
Mesh non-orthogonality Max: 67.6634 average: 19.6029
Non-orthogonality check OK.
Face pyramids OK.
Max skewness = 0.878654 OK.
Min/max edge length = 0.0016882 0.607378 OK.

================================================

vinz February 20, 2008 09:23

Thanks for your reply Juho. I
 
Thanks for your reply Juho.
I'm actually looking for a good and easy to use free (or not too expensive) mesher for this kind of complex meshes. But I still didn't find the perfect one.
I guess I'm putting the bar a little too high!:D
Problems come when beginning to use lifdrag, so don't be too hurry!
Anyway, nice draw!Good luck.

Vincent

juho February 20, 2008 09:37

The ICEM CFD is good I hear, h
 
The ICEM CFD is good I hear, haven't used it. It probably isn't cheap though.

Does anyone actually know the price?

vtk_fan February 20, 2008 12:18

ICEM/CFD can cost upwards of U
 
ICEM/CFD can cost upwards of US $15,000 for a node-locked license. A floating license would probably cost a lot more.

bastil February 20, 2008 16:58

ICEM has restrictions regardin
 
ICEM has restrictions regarding hexcore meshes. Hexas all have the same size. His is not very well suited for Aerodynamic meshes.

pbo February 20, 2008 17:40

What do you mean by restrictio
 
What do you mean by restrictions on hexcore meshes?
I generated several multi-block structured meshes around wing and aircraft geometries using ICEM-CFD, all were featuring graded edges to properly resolve the boundary layer.

Gridgen from Pointwise is worth looking at (I prefer it to ICEM as far as I am concerned...), the academic licence is about 1500 GBP.

On the (almost) free side, there is CUBIT.

Another alternative: you can use the preprocessing utilities from EDGE (FOI CFD code with freely available binaries), and convert the generated mesh files to meet FOAM format.

bastil February 21, 2008 14:28

Patrick: You are takling ab
 
Patrick:

You are takling about ICEM Hexa. This is good for block-structured meshes like wing flows. However, for real complex car shapes you will need lots of time to generate block structered grids. Therefore it is quite common to use more automatic methods like hexcore meshes. Hexcore meshes in ICEM Tetra can only generate hexas with a uniform edge length. His is a stupid restriction. It is better to uses hexahedrals of different sizes like T-Grid or ANSA can do or even more hex-dominant meshes (quality trobles!)

Regards

morfeus80 February 22, 2008 11:47

BastiL, my residuals are very
 
BastiL,
my residuals are very low (10^-8), but the wake has an absurd shape.

The solver settings I used are:

ddtSchemes
{
default steadyState;
}

gradSchemes
{
default fourth;
grad(p) fourth;
grad(U) fourth;
}

divSchemes
{
default none;
div(phi,U) Gauss SFCD;
div(phi,k) Gauss SFCD;
div(phi,epsilon) Gauss SFCD;
div(phi,R) Gauss SFCD;
div(R) Gauss linear;
div(phi,nuTilda) Gauss SFCD;
div((nuEff*dev(grad(U).T()))) Gauss linear;
}

laplacianSchemes
{
default none;
laplacian(nuEff,U) Gauss linear corrected;
laplacian((1|A(U)),p) Gauss linear corrected;
laplacian(DkEff,k) Gauss linear corrected;
laplacian(DepsilonEff,epsilon) Gauss linear corrected;
laplacian(DREff,R) Gauss linear corrected;
laplacian(DnuTildaEff,nuTilda) Gauss linear corrected;
}

interpolationSchemes
{
default linear;
interpolate(U) linear;
}

snGradSchemes
{
default corrected;
}

fluxRequired
{
default no;
p;
}


// ************************************************** *********************** //


solvers
{
p GAMG
{
tolerance 1e-08;
relTol 0;
smoother GaussSeidel;
nCellsInCoarsestLevel 40;
mergeLevels 1;
agglomerator faceAreaPair;
cacheAgglomeration off;
nPreSweeps 0;
nPostSweeps 2;
nFinestSweeps 2;
scaleCorrection true;
directSolveCoarsest false;
};
U BICCG 1e-07 0;
k BICCG 1e-06 0;
epsilon BICCG 1e-06 0;
R BICCG 1e-06 0;
nuTilda BICCG 1e-06 0;
}

SIMPLE
{
nNonOrthogonalCorrectors 1;
pRefCell 0;
pRefValue 0;
}

relaxationFactors
{
p 0.3;
U 0.4;
k 0.5;
epsilon 0.5;
R 0.7;
nuTilda 0.5;
}




----------------------------------

Hrv suggested these settings in another topic of this forum.
What's your opinion?

hjasak February 22, 2008 12:45

? Did I really - this looks pr
 
? Did I really - this looks pretty bizarre to me.

gradSchemes
{
default fourth;
grad(p) fourth;
grad(U) fourth;
}

Nope. Use Gauss linear or leastSquares if your mesh is bad.

div(phi,k) Gauss SFCD;
div(phi,epsilon) Gauss SFCD;
div(phi,R) Gauss SFCD;


Here, Gauss upwind is probably good enough.

For momentum convection, try

div(phi,U) Gauss GammaV 0.5; and see if it converges. If not, we can talk more...

Hrv

morfeus80 February 22, 2008 16:02

I'm sorry, Vincent RIVOLA used
 
I'm sorry, Vincent RIVOLA used these settings.

On manday I'll test with the schemes you suggest. According your opinion, are the solvers OK? Is it possible make iterations faster?

Another thing: in each time step, that should be an iteration counter for steady solvers, there are several iterations inside. Why?

bastil February 23, 2008 04:08

Mattia, how bad is your mes
 
Mattia,

how bad is your mesh? Btw, how did you create it? Could you post the output from checkMesh, please. It might be worth trying to reduce nNonOrthogonalCorrectors to 0 if your mesh is not too bad. This will give you an aditional speedup.
Youre right, a timesteps corresponds to what other solvers call iteration. The output of iterations give you the inner iterations for each variable (called sweeps in STAR). Hrv please correct me if I am wrong.

Regards

morfeus80 February 23, 2008 08:03

BastiL, I use a tetrahedral m
 
BastiL,
I use a tetrahedral mesh of 1.3mil cells and I think it's quite good. Max cell skewness is less than 0.40 . However on monday I'll post the checkMesh result.

bastil February 23, 2008 09:26

Mattia, quality sounds good
 
Mattia,

quality sounds good. I am looking forward to see the checkMesh results. What tool did you use? Is it komplex geometry? Cell count is low so I guess it is a more simple shape?

In general perver hexahedral over tetras so aim for more hex-dominant meshes.

Regards

juho February 23, 2008 09:48

I'm baffled by the pressure re
 
I'm baffled by the pressure results in my case.

My free stream velocity is 30m/s

After 3000 iterations, and max. pressure hasn't changed much during the last 1500 of them, simpleFoam gives a stagnation pressure of 672 at the front of the car.

Shouldn't it be 30²/2 = 450?

What am I missing?

morfeus80 February 25, 2008 12:43

Hallo, this is the output of
 
Hallo,
this is the output of checkMesh:


Mesh stats
points: 262914
edges: 1633690
faces: 2644429
internal faces: 2450187
cells: 1273654
boundary patches: 7
point zones: 0
face zones: 0
cell zones: 0

Number of cells of each type:
hexahedra: 0
prisms: 0
wedges: 0
pyramids: 0
tet wedges: 0
tetrahedra: 1273654
polyhedra: 0

Checking topology...
Boundary definition OK.
Point usage OK.
Upper triangular ordering OK.
Topological cell zip-up check OK.
Face vertices OK.
Face-face connectivity OK.
Number of regions: 1 (OK).

Checking patch topology for multiply connected surfaces ...
Patch Faces Points Surface
Ahmed_body 55893 28228 ok (not multiply connected)
simmetry 59808 30528 ok (not multiply connected)
side 5778 3066 ok (not multiply connected)
outlet 546 305 ok (not multiply connected)
inlet 539 301 ok (not multiply connected)
road 66226 33517 ok (not multiply connected)
top 5452 2902 ok (not multiply connected)

Checking geometry...
Domain bounding box: (-11 -9.1e-06 -0.05) (5 1.5 1.5)
Boundary openness (-1.88276e-17 1.94498e-15 2.05761e-15) OK.
Max cell openness = 1.70742e-16 OK.
Max aspect ratio = 7.26466 OK.
Minumum face area = 1.3057e-06. Maximum face area = 0.012724. Face area magnitudes OK.
Min volume = 6.59628e-10. Max volume = 0.000420286. Total volume = 37.1445. Cell volumes OK.
Mesh non-orthogonality Max: 67.8068 average: 19.6179
Non-orthogonality check OK.
Face pyramids OK.
Max skewness = 0.97498 OK.
Min/max edge length = 0.00165297 0.196461 OK.
All angles in faces OK.
All face flatness OK.

Mesh OK.

bastil February 25, 2008 13:23

Looks like a pretty good mesh.
 
Looks like a pretty good mesh. Try zero non-orthogonal correctors. This will speed up your solution. What software did you use for meshing?

Regards


All times are GMT -4. The time now is 08:35.