vishnu sankar
vishnu sankar

Reputation: 15

How do I add design variables and constraints from AeroProblem and DVConstraints to OpenMDAO?

I am trying to solve the wing optimization tutorial problem given in the MACH-Aero framework documentation using OpenMDAO instead of pyOptSparse, which is originally used in the documentation. I am stuck in figuring out how to add the design variables of AeroProblem and constraints of DVConstraints to OpenMDAO. As given in the link above in pyOptSparse it is easily achieved through the following code:

# Add variables from the AeroProblem
ap.addVariablesPyOpt(optProb)

# Add DVGeo variables
DVGeo.addVariablesPyOpt(optProb)

# Add constraints
DVCon.addConstraintsPyOpt(optProb)

But I am lost on how to do the same with OpenMDAO. Is there a similar simple one line command that does the job? If not, could you suggest a way to go about incorporating the design variables and constraints from AeroProblem, DVGeometry and DVConstraints into OpenMDAO?

(I looked into the documentation of pyAero_problem and DVCon to see if there are any similar functions available that can be used to plug-in the design variables and constraints into OpenMDAO directly. But at the moment I couldn't find any.)

Upvotes: 0

Views: 103

Answers (1)

Justin Gray
Justin Gray

Reputation: 5710

The Mphys (short for multi-physics) is an existing effort to port the MACH-Aero framework into a more general OpenMDAO context.

While the core math and overall design of OpenMDAO is heavily infulenced by MACH, the details of matching everything up are pretty complex, at least if you want to use MPI (which you almost always do when CFD is involved).

Mphys is a bit more general than MACH, but the ADflow wrappers are well integrated and the example optimizations have all be ported too. Check out the Mphys Docsfor API details.

There is also an example folder, with the equivalent aero-optimization using both a VLM code and ADFlow.

Upvotes: 0

Related Questions