フィルターのクリア

optimization problem using optim prob in matlab

2 ビュー (過去 30 日間)
Omer Hassan
Omer Hassan 2019 年 12 月 1 日
回答済み: Dhananjay Kumar 2019 年 12 月 4 日
How can I restrict the optim problem at matlab to produce integers or binary values only? I tried to use binary() operator but it didn't accept it ?
  1 件のコメント
Vladimir Sovkov
Vladimir Sovkov 2019 年 12 月 1 日
When you create an optimization variable with the function optimvar of the Optimization Toolbox, you have an option to choose its type as integer and declair its boundaries.

サインインしてコメントする。

回答 (1 件)

Dhananjay Kumar
Dhananjay Kumar 2019 年 12 月 4 日
While using optimvar to create variables which would be used in optimization problem constraints, you can specify 'Type' as 'integer' to achieve your purpose.

カテゴリ

Help Center および File ExchangeProblem-Based Optimization Setup についてさらに検索

タグ

製品


リリース

R2018a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by