MATLAB Answers

0

How to avoid the repetition of events ?

Asked by parag gupta on 24 Apr 2019
Latest activity Edited by parag gupta on 25 Apr 2019
I am using dde23 solver.
p = sol.ie()
p = 6 4 2 3 1 17 17 21 21 27
I dont want the same event to happen again.What to do to avoid the repetition of same event?
For eg I dont want 17th event should happen 2 time i.e I want it should happen only once.

  0 Comments

Sign in to comment.

Tags

1 Answer

Answer by Akira Agata
on 24 Apr 2019

How about using unique function?
p = [6 4 2 3 1 17 17 21 21 27];
p = unique(p,'stable');
The output becomes like this:
>> p
ans =
6 4 2 3 1 17 21 27

  1 Comment

I was talking about events.I am using dde23 solver so I want same event should not happen again

Sign in to comment.