# [Tutorial 3] Doubts about iteration number

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

 April 16, 2014, 20:04 [Tutorial 3] Doubts about iteration number #1 Member   Carlos Alexandre Tomigawa Aguni Join Date: Mar 2014 Posts: 40 Rep Power: 4 Did anyone do the Tutorial 3 (Laminar Cylinder)? Why is it set to do 9999 iterations? If it's possible to change that what's the best suitable number to put? Thanks in advance! Edit1: This thread has advanced! Please check my following posts! Last edited by CrashLaker; April 16, 2014 at 22:09.

 April 16, 2014, 20:24 #2 Member   Carlos Alexandre Tomigawa Aguni Join Date: Mar 2014 Posts: 40 Rep Power: 4 I've noticed that 9999 was the maximum number of iterations.. So where do I find how many iterations is it set to do? My program goes far till 7k then crashes... Any help?

April 16, 2014, 22:19
#3
Member

Carlos Alexandre Tomigawa Aguni
Join Date: Mar 2014
Posts: 40
Rep Power: 4
I've just realized that running it in serial the calculations don't reach the breaking point (this I suppose is the convergence they talk about on the tutorial).

So.. when running it in serial or setting np = 1 (if one use any mpi implementation) it just goes till the 9999th iteration

Can you explain why is that?

Example where I've set np = 2
Quote:
 Iter Time(s) Res[Rho] Res[RhoE] CLift(Total) CDrag(Total) 420 0.798929 -11.861028 -6.468419 -0.005113 1.548706 421 0.798910 -11.869982 -6.480136 -0.005113 1.548706 422 0.798895 -11.878834 -6.491870 -0.005113 1.548706 423 0.798879 -11.887588 -6.503607 -0.005113 1.548705 424 0.798863 -11.896239 -6.515355 -0.005113 1.548705 425 0.798847 -11.904784 -6.527122 -0.005113 1.548705 426 0.798834 -11.913214 -6.538915 -0.005113 1.548705 427 0.798823 -11.921537 -6.550715 -0.005113 1.548705 428 0.798811 -11.929736 -6.562532 -0.005113 1.548705 429 0.798797 -11.937814 -6.574367 -0.005113 1.548705 430 0.798782 -11.945750 -6.586230 -0.005113 1.548705 431 0.798766 -11.953555 -6.598090 -0.005113 1.548705 432 0.798750 -11.961219 -6.609973 -0.005113 1.548705 433 0.798734 -11.968734 -6.621870 -0.005113 1.548705 434 0.798716 -11.976098 -6.633788 -0.005113 1.548705 435 0.798698 -11.983323 -6.645670 -0.005113 1.548704 436 0.798683 -11.990378 -6.657576 -0.005114 1.548704 437 0.798675 -11.997265 -6.669486 -0.005114 1.548704 438 0.798658 -12.003985 -6.681365 -0.005114 1.548704 History file, closed.
Example when I run it in serial
Quote:
 Iter Time(s) Res[Rho] Res[RhoE] CLift(Total) CDrag(Total) 7860 1.396446 -11.777780 -5.518481 -0.005118 1.548717 7861 1.396445 -11.776718 -5.518419 -0.005118 1.548717 7862 1.396443 -11.777780 -5.518481 -0.005118 1.548717 7863 1.396442 -11.776718 -5.518419 -0.005118 1.548717 7864 1.396440 -11.777780 -5.518481 -0.005118 1.548717 7865 1.396438 -11.776718 -5.518419 -0.005118 1.548717 7866 1.396437 -11.777780 -5.518481 -0.005118 1.548717 7867 1.396436 -11.776718 -5.518419 -0.005118 1.548717 7868 1.396435 -11.777780 -5.518481 -0.005118 1.548717 7869 1.396433 -11.776718 -5.518419 -0.005118 1.548717 7870 1.396431 -11.777780 -5.518481 -0.005118 1.548717 7871 1.396430 -11.776718 -5.518419 -0.005118 1.548717 7872 1.396430 -11.777780 -5.518481 -0.005118 1.548717 7873 1.396427 -11.776718 -5.518419 -0.005118 1.548717 7874 1.396427 -11.777780 -5.518481 -0.005118 1.548717 7875 1.396425 -11.776718 -5.518419 -0.005118 1.548717 7876 1.396422 -11.777780 -5.518481 -0.005118 1.548717 7877 1.396422 -11.776718 -5.518419 -0.005118 1.548717 7878 1.396421 -11.777780 -5.518481 -0.005118 1.548717
