フィルターのクリア

Attempted to access 2 element of data dxdt. The valid index range is 1 to 1 Please note that the simulation will be aborted immediately after you continue from this breakpoint to avoid segmentation violations. debug>>

1 回表示 (過去 30 日間)
I´m working with opc in simulink, i need to solve the equation:
function [X, dxdt]=Biomassprediction(O2)
%Guardar memoria dxdt=zeros(); t=zeros(); X=zeros();
%Parametros Fair=2.0; Vol=250; %Volumen inicial O2ini=20.76; %Concentración inicial de O2
%Condiciones iniciales X(1)=8.3;%Biomasa residual g/L dxdt(1)=((20.97-O2ini)*100000*Fair*0.001429*0.921*60)/((Vol*100)-(X(1)*0.0006913*60));
tsim=inf; dt=0.01; t(1)=0; i=1;
while t(i)<tsim dxdt(i+1)=dxdt(i)+((20.97-O2)*100000*Fair*0.001429*0.921*60)/((Vol*100)-(X(i)*0.0006913*60))*dt; X(i+1)=X(i)+dxdt(i)*dt;
t(i+1)=t(i)+dt; i=i+1; end
but, i´m getting problems with the solution.

回答 (0 件)

カテゴリ

Help Center および File ExchangeUnified Architecture についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by