linear_constraints module¶
Build matrices from linear constraints for solvers.
Functions:
|
Return the constraint matrices corresponding to bounds. |
|
Build the constraints matrices associated with passed linear constraints. |
- gemseo.algos.opt.core.linear_constraints.build_bounds_matrices(bounds, upper)[source]¶
Return the constraint matrices corresponding to bounds.
- Parameters
bounds (ndarray) – value of the bounds
upper (bool) – if True the bounds are considered upper bounds
- Returns
left-hand side matrix, right-hand side vector
- Return type
ndarray, ndarray
- gemseo.algos.opt.core.linear_constraints.build_constraints_matrices(constraints, constraint_type)[source]¶
Build the constraints matrices associated with passed linear constraints.
- Parameters
constraints (list(MDOLinearFunction)) – list of linear constraints
constraint_type (str) – type of constraint to consider
- Returns
left-hand side matrix, right-hand side vector
- Return type
ndarray or None, ndarray or None