convolution integral with dde
8 ビュー (過去 30 日間)
古いコメントを表示

Hi guys, I am trying to solve this differential equation using dde. I have a problem with the integral term. In the code shown below, tau is the delay but I cannot just specify a constant value because it is also in the integral which goes from 0 to t. Does anywone know how to deal with it? Thank you!
%%
function sol = exer_3
sol = dde23(@exer3f,tau,[0; 0],[0, 10]);
figure
plot(sol.x,sol.y)
function v = exer3f(t,y,Z)
k = 125; m = 5; F = 1; w = 8;
c=@(t)exp(-t^2);
ylag = Z(:,1);
v = zeros(2,1);
v(1)=y(2);
v(2) = -(k*y(1) - F*cos(w*t) + integral(@(tau)c(tau).*ylag(1), 0, t,'ArrayValued',true))./m;
4 件のコメント
Satheesh oe
2019 年 12 月 20 日
Hi,
can i know why there is (+k) tem in the integral "(c(t-s)+k)".
Regards,
satheesh
回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Numerical Integration and Differential Equations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

