Borrar filtros
Borrar filtros

how to define a binary variable in GA tool box

1 visualización (últimos 30 días)
Ayesha Maroof
Ayesha Maroof el 7 de Dic. de 2018
Comentada: buvaneshwari tk el 19 de Jun. de 2022
Hi all
I am working with a facility location problem where the cost of facility is depending on either opening[1] or not opening a facility.[0].So my one variable is binary.when I go to the tool box it asks for upper and lower bounds.but i want to fix the vaiable to either 0 or 1.How can I do that?
Thanx in advance

Respuesta aceptada

Walter Roberson
Walter Roberson el 8 de Dic. de 2018
mark it as an integer variable with lb 0 and ub 1
  5 comentarios
Ayesha Maroof
Ayesha Maroof el 9 de Dic. de 2018
@Walter Roberson thankyou sooooo much.It worked :)
buvaneshwari tk
buvaneshwari tk el 19 de Jun. de 2022
@Ayesha Maroof please share the code..it will helpful for my research work.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre MATLAB Coder en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by