CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > General Forums > Main CFD Forum

Requesting help for validating software

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 27, 2010, 17:44
Default Requesting help for validating software
  #1
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 16
HectorRedal is on a distinguished road
Hi,

I am currently developing a software for solving incompressible / compressible fluids flows using the finite element method.
Right now, I am testing the software by simulating a lid driven cavity.
For validating the software I am using the data provided in the following link:
http://web.gyte.edu.tr/enerji/ercane...cavityflow.htm

The results I have obtained are quite different from the stated in the link above.
I would like to know if the problem is that the simulation time is not so long as to get the steady state.

For a Reynolds number of 1000, I am taken a simulation interval of 20 seconds. I don't know if this time is long enough so as to get the steady state. I have re-run the simulation upto 30 seconds, but the results are pretty similar, so I assume that the steady state is reached. Is this assumption correct?

I am enclosing two graphs (jpg files) that are the comparison between the reference results and the results I have got. You can take a look at them.

Could anyone help me with this issue?

Thanks in advance for your help and time,

Hector Redal.
Attached Images
File Type: jpg Cavity_u.JPG (25.6 KB, 14 views)
File Type: jpg Cavity_v.JPG (21.4 KB, 11 views)
HectorRedal is offline   Reply With Quote

Old   August 28, 2010, 11:08
Default
  #2
otd
Member
 
private
Join Date: Mar 2009
Posts: 74
Rep Power: 17
otd is on a distinguished road
Some observations of the comparison solutions you posted. This is to suggest things you might consider, NOT criticism.

Your solution appears to be either (1) not fully converged, or (2) belonging to a much more viscous fluid.

Possible reasons for (1) is that it should be run for longer times.

Possible reasons for (2):
(a) The finite element solution generates numerical errors that appear as an effective or computational 'viscosity' that is much larger than the physical value prescribed for the fluid.
(b) The mesh you have used is inadequate, again resulting in a falsely large viscosity for the computation.
(c) The time step you've used is too large, causing convergence to a false solution.
I'm sorry that I'm using finite difference language. I assume that the concepts exist in finite element lingo - but I don't know that language.

Anyway, you might want to try again using much smaller elements. Also consider using smaller time steps for your marching.

Good luck!
otd is offline   Reply With Quote

Old   August 29, 2010, 03:15
Default
  #3
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 16
HectorRedal is on a distinguished road
Hi otd,

First of all, I would like to thank you for your time and support.
The information you have provided to me is very valuable.
I have been working in the cfd field only for one year and a half, and as you can see, I have still a lot to learn.
And, only to add that the observations you have provided are very good, and they don't contain any kind of criticism. So, thank you!!

For debugging this problem, I have followed the strategy pointed out by you.

Regarding suggestion (1), I have rerun the case for longer time (from 20 seconds to 100 seconds) and the results are pretty similar: no significant change can be seen.

So, I am affraid, that as you have suggested, there are some programmatic errors in the code that is adding artiffical 'viscosity' to the solution.

I have followed the hints for (2), and the results obtained are not very promising:
Either changing the size of the mesh or changing the time step does not affect the converged solution.
So, the only option left is the errors in the implementation of the code. I am afraid I will have to debug the code so as to find the problematic module.

Other hypothesis I am thinking about is that as the reference length for calculating the Reynolds number I have taken one of the side of the square. Maybe in the reference, the reference length might have be taken for the diagonal of the square.
I don't know if this difference may account for the differences in the results.
I suppose that this is not the case, since the differences from the results obtained with the code I am developing and the results from the reference are very high.

Anyway, once again, thank you for your suggestions.

Best regards,
Hector.
HectorRedal is offline   Reply With Quote

Old   August 30, 2010, 05:27
Default
  #4
Member
 
ganesh
Join Date: Mar 2009
Posts: 40
Rep Power: 17
ganesh is on a distinguished road
Dear Hector,

I am not sure if this might help you, but following are some of my suggestions.

1. If you are trying with a grid that is not cartesian, please try first with a uniform cartesian mesh, say a 50*50 for a unit square domain will suffice.

2. Re is calculated based on the characteristic length which is the cavity length, using the diagonal doesnt change the Re much (in terms of order of magnitude), so if results are wrong at 100 it is going to be wrong at 200 too.

3. If a non cartesian grid is employed for the results that you have shown, try running at a higher Re, say 5000 and see if the results are closer.

4. Also consider running the simulation to steady state by not considering the total time as such (like 20 s or 30 s), but by measuring the error in residuals, say the normalised error in the kinetic energy measured in an L2 norm over the entire domain must be less than some tolerance typically 1e-6.

I have had problems with non--cartesian meshes when running at lower Re using a finite volume staggered mesh framework, and it appeared quite evidently in that the vortex pattern (plot streamlines to see this) was completely wrong, esp. the corners. If you are facing similar problems, which also reflect in the profiles, then the issue is mostly with the computation of viscous fluxes.
Also make sure that there is no mass leakage, in particular, the divergence constraint is being satisfied to reasonable accuracy.

Hope this helps.

Regards,
Ganesh
ganesh is offline   Reply With Quote

Old   September 4, 2010, 11:32
Default
  #5
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 16
HectorRedal is on a distinguished road
Hi Ganesh,

First of all, I would like to thank you for your suggestions.

I am going to add some useful information regarding this issue.
1.- The type of grid I am using is cartesian. It is not an uniform gratesian grid, but a grade cartesian grid (with finner grid in the boundaries of the cavity).
2.- I have re-run the simulation with a higher Reynolds number, but the results are even worse. You can take a look at the picture I am enclosing.

You have suggested to measure the error in residuals, so as to determine if the flow has reached the steady state. This will take some time, since the code has been developed by me and I will have to include this type of calculation in the software.

I will come back when I have finished the implementation of this computation.

Thanks for your help and support.

Best regards,
Hector.
Attached Images
File Type: jpg Cavity_u_Re10000.JPG (20.8 KB, 4 views)
HectorRedal is offline   Reply With Quote

Reply

Tags
finite element method, lid driven cavity

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[CAD formats] Hexahedral meshing of CAD files - Which free software? Wolle OpenFOAM Meshing & Mesh Conversion 14 November 22, 2014 22:40
CAD integrated CFD Software kostikr Main CFD Forum 3 February 4, 2010 15:38
Need help in proper CFD software AMusteykis Main CFD Forum 0 September 6, 2009 09:28
Visualization Software for CFD Paul Main CFD Forum 3 March 25, 2006 18:16
Waterhammer software Andris Skattebo Main CFD Forum 1 July 18, 1998 22:01


All times are GMT -4. The time now is 07:18.