Simevents: entity generator and insert pattern with non periodic sequences
4 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
I am trying to generate an entity with an specific intergeneration time sequence, and I am not able to make it. The tools helps on generating random and periodic sequences but this is not matchng my requested pattern. This is [0.002 0.016 0.016 0.016...]. The value 0016 remains constant to the end, and the simulation has to be launched for 2 minutes...I supose that there is a way to generate this with Matlab programming, but I not famiiar with this. I have two questions: 1/ Could you please can send me the Matlab Code to generate the sequence? 2/ The root cause...could you please send me some information (links, title for books,...) for get the proper expertise for Matlab coding?
Thanks in advance...
0 comentarios
Respuestas (1)
Adit Kirtani
el 23 de Mzo. de 2023
Editada: Adit Kirtani
el 23 de Mzo. de 2023
Hi José,
For your first question, if you have a sequence of values from which you wish to set an intergeneration time, you can use the "Event Actions Assistant".
You can set your desired sequence and modify the if condition after the sequence definition to ensure the sequence always checks the second index (which in your case is the value of 0.016). By default, it is set to return to the first index.
if idx > numel(SEQ)
idx = 2;
end
As for learning MATLAB, a good resource to learn MATLAB programming would be to complete the MATLAB Onramp. You can view the course here:
I hope this helps,
Adit Kirtani.
0 comentarios
Ver también
Categorías
Más información sobre Discrete-Event Simulation en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!