lornez1.m

来自「1)先利用文件Lorenz.m求解出Lorenz系统」· M 代码 · 共 35 行

M
35
字号
clear
load un;

n=30001;        % the dimension of the column   
E=0.005;      % the distant small enough
ct=0;           %to record the number of the orbits
m=0;
i=3000;

while (i>=3000)&(i<=4000)
    k=i+200;
    if(i+3000>30001)
        usl=30001;
    else
        usl=i+1000;
    end   
    while (k>=i+200)&(k<=usl)      
        m=((un(k,3)-un(i,3))^2+(un(k,2)-un(i,2))^2+(un(k,1)-un(i,1))^2)^0.5;
        if(m<E)
          ct=ct+1;
          k
          i
          i=k+1;
          break;          
        end;       
        k=k+1;
    end;  
    if(m>=E)
        i=i+1;
    end;
end;

ct      

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?