Analysis.setup_optimization
- Analysis.setup_optimization()
Setup the full nonlinear optimization problem with all features.
This method creates the complete optimization problem including: - All selected variables (q, zb, xyb, etc.) - All constraints (funicular, envelope, reactions, etc.) - Objective function and gradients - Jacobian matrices
The problem is stored in self.optimiser.problem and includes all callable functions (fobj, fgrad, fconstr, fjac) ready for the solver.
Notes
This is the third step in the new workflow. It requires that: - Form diagram has been initialized with a starting point - Optimiser settings specify the features, variables, and constraints
For convex problems, this method does nothing (base problem is sufficient).
Examples
>>> analysis.create_base_problem() >>> analysis.compute_starting_point() >>> analysis.setup_optimization() >>> print(f"Variables: {analysis.optimiser.problem.variables}") >>> print(f"Constraints: {analysis.optimiser.problem.constraints}")