How to ensure that values between ones is less than or equal to specific number?
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I have these row vectors:
T = 1:11
C = T(1)
a = T(2:6)
b = T(7:11)
Da = [10 12 8 10 7]; % these vaules are corresponding to a values
Db = [10 9 8 10 7]; % theses vales are corresponding to b vales.
TD = 40
r = [1 2 3 7 8 1 4 8 9 1 5 6 10 11 1]; % r is a random permutation vector/ matrix consists of a and b values( a should always be followed by b in sequenc) after inserting ones which is C.
How to create a loop to ensure that the Da valuse, which are corresponding to a values, are less than or equel to TD(40) between each ones.
Same for Db, which are corresponding to b values, they also should be less or equel to TD(40) between each ones.
0 Kommentare
Antworten (0)
Siehe auch
Kategorien
Mehr zu Creating and Concatenating Matrices finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!