-
Notifications
You must be signed in to change notification settings - Fork 128
Description
Description
In the openaerostruct/geometry/utils.py module the Taper Function, taper, that is implemented produces wrong results when the mesh has an offset in the y (spanwise) direction.
Steps to reproduce issue
- Use the generate_mesh function available in the same module to produce a rectangular wing with an offset in the y direction:
from openaerostruct.geometry.utils import (
generate_mesh,
taper
)
mesh_dict = {'num_y' : num_y_outboard,
'num_x' : num_x,
'wing_type' : 'rect',
'symmetry' : True,
'span_cos_spacing' : 0.5,
'span' : 2.5,
'root_chord' : 0.399,
'offset' : np.array([0, -0.75, 0])
}
mesh = generate_mesh(mesh_dict)
- Use the taper function to change the geometry of the mesh:
mesh = taper(
mesh=mesh,
taper_ratio=0.55,
symmetry=True
)
Current behavior
mesh[0, -1, 0] returns a value for the x-coordinate of the Leading Edge root different than the original value defined when calling the generate_mesh helper function.
mesh[-1, -1, 0] also returns a different value than previously defined by the generate_function helper function.
Expected behavior
mesh[0, -1, 0] and mesh[0, -1, 0] to return the same value as given by the generate_function helper function.
The x-coordinates of the wing root should be the same after calling the taper function.
Code versions
- Python 3.9.5
- OpenMDAO 3.6.0
- OpenAeroStruct 2.3.0