What does this error " Undefined operator '*' for input arguments of type 'string' " means?
Show older comments
I have this code (part of a script)
for i=1:N
Size = Event_List(1,4);
Start_trans_time_ONU(i) = CurrentTime + (Distances(i) / Prop_speed) + Size * 8/ (C *(10^9));
End_Trans_time_ONU(i) = Start_trans_time_ONU(i) + (Distances(i)/Prop_speed) + Grant_time;
aux = End_Trans_time_ONU(i) + Guard_time;
Trans_ONU = i+1;
Event_List = [Event_List; DepartureONU aux 0 0 i+1];
end
And I get the error "Undefined operator '*' for input arguments of type 'string'" on 3rd line.
Can anyone help me on solving it?
Many thanks in advance.
4 Comments
Bob Thompson
on 6 Feb 2018
What type of variables are 'C' and 'Size'?
Aziza Zaouga
on 6 Feb 2018
Bob Thompson
on 6 Feb 2018
Ok, so what is Event_List(1,4) then? What type of array is eventlist?
Aziza Zaouga
on 7 Feb 2018
Edited: Stephen23
on 7 Feb 2018
Accepted Answer
More Answers (0)
Categories
Find more on Embedded Coder in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!