Coupled ODE-PDE systems, sovler?
1 回表示 (過去 30 日間)
古いコメントを表示
Hi everyone,
I'm trying to code a coupled ODE-PDE model using the matlab ODE solvers, im trying to code 3 ODEs of the form
(1) dA/dt= F(B)+ D*(dA/dx)^2
(2) dB/dt= -F(B)+F(C)
(3) dC/dt= -F(C)
where F(B) in equations (1) & (2) are functions of B and F(C) in equations (2) & (3) are functions of C.
where D in equation (1) is a constant and (dA/dx)^2 is a double derivative in the spatial direction.
I can code a script using ode45 that works if I remove my diffusion term but im struggling to code a script including this term? I initially tried to discretize (dA/dx)^2 but then i couldnt find a way to recall A(j+1) A(j) and A(j-1) in the solver thanks
0 件のコメント
回答 (1 件)
Torsten
2015 年 3 月 18 日
There is no ready-to-use solver for a coupled ODE-PDE - system.
You will have to go the way you already tried: discretize the d^2A/dx^2-term in space.
This will give you 3*n ordinary differential equations where n is the number of grid points.
Use ODE15S to solve.
Best wishes
Torsten.
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!