Variable out_vec must be of size [1 3]. It is currently of size [1 20]. Check where the variable is assigned a value.
5 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
How can I reduce [1 20] size to a [1 3] size, without getting in the problem of needing only the number 1 10 and 20 in a vector row?
0 commentaires
Réponses (1)
KSSV
le 27 Juil 2021
x = 1:20 ;
idx = sort(randperm(length(x),3)) ; % select randomly
x(idx)
2 commentaires
Voir également
Catégories
En savoir plus sur Problem-Based Optimization Setup dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!