改进基于问题的组织和性能
在基于问题的设置中实现专用任务
此类别提供基于问题的解的详细信息,并为更具体的任务提供建议。有关基本任务和介绍性工作流,请参阅基于问题的优化和方程快速入门。
第一节讨论在创建或调节问题时提高性能的方式。
第二节说明当目标或约束包含
for
循环时如何提高性能。第三节提供高效使用基于问题的方法的技巧。
主题
为高效求解对问题进行设置
- Create Efficient Optimization Problems
Obtain a faster or more accurate solution when the problem has integer constraints, and avoid loops when creating a problem. - Objective and Constraints Having a Common Function in Serial or Parallel, Problem-Based
Save time when the objective and nonlinear constraint functions share common computations in the problem-based approach. - Tune Solution for Analysis
Techniques for effective use of the analysis capabilities in the problem-based approach. - Supply Derivatives in Problem-Based Workflow
How to include derivative information in problem-based optimization when automatic derivatives do not apply. - Effect of Automatic Differentiation in Problem-Based Optimization
Automatic differentiation lowers the number of function evaluations for solving a problem.
静态分析
- Static Analysis of Optimization Expressions
Describes static analysis of optimization expressions, a part of thefcn2optimexpr
algorithm. - Create for Loop for Static Analysis
How to create a for loop in separate function for static analysis. - Convert Constraints in for Loops for Static Analysis
How to create a for loop for constraints in separate function for static analysis.
基于问题的设置的技巧
- 有效使用基于问题的优化实时编辑器任务
如何使用和理解基于问题的优化实时编辑器任务。 - Separate Optimization Model from Data
Create reusable, scalable problems by separating the model from the data. - Named Index for Optimization Variables
Create and work with named indices for variables. - Create Initial Point for Optimization with Named Index Variables
Create initial points forsolve
when the problem has named index variables by using thefindindex
function. - Initialize Optimization Expressions
How initialize optimization expressions in functions, and how to recognize that you need to initialize them. - 基于问题的非线性优化中的整数约束
了解基于问题的优化函数prob2struct
和solve
如何处理整数约束。 - Obtain Generated Function Details
Find the values of extra parameters in nonlinear functions created byprob2struct
. - Output Function for Problem-Based Optimization
Use an output function in the problem-based approach to record iteration history and to make a custom plot.