You can see that Cdrag and Clift remains the same after each iteration. And "res" is repeating by 2. After that my process crashed (but this was a problem with my cluster so.. it should've ran up to the 9999th iteration).

April 18, 2014, 09:19
#4
Super Moderator

Francisco Palacios
Join Date: Jan 2013
Location: Long Beach, CA
Posts: 342
Rep Power: 6
Quote:
 Originally Posted by CrashLaker I've just realized that running it in serial the calculations don't reach the breaking point (this I suppose is the convergence they talk about on the tutorial). So.. when running it in serial or setting np = 1 (if one use any mpi implementation) it just goes till the 9999th iteration Can you explain why is that? Example where I've set np = 2 Example when I run it in serial You can see that Cdrag and Clift remains the same after each iteration. And "res" is repeating by 2. After that my process crashed (but this was a problem with my cluster so.. it should've ran up to the 9999th iteration).

You are probably satisfying another criteria before arriving to the maximum number of iterations.

Currently we SU2 have in place CAUCHY and RESIDUAL which are controlled by

% --------------------------- CONVERGENCE PARAMETERS --------------------------%
%
% Convergence criteria (CAUCHY, RESIDUAL)
%
CONV_CRITERIA= RESIDUAL
%
% Residual reduction (order of magnitude with respect to the initial value)
RESIDUAL_REDUCTION= 5
%
% Min value of the residual (log10 of the residual)
RESIDUAL_MINVAL= -8
%
% Start convergence criteria at iteration number
STARTCONV_ITER= 10
%
% Number of elements to apply the criteria
CAUCHY_ELEMS= 100
%
% Epsilon to control the series convergence
CAUCHY_EPS= 1E-10
%
% Direct function to apply the convergence criteria (LIFT, DRAG, NEARFIELD_PRESS)
CAUCHY_FUNC_FLOW= DRAG

Cheers,
Francisco

 April 18, 2014, 10:55 #5 Member   Carlos Alexandre Tomigawa Aguni Join Date: Mar 2014 Posts: 40 Rep Power: 4 Hello Francisco! Thanks for your reply! But the config files were supposed to work without any modification right? The thing is that with the same config the serial execution doesn't finishes and setting np = 2 it takes just few seconds to accomplish. Why is that? Thanks in advance. Carlos.

 April 24, 2014, 04:54 #6 Super Moderator   Thomas D. Economon Join Date: Jan 2013 Location: Stanford, CA Posts: 270 Rep Power: 6 Hi Carlos, As Francisco mentions above, the simulation will terminate if any of the following criteria is met (whichever happens first): 1. The magnitude of the density residual drops the specified number of orders relative to the initial value, e.g., -2 -> -7 if 5 orders reduction is requested 2. The density residual reaches the specified minimum value in RESIDUAL_MINVAL 3. The simulation hits the max number of allowed iterations in EXT_ITER Lastly, note that, depending on the chosen methods, the residual history will not be the same for serial and parallel calculations. This is likely why one of the conditions above is being met in serial and not in parallel, or vice-versa. Hope this helps clear it up, Tom CrashLaker and helicopterliu like this.

April 27, 2014, 23:21
#7
Member

Carlos Alexandre Tomigawa Aguni
Join Date: Mar 2014
Posts: 40
Rep Power: 4
Quote:
 Originally Posted by economon Hi Carlos, As Francisco mentions above, the simulation will terminate if any of the following criteria is met (whichever happens first): 1. The magnitude of the density residual drops the specified number of orders relative to the initial value, e.g., -2 -> -7 if 5 orders reduction is requested 2. The density residual reaches the specified minimum value in RESIDUAL_MINVAL 3. The simulation hits the max number of allowed iterations in EXT_ITER Lastly, note that, depending on the chosen methods, the residual history will not be the same for serial and parallel calculations. This is likely why one of the conditions above is being met in serial and not in parallel, or vice-versa. Hope this helps clear it up, Tom
Thank you so much Economon

 Thread Tools Display Modes Linear Mode

 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 OffTrackbacks are On Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post almir OpenFOAM Running, Solving & CFD 62 June 16, 2016 03:01 Ardalan Main CFD Forum 6 April 17, 2010 23:40 chelvistero OpenFOAM 11 January 15, 2010 20:43 Allan CFX 3 April 14, 2009 05:03 Javier Larrondo FLUENT 0 October 28, 2007 23:30

All times are GMT -4. The time now is 22:49.