www.pudn.com > zishiyingjiami.rar > FDC.asv, change:2011-12-15,size:2222b


function F=FDC(x_0,y_0,z_0,f_0) 
%参数值  
a = 50; b = 15; c = 12.4; d = 20; e=0.3 
%初始值  
h = 0.01; % 积分时间步长 
step1 = 10000;        % 前面的迭代点数  
step2 = 5000;         % 后面的迭代点数  
X = []; Y = []; Z = []; F = [];  
for(i = 1:1:(step1 + step2))  
    %e1  
    x_e1 = -a*x_0 + a*y_0+y_0*z_0*f_0 ;  
    y_e1 = b*x_0 + b*y_0 -x_0*z_0*f_0; 
    z_e1 = c*(x_0 - z_0)+x_0*y_0*f_0; 
    f_e1 = e*z_0 - d*f_0+x_0*y_0*z_0 ; 
    %e2  
     
        
    x_h = x_0 + 0.5*h*y_e1;  
    y_h = x_0 + 0.5*h*x_e1;  
    z_h = z_0 + 0.5*h*z_e1;  
    f_h = f_0 + 0.5*h*f_e1; 
            
    x_e2 = -a*x_h + a*y_h+y_h*z_h*f_h;  
    y_e2 = b*x_h + b*y_h -x_h*z_h*f_h; 
    z_e2 = c*(x_h - z_h)+x_h*y_h*f_h; 
    f_e2 = e*z_h - d*f_h+x_h*y_h*z_h ; 
     
    x_h1 = x_0 + 0.5*h*y_e1;  
    y_h1 = x_0 + 0.5*h*x_e1;  
    z_h1 = z_0 + 0.5*h*z_e1;  
    f_h1 = f_0 + 0.5*h*f_e1; 
     
     
     
    x_e2 = a*(y_h - x_h) +y_0*z_0*f_0;  
     
     
    y_e2 = b*(x_h + y_h) -x_0*z_0*f_0;  
    z_e2 = c*(x_h - z_h) +x_0*y_0*f_0; 
    f_e2 = e*z_h - d*f_h -x_0*y_0*z_0; 
    %e3  
    y_h = y_0 + 0.5*h*y_e2;  
    x_h = x_0 + 0.5*h*x_e2; 
    x_e3 = a*(y_h - x_h) +y_0*z_0*f_0;  
      
    z_h = z_0 + 0.5*h*z_e2;  
    f_h = f_0 + 0.5*h*f_e2; 
    y_e3 = b*(x_h + y_h) -x_0*z_0*f_0;  
    z_e3 = c*(x_h - z_h) +x_0*y_0*f_0; 
    f_e3 = e*z_h - d*f_h -x_0*y_0*z_0; 
    %e4  
    y_h = y_0 + 0.5*h*y_e3;  
    x_h = x_0 + 0.5*h*x_e3;  
    x_e4 = a*(y_h - x_h) +y_0*z_0*f_0;  
     
    z_h = z_0 + 0.5*h*z_e3;  
    f_h = f_0 + 0.5*h*f_e3; 
    y_e4 = b*(x_h + y_h) -x_0*z_0*f_0;  
    z_e4 = c*(x_h - z_h) +x_0*y_0*f_0; 
    f_e4 = e*z_h - d*f_h -x_0*y_0*z_0; 
    %迭代 
    x_1 = x_0 + 1/6*h*(x_e1 + 2*x_e2 +2*x_e3 + x_e4);  
    y_1 = y_0 + 1/6*h*(y_e1 + 2*y_e2 +2*y_e3 + y_e4);  
    z_1 = z_0 + 1/6*h*(z_e1 + 2*z_e2 +2*z_e3 + z_e4);  
    f_1 = f_0 + 1/6*h*(f_e1 + 2*f_e2 +2*f_e3 + f_e4);  
    X = [X,x_1];  
    Y = [Y,y_1];  
    Z = [Z,z_1];  
    F = [F,f_1];  
    x_0 = x_1;  
    y_0 = y_1;  
    z_0 = z_1;  
    f_0 = f_1; 
end  
X = X(step1+1:end);  
Y = Y(step1+1:end);  
Z = Z(step1+1:end);  
F = F(step1+1:end); 
figure(2);  
plot3(X,Y,Z); 
figure(3); 
plot3(Y,Z,F); 
figure(4); 
plot3(X,Y,F);