optimization problem using optim prob in matlab

1 Ansicht (letzte 30 Tage)
Omer Hassan
Omer Hassan am 1 Dez. 2019
Beantwortet: Dhananjay Kumar am 4 Dez. 2019
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 Kommentar
Vladimir Sovkov
Vladimir Sovkov am 1 Dez. 2019
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.

Melden Sie sich an, um zu kommentieren.

Antworten (1)

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

Kategorien

Mehr zu Get Started with Optimization Toolbox finden Sie in Help Center und File Exchange

Produkte


Version

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by