replace the function "randperm" into code from embedded block SIMULINK
Ältere Kommentare anzeigen
hi, I need to generate a c code from the next code wrote on an embedded editor from embedded block from simulink, but randperm is not supported by code generation, is there some way to do it?
thanks for you support
Size = 100
n = 50
pop = zeros(Size,n);
pop(1,:) = (1:n);
for k = 2:popSize
pop(k,:) = randperm(n);
end
1 Kommentar
Emmanuel Luevano
am 20 Nov. 2012
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu General Applications finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!