when to take outputs of my simulation

Hi,

I am having some doubts about in which routine of my code I must write my velocity and density outputs in order to have realistic results. Does anybody know how when do I have to write it in a generic way or do I need to be specific on my code?

Anyway I use basic bounceback in a channel flow. 2DQ9, and I want to visualize correctly my vortex shedding.

Thanks in advanced,

Puigar

Hi,

I write results into a .dat file after iterations until some convergence criterion is achieved. Then I use TecPlot to see the results.

You can see my code of Poiseuille flow for reference

https://www.dropbox.com/sh/40oc1f5c97ezmbm/QowAWvPLMj

If I have an unsteady flow due to vortex shedding passing the Critical Reynolds number, which criterion do I need to have in mind in order to say that my simulation is already “stable”?

I am now using a high amount of time steps and I figure out when my peak-to-peak lift force becomes a sinusoidal wave with the same amplitude. Which tolerance do you think I must set up in this case?

Thank you for your answer tanmaya.

Regards

Hi Puigar,

I generally use higher time steps whenever I exceed critical Re.

I think that some convergence criterion such as difference of velocity in two consecutive iterations at some monitor point could be apply. Although I am not sure about it.

I am a learner of LBM still, so I look forward for some expert to help you.

Best regards
Tanmay

Well, thanks for your reply Tanmay,

The real purpose of my question is no to find the exact timestep which I do have to get my outputs, but to know in which routine of my program I should have my file written. I mean if I have a loop scheme like:

initialization

begin loop

inlet outlet boundary conditions treatment
Wall Bounceback
Comput Macroscopic properties
Compute f_eq
Collision
second order Boundary treatment (Mei et al. 32,33)
[b]WRITE OUTPUT[/b]
Streaming

end of loop

Should it be like this?

Hi,

I write my results after all the things i.e. after doing streaming, collision and boundary conditions for time step number of times.
Just have a look at my codes to understand what I mean to say.

Thanks

Tanmay

Hi Puigar,

As far as I remember it should be like this:
Advection and collision are (physically) instantaneous.
This is not the case in LBM, therefore some people save the output at half timesteps.
This is achieved by averaging of pre and post-collision data.
A quick search and skimming Nguyen and Ladd 2002 (DOI: 10.1103/PhysRevE.66.046708) indicates that this is used for force coupling, but I don’t see why e.g. density shouldn’t be just as instantaneous.
EDIT:
By coincidence I’m just reading the Ladd and Verberg 2001(DOI:10.1023/A:1010414013942) paper, that shows the difference in error of before,after and midway, as compared to the analytical solution. This paper then is the answer to your question. The velocity field should be measured in the middle of each time step.

Thank you dennis
Are you in the icmmes congress??

Regards

Puigar

Hi Puigar,

you are welcome.
The second paper really was a lucky coincidence. I was curious before, how much this improves the result and if it really is worth the overhead.
Apparently it is.
No, sadly I’m not at the ICMMES conference. Hopefully next time.

Regards
Dennis