Auto-IVC design variables #920
-
|
I want to use aspect ratio as a design variable and allow span to change based on aspect ratio, but when I try to set AR as a design variable, span and wing area just stay as their initial values after optimization. Are there any simple ways to change this? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
It seems like you've stumbled across an oversight on how geometry is set up. We copied the equations in FLOPS as they were, but this is a problem because aspect ratio is an output only, and there are no components that do the reverse, and recalculate wing parameters if aspect ratio is changed. Aviary typically handles things like this in the "preprocessing" step before the openmdao model is run, but it looks like a check for aspect ratio vs. area vs. span doesn't exist yet. That won't fix your problem though, since during optimization preprocessing isn't run each iteration. We don't have a solution for this quite yet, it will probably require a minor refactor of Aviary's problem setup. I will make an issue for this though! |
Beta Was this translation helpful? Give feedback.
After some more thought I think you can get this working with base Aviary right now. Aspect ratio is a tricky design variable because there are infinite combinations of span & area that can produce a given aspect ratio. You'll need to fix one of those, then vary the other one to achieve your desired aspect ratio. Let's assume you're fixing span as an example: you could either add a new component as an external subsystem that computes the correct wing area given aspect ratio & span, or you can add wing area as another design variable, and add an equality constraint that span^2/area must equal the provided aspect ratio.