CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   CFX (https://www.cfd-online.com/Forums/cfx/)
-   -   The initial transient part of the solution takes too long to fade (https://www.cfd-online.com/Forums/cfx/247253-initial-transient-part-solution-takes-too-long-fade.html)

Ashkan Kashani January 23, 2023 11:17

The initial transient part of the solution takes too long to fade
 
Hi all,

I'm doing a series of 2D transient simulations of separated and reattached flow past a sharp-edged rectangular body.
According to previous recommendations on this forum, I opted to set an adaptive timestep based on a target minimum/maximum number of coefficient loops to ensure a proper temporal resolution, which leads to very small timesteps in my simulation.
Despite initializing the simulation using a relevant solution previously obtained, the initial transient part of the solution appears to take a very long simulation time to fade, considering the small timesteps imposed by the adaptive timestepping. This is unfortunately beyond the computational resources available to me.
I'm wondering what could be done to reach the stationary solution faster since I'm not interested in the initial transient part. Is it reasonable to manually choose a much bigger timestep?

I appreciate any comments.

ghorrocks January 23, 2023 16:46

Yes, you can use a bigger time step. Returning to a smaller time step to fully resolve the flow will then result in a new transient which you will have to wait for it to fade out, but as long as you carefully choose the bigger time step it should be manageable.

Another alternative is you could use 1st order time differencing for a while. That will have extra dissipation and mean you will not have to change the time step as much.

Ashkan Kashani January 28, 2023 14:08

Thank you for your comment. I would also appreciate any comments on the following.
1- Among the options for adaptive timestep setting in CFX, homing on 3 to 5 loops has been mostly recommended on this forum. I'm wondering about the physical explanation behind such a setting and also wondering why it's said that setting the timestep based on max/rms courant number is not as useful.
2- Regarding my simulation objective (time-averaged flow past a sharp-edge rectangular body), i think the timestep based on 3 to 5 loops leads to a very conservative time marching, probably picking on very slowly-evolving structures that delay statistically converged flow and are also insignificant in the time-averaged field. Could this be true?
3- According to the literature and my personal understanding, the best practice is to choose a timestep based on the range of Strouhal numbers known from previous works. This is done by sweeping each cycle of vortex shedding (corresponding to the dominant frequency) through a number of timesteps, let's say n. What is an appropriate value for n. Well, i couldn't find any consensus on this matter in the literature. I understand that this should be really determined through a sensitivity analysis. But since i can't afford the computational costs, i'm hoping there's a reasonable empirical choice to go with.

ghorrocks January 28, 2023 18:52

Some astute questions there.

Quote:

Among the options for adaptive timestep setting in CFX, homing on 3 to 5 loops has been mostly recommended on this forum. I'm wondering about the physical explanation behind such a setting
It is because the CFX solver generally works best in a transient simulation when the solver is doing a small number of coeff loops per iteration, so less than 5. And you set a minimum of 3 so that if the time step is too small it will then detect this and make the time step larger.

Through experience (both mine and that of ANSYS) it has been found that almost always when you are using 3-5 coeff loops per iteration you also have an accurately time resolved simulation. If you actually want to prove your time accuracy you should do a sensitivity check, but for most purposes if you have 3-5 coeff loops per iteration that is good enough and means you can be confident you are adequately time resolved with having the hassle of doing the sensitivity check.

Quote:

why it's said that setting the timestep based on max/rms courant number is not as useful.
Because what Courant number do you make it use? CFX is an implicit solver, so has no strict Courant number limit (like explicit solvers do). The Courant number you can use depends on the flow, your accuracy requirements, your mesh etc, so you need to determine what Courant number you need for your simulation. And if you need to determine it, then there is no the advantage of using Courant number over just the time step size in seconds.

Quote:

Regarding my simulation objective (time-averaged flow past a sharp-edge rectangular body), i think the timestep based on 3 to 5 loops leads to a very conservative time marching, probably picking on very slowly-evolving structures that delay statistically converged flow and are also insignificant in the time-averaged field. Could this be true?
3-5 Coeff loops will usually result in a time step size to capture all modelled time scales in the simulation, including the very small ones. In your case, yes it will then give a small time step which will be to capture the very small structures.

But do not fall into the mistake of thinking that a simulation which is not fully time resolved and therefore blurrs out some of the smaller transient features is the same as the time averaged result. This is not correct! A not fully time resolved simulation has an uncontrolled error of some size in it, and the time averaged result is the time average of a fully accurate time resolved simulation. They are not equivalent.

Quote:

According to the literature and my personal understanding, the best practice is to choose a timestep based on the range of Strouhal numbers known from previous works.
Yes, that can give you a good starting point, but only a starting point. What you do from there depends on how accurate you want to be. If you want to be really accurate you then should do a proper time step sensitivity analysis to set the time step, if you can handle a level of error then estimating the time step directly from the Strouhl number is a reasonable short cut.

But repeating my previous point, do not assume that a transient simulation which does not properly resolve the time scales is equivalent to the time-averaged flow.


All times are GMT -4. The time now is 10:47.