Event base simulation in matlab
이전 댓글 표시
Hi, I don't know how to do event based simulation in matlab. Just need a start for it, this question is a start part of my bigger task.
i have this,
arrival_departure_frequency =
0.0000 5.9489 0
0.0000 6.6353 0
0.0001 6.9292 0
0.0001 6.9361 0
0.0001 7.2979 0
0.0001 7.7989 0
0.0002 7.9419 0
0.0002 8.8358 0
0.0002 8.8383 0
0.0002 9.0600 0
First column is my event_arrivals and the 2nd column is event_departure. I want to change the value of third column from 0 to 1 when the simulation is in between arrival time and the departure time.
Once the event_departure arrives it again back set to O. Thank you so much.
댓글 수: 27
José-Luis
2014년 6월 11일
I am not sure I follow. What are the values that trigger the change?
Aftab Ahmed Khan
2014년 6월 11일
편집: Aftab Ahmed Khan
2014년 6월 11일
José-Luis
2014년 6월 11일
Will trigger a change depending on what? What are the conditions?
Aftab Ahmed Khan
2014년 6월 11일
José-Luis
2014년 6월 11일
Ok, but what are the conditions?
if first_col = what then third_column what?
if second_col = what then third_column what?
Aftab Ahmed Khan
2014년 6월 11일
Aftab Ahmed Khan
2014년 6월 11일
José-Luis
2014년 6월 11일
And where do you get now_time from?
Aftab Ahmed Khan
2014년 6월 11일
Aftab Ahmed Khan
2014년 6월 11일
José-Luis
2014년 6월 11일
I am sorry, I don't understand what you want.
Aftab Ahmed Khan
2014년 6월 11일
Aftab Ahmed Khan
2014년 6월 11일
José-Luis
2014년 6월 11일
And how do you measure time? You could look into a timer object.
doc timer
Abhishek M
2014년 6월 12일
Are the rows which you provided are of different iterations??
Are these rows related to each other or how is it?? Can you please give some details about it??
0.0000 5.9489 0
0.0000 6.6353 0
Aftab Ahmed Khan
2014년 6월 12일
Abhishek M
2014년 6월 12일
I guess the 1st 2 columns are inputs and the 3rd column is output{0/1}. What are the other rows, are they different probabilities of inputs?? and are these rows related to each other??
Aftab Ahmed Khan
2014년 6월 12일
Abhishek M
2014년 6월 12일
편집: Abhishek M
2014년 6월 12일
will that work aftab??
for example consider these 2 rows
0.0000 6.6353 0
0.0001 6.9292 0
until 0.000 to 6.6353 value will be 1 and what will be the value between 6.6353 to 6.9292. Or else does your input resets after each row and start again with the next row??
Aftab Ahmed Khan
2014년 6월 12일
Abhishek M
2014년 6월 12일
Different output locations??? What does that mean??
Aftab Ahmed Khan
2014년 6월 12일
Aftab Ahmed Khan
2014년 6월 12일
Aftab Ahmed Khan
2014년 6월 12일
Aftab Ahmed Khan
2014년 6월 12일
Abhishek M
2014년 6월 13일
Cool.. I saw your recent query. That question seems to be more clear than this. Anyways good to know you got your solution.
Cheers.
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Number Theory에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!