It seems that the airfoil optimization double-wraps the objective values of the OptiSteps into numpy arrays, e.g.,
OptiStep(obj_values=np.array([[182.33]]), step = 1). This causes problems when computing optimality gaps.
Also, it is possible that the design passed to the airfoil has an angle_of_attack that is a numpy array (this is the result of calling design_space.unflatten(design). We should check this in the functions (opti and simulate) and unpack if necessary.
It seems that the airfoil optimization double-wraps the objective values of the OptiSteps into numpy arrays, e.g.,
OptiStep(obj_values=np.array([[182.33]]), step = 1). This causes problems when computing optimality gaps.Also, it is possible that the design passed to the airfoil has an angle_of_attack that is a numpy array (this is the result of calling design_space.unflatten(design). We should check this in the functions (opti and simulate) and unpack if necessary.