showconstr
(不推荐)显示优化约束
说明
示例
输入参数
constr
— 优化约束
OptimizationEquality
对象 | OptimizationInequality
对象 | OptimizationConstraint
对象
优化约束,指定为 OptimizationEquality
对象、OptimizationInequality
对象或 OptimizationConstraint
对象。constr
可以表示单个约束或约束数组。
示例: 当 x
和 y
是标量变量时,constr = x + y <= 1
是单个约束。
示例: 当 x
是二维或多维数组时,constr = sum(x) == 1
是约束数组。
提示
对于大型或复杂的约束,请使用
writeconstr
生成包含约束信息的文本文件。
版本历史记录
在 R2017b 中推出MATLAB 命令
您点击的链接对应于以下 MATLAB 命令:
请在 MATLAB 命令行窗口中直接输入以执行命令。Web 浏览器不支持 MATLAB 命令。
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)