📄 odeeul.m
字号:
function [t,x,stats] = odeeul(func,dt,x0,options)
% Fixed step size euler integration
% Used only with discrete-time simulations, it takes one step from
% time 0 to dt and returns only the results at the end of the step.
%THIS IS NOT A GENERAL PURPOSE INTEGRATOR!
% 'dt' must be a scalar
xx0 =x0; % The dummy variable fixes a strange bug!?
xdot = feval(func,0,x0); % Get righthand side
x = xx0 + xdot * dt;
stats = 0; % To match the call to ode23; not used here
t = dt;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -