Info
この質問は閉じられています。 編集または回答するには再度開いてください。
Help i get this error: Array indices must be positive integers or logical values. Error in simulering (line 35) plot(v(t),t)
1 回表示 (過去 30 日間)
古いコメントを表示
clear all;
close all;
clc;
load('GaugeDataPart01.mat','INTtimeSERIE')
load('gaugeData.mat','event_summary')
%konstanter
t=INTtimeSERIE(:,1);
I=INTtimeSERIE(:,2);
Fred=5.70492; %Ha
Qud=1*Fred; %l/s/Ha
alpha=0.76;
c=28070;
f=1;
v=@(t) Fred*(f*c*t.^-(0.76).*t-Qud*t);
v=@(t) v(t-1)+f*I*Fred-Qud;
if v(t)>=0
v(t)=v(t-1)+f*I*Fred-Qud;
else
v=0;
end
plot(v(t),t)
datetick('x','mm-yy')
xlabel('dato')
ylabel('volumen [m^3]')
0 件のコメント
回答 (1 件)
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!