Please explain how to solve coupled equation in MATLAB? ODE 45 or Runge kutta method? The equation is d/dz(Ep) + (n/c) d/dt (Ep) = Es M where n= 1.45 and C = 3e8
3 次查看(过去 30 天)
显示 更早的评论
%Non Linear ODE equation
clc;
clear all;
%code is incomplete, i was trying to explore but couldnt figure it out properly
c=3e8;
A= 86;
n= 1.45;
g= 1.92e-11;
i= 1;
M= i.* g .* A ;
V= n/ c;
syms z t;
f = @(z,t) ;
0 个评论
回答(1 个)
Torsten
2022-9-2
编辑:Torsten
2022-9-2
The equation you posted is a PDE, not an ODE. So an ODE integrator cannot be used directly for its solution.
You will have to discretize the equation in the z-coordinate and solve the resulting system of ordinary differential equations using ODE15S. Look up "method-of-lines" and "upwind scheme" for more information.
If all variables except E_p and your boundary condition at z=0 are constant, the equation can be solved analytically.
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!