AIMD algorithm charging value becoming signification

27 次查看(过去 30 天)
I am trying to this AIMD algorithm
for t=[1:1440]
%generate uniform random number, p=rand
if p < pi then
ci(t+1) = b(1)ci(t)
else
ci(t+1) = b(2)ci(t)
endif
end else
ci(t+1) = min(cimax,ci(t)+a detat)
endif
endfor
endwhile
as
p=rand(1440,1);
for t=[1:1440];
Cimax(t)=7;
b1=p(1:1);
b2=p(2:2);
a=p(3:3);
% generate uniform random number,
if p(t) > p(t+1)
ci(t+1) = b1*ci(t);
%elseif ci(t+1) = b2*Ci(t)
else
ci(t+1) = min(Cimax(t),ci(t)+a);
end
% if V(t)<Vevent
% ci(t+1)=0
%end
end
end
but I can't seem to get a value of ci to increase towards 7 in the additive section or to decrease

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 MATLAB 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by