Constraint

class pyoptsparse.pyOpt_constraint.Constraint(name, nCon, linear, wrt, jac, lower, upper, scale)[source]

This class holds the representation of a pyOptSparse constraint group

See also

Optimization.addConGroup

for the full documentation

finalize(variables, dvOffset, index)[source]

After the design variables have been finalized and the order is known we can check the constraint for consistency.

Parameters
variablesOrdered Dict

The pyOpt variable list after they have been finalized.

dvOffsetdict

Design variable offsets from pyOpt_optimization

indexint

The starting index of this constraint in natural order

Warning

This function should not need to be called by the user