How can i define algebraic equation in differential function in MATLAB?
1 次查看(过去 30 天)
显示 更早的评论
I want to solve 7 equations. I define all of them in one function in MATLAB dy=function(t,y) for example one of the equation is : dy(i,j)=(Ao*epsilonf.*Ucp*y(i,j))-(kg*Ao.*(y(1,1)-y(2,1))) now i should solve a algebraic equation in this function too.this is my algebraic equation: y(i,10)=((Deff/deltar)*(y(i,10)-y(i-1,10)))+kgAo*(y(2,10)-y(3,10)) how can i do this? i put a small coefficient that eliminate dy 10^-10* dy(i,10)= -y(i,10)+((Deff/deltar)*(y(i,10)-y(i-1,10)))+kgAo*(y(2,10)-y(3,10)) but matlab couldnt solve it. could you help me please?
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Ordinary Differential Equations 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!