Usage example for RK_stab_fun Boundary of stability domain of Kutta's method
0001 % Usage example for RK_stab_fun 0002 % Boundary of stability domain of Kutta's method 0003 0004 b = [1/6; 2/3; 1/6]; 0005 c = [0; 1/2; 1]; 0006 A = [0 0 0; 0007 1/2 0 0; 0008 -1 2 0]; 0009 [ R ] = RK_stab_fun( b,c,A ) 0010 [X,Y] = meshgrid(-3:0.1:0.5,-3:0.1:3); 0011 Z = X+1i*Y; 0012 Rmod = abs(R); 0013 Rmod = matlabFunction(Rmod); 0014 boundary = feval(Rmod,Z); 0015 contour(X,Y,boundary,[1 1]); 0016 grid on; 0017 title(['Kutta',char(39),'s method']);