CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   SU2 Shape Design (https://www.cfd-online.com/Forums/su2-shape-design/)
-   -   Shape returning to the initial condition (https://www.cfd-online.com/Forums/su2-shape-design/135776-shape-returning-initial-condition.html)

shsreekanth May 17, 2014 13:45

Shape returning to the initial condition
 
1 Attachment(s)
Hi,

When i run the simulation for optimization, I find that after an initial deformation, it gradually tends to get back to the initial shape. This repeats again.
I know that there is better solution, so it cant be that the initial solution is best.

What could I be doing wrong?

Configuration file is attached.

NB: My objective is to minimize the lift, hence i have multiplied the objective with a negative number.

Please have a look and let me know what all things I could be doing wrong. I have to finish my project soon but I am getting stuck at different places with SU2

Thank you.

Sreekanth

btracey May 19, 2014 17:00

How are you calling the optimization?

shsreekanth May 20, 2014 01:45

shape_optimization.py -f coarsecavity.cfg -p 2

cemonair June 4, 2015 20:04

I have the same problem with the latest version of rotating NACA0012 test case. I don't get the same result with the tutorial without changing anything. NACA0012 goes back to NACA0012 after 37 designs and stays there.

shape_optimization.py -f rotating_NACA0012.cfg

Also I can't get the results in Figure (8): Function evaluation history in tutorial. Drag does not change much during evaluations and at the end goes back to the same location.

Here is the output, looks like OBJFUN and GNORM is not changing much

NIT FC OBJFUN GNORM
1 1 2.158280E-06 2.223470E-03
2 12 2.158351E-06 2.224594E-03


Developers: can you please check this?
Thanks!!

WillemFloris January 18, 2017 05:03

Hello Sreekanth and Cemonair,


Have you already found a possible solution for this problem?
I have the same problem as well...

I appreciate any help/suggestions of you ;)

Kind regards,

Floris

S.Kontogiannis January 23, 2017 12:54

Hello,

In the history of the optimization, is there any design point actually superior than your initial point?
If not, could it be simply that the initial point is a local optimum of your design space?

Spyros

WillemFloris January 24, 2017 03:42

Hi Spyros,

Yes I checked that, the first new shape is improving the object function. I checked this for a drag as objective function and for lift over drag (efficiency) as objective function. Both optimizations have the same progress; initial design--first optimized design (which is improving the objective function)---back to initial shape.

Kind regards,

Floris

Ryan. August 10, 2017 16:57

Quote:

Originally Posted by WillemFloris (Post 634490)
Hi Spyros,

Yes I checked that, the first new shape is improving the object function. I checked this for a drag as objective function and for lift over drag (efficiency) as objective function. Both optimizations have the same progress; initial design--first optimized design (which is improving the objective function)---back to initial shape.

Kind regards,

Floris

Hi,

I'm dealing with the same problem. Did you manage to fix it somehow? I would appreciate it if you could let me know.

Thanks.

WillemFloris August 11, 2017 02:07

Hi Ryan,

Apparently this behavior appears when no improved design has been found. The objective function is decreasing, however not sufficient (Armijo-Goldstein conditions).

Reducing the objective scale is a remedy for this typical behavior, however the deviations in shape are so small that it is barely noticeable. In this case, increase the scale of DEFINITION_DV.

It helps when you put "restart flow" on "yes".

Furthermore I would like to refer you to: https://github.com/su2code/SU2/issues/409. In here, the results that can be checked to ensure a proper optimization are pointed out.

I hope this helped you. Please let me know your foundings:).

Cheers!

Floris van der Schuur

Ryan. August 11, 2017 13:03

Quote:

Originally Posted by WillemFloris (Post 660297)
Hi Ryan,

Apparently this behavior appears when no improved design has been found. The objective function is decreasing, however not sufficient (Armijo-Goldstein conditions).

Reducing the objective scale is a remedy for this typical behavior, however the deviations in shape are so small that it is barely noticeable. In this case, increase the scale of DEFINITION_DV.

It helps when you put "restart flow" on "yes".

Furthermore I would like to refer you to: https://github.com/su2code/SU2/issues/409. In here, the results that can be checked to ensure a proper optimization are pointed out.

I hope this helped you. Please let me know your foundings:).

Cheers!

Floris van der Schuur

Thank you Floris, for your quick reply. I will try to modify the scales as you described. I changed the optimizer to POWELL and it seems to be working just fine but my simulation is still running so maybe it's too soon to judge.

tomp1993 August 29, 2017 11:09

Hi All,
I am having the same issue as described above!
for a 2D shape design case, the optimizer takes one or two steps in a direction which minimizes drag (the first iteration being the most effective, reducing drag by nearly 2 counts), but then every subsequent design tends back towards the original design!
i have tried reducing the scale of OPT_OBJECTIVE and OPT_CONSTRAINT to 1e-5 whilst increasing the scale of DEFINITION_DV to as suggested above but this unfortunately did not help the situation.
any more help would be vastly appreciated!
thanks
Tom

tomp1993 August 29, 2017 11:52

UPDATE:
i have just discovered that the adjoint gradient for the optimization is only being calculated for the first design iteration; then every subsequent design iteration only carries out 'DIRECT', 'GEOMETRY' and 'DEFORM' processes.
This is very confusing, i'm not sure why the optimizer wouldn't calculate a sensitivity gradient for every design step?

WillemFloris August 30, 2017 01:45

Hi Tom,

In order to give an suggestion, you have to provide more information about your test case (config file, output files, etc). For now, I can give you the following information:

Returning to initial design indicates that the optimizer did not find any improved design. So first it calculates the direct solution after which the sensitivity is determined. Subsequently line searches takes place to find an improved design. When after 11 searches no improved design is found, it takes the 12th design and calculates the direct and adjoint again.

It is indeed good to play around with the scales, but keep it organized.

During the test cases please check the sensitivities (adjoint & direct) and the output files indicated in https://github.com/su2code/SU2/issues/409.

Please search for the theory of SQP optimizers (SU2 uses the SLSQP, which is a based on SQP optimizers). If you understand the theory, I suggest you to have a look at the source code of the optimizer: https://github.com/scipy/scipy/blob/.../slsqp_optmz.f.

I hope I give you enough information about the gradient based optimization technique of SU2:).

Kind regards,

Floris van der Schuur

tomp1993 August 30, 2017 10:09

1 Attachment(s)
Hi Floris,
Thanks for the detailed information and links! i will read more into the workings of the optimizer.
when you say that 11 line-searches are performed, is this number of attempts arbitrary, or is there a reason for it to be 11?
As requested here is a txt copy of the config file which i have been using.
Attachment 58105
thankyou for taking the time to educate me a little bit! your help is much appreciated.
Tom


All times are GMT -4. The time now is 09:02.