How to plot Euler's method and ODE45 against eachother?
古いコメントを表示
N0=5 %Euler method
r=10
tmax=10
dt=0.1
[T,N]=expgrowthEULER(N0,tmax,dt,r)
a=[T,N]
tspan=[0,10] %numerical integration
Y0=5
r=10
[T,Y]=ode45(@(T,Y) expgrowthODE(T,Y,r),tspan,Y0)
b=[T,Y]
Error using horzcat
Dimensions of arrays being concatenated are not consistent.
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Ordinary Differential Equations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!