|
[Sponsors] |
Problem about multipoint optimization with geometry constraint |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
May 30, 2022, 12:08 |
Problem about multipoint optimization with geometry constraint
|
#1 |
New Member
zhou
Join Date: Mar 2019
Posts: 8
Rep Power: 7 |
Hi,
I want to process a multipoint optimization with constraints. The problem I encountered is that, if I set OPT_CONSTRAINT=NONE or a flow based constraint function(e.g. MULTIPOINT_MOMENT_Z), the optimization goes well. But if the geometry based constraint is given to OPT_CONSTRAINT(e.g. OPT_CONSTRAINT=( AIRFOIL_THICKNESS>0)*0.001 like onepoint problem ), the error will occur as below. The cfg file is based on inv_NACA0012_multipoint.cfg that is from TestCase and it is put in the attachment. I have no idea what the problem is. I can't find the answer anywhere else. _____________________________________ Traceback (most recent call last): File "/home/star/su2/bin/shape_optimization.py", line 183, in <module> main() File "/home/star/su2/bin/shape_optimization.py", line 92, in main shape_optimization( options.filename , File "/home/star/su2/bin/shape_optimization.py", line 159, in shape_optimization SU2.opt.SLSQP(project,x0,xb,its,accu) File "/home/star/su2/bin/SU2/opt/scipy_tools.py", line 120, in scipy_slsqp outputs = fmin_slsqp( x0 = x0 , File "/usr/local/python/lib/python3.8/site-packages/scipy/optimize/_slsqp_py.py", line 206, in fmin_slsqp res = _minimize_slsqp(func, x0, args, jac=fprime, bounds=bounds, File "/usr/local/python/lib/python3.8/site-packages/scipy/optimize/_slsqp_py.py", line 374, in _minimize_slsqp sf = _prepare_scalar_function(func, x, jac=jac, args=args, epsilon=eps, File "/usr/local/python/lib/python3.8/site-packages/scipy/optimize/_optimize.py", line 263, in _prepare_scalar_function sf = ScalarFunction(fun, x0, args, grad, hess, File "/usr/local/python/lib/python3.8/site-packages/scipy/optimize/_differentiable_functions.py", line 158, in __init__ self._update_fun() File "/usr/local/python/lib/python3.8/site-packages/scipy/optimize/_differentiable_functions.py", line 251, in _update_fun self._update_fun_impl() File "/usr/local/python/lib/python3.8/site-packages/scipy/optimize/_differentiable_functions.py", line 155, in update_fun self.f = fun_wrapped(self.x) File "/usr/local/python/lib/python3.8/site-packages/scipy/optimize/_differentiable_functions.py", line 137, in fun_wrapped fx = fun(np.copy(x), *args) File "/home/star/su2/bin/SU2/opt/scipy_tools.py", line 383, in obj_f obj_list = project.obj_f(x) File "/home/star/su2/bin/SU2/opt/project.py", line 237, in obj_f return self._eval(konfig, func,dvs) File "/home/star/su2/bin/SU2/opt/project.py", line 206, in _eval vals = design._eval(func,*args) File "/home/star/su2/bin/SU2/eval/design.py", line 147, in _eval vals = eval_func(*inputs) File "/home/star/su2/bin/SU2/eval/design.py", line 244, in obj_f func += su2func(this_obj,config,state) * sign * scale * global_factor File "/home/star/su2/bin/SU2/eval/functions.py", line 100, in function multipoint( config, state ) File "/home/star/su2/bin/SU2/eval/functions.py", line 675, in multipoint func[i+1] = aerodynamics(konfig,ztate) File "/home/star/su2/bin/SU2/eval/functions.py", line 313, in aerodynamics funcs[key] = state['FUNCTIONS'][key] KeyError: 'AIRFOIL_AREA' _____________________________________ |
|
Tags |
geometry constraint, keyerror, multipoint optimization |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[ICEM] Volume Meshing Problem; YOUR GEOMETRY HAS A HOLE | mariachi | ANSYS Meshing & Geometry | 5 | May 30, 2018 03:52 |
Problem with building geometry - concentric cylinders | Rhoddwen | OpenFOAM Pre-Processing | 9 | December 17, 2014 11:02 |
problem when imported geometry from 3D CAD to star ccm, | TAREK GANAT | STAR-CCM+ | 1 | May 21, 2013 23:15 |
FSI problem of improper constraint | moloykb | FLUENT | 3 | April 4, 2013 04:47 |
[Gmsh] Problem meshing an imported geometry | Alicia | OpenFOAM Meshing & Mesh Conversion | 0 | March 30, 2010 05:53 |