#
global theta gamma epsilon INPUT;
theta= 0.01;
gamma = 0.5;
epsilon = 0.002;
INPUT = 0.4;

function dx = nagumo(x,t)
        global theta gamma epsilon INPUT;
        dx(1) = -x(1)*( x(1)- theta)*( x(1)-1.0 ) - x(2) + INPUT;
        dx(2) = epsilon*( x(1)  - gamma*x(2) );
end

t=linspace(0,2000,2000);  
x=lsode("nagumo",[0.5; 0.2],t); # 0.5; 0.2 は x(1) x(2) の初期値
__gnuplot_set__ key bottom
plot( t,x(:,1), ";u;");
hold on
plot(t,x(:,2),";v;" );
pause

clearplot
plot(x(:,1),x(:,2));   # もうひとつの図をみる．横軸 u 縦軸 v．
pause

# for creating PS figure
#
__gnuplot_set__ term postscript eps color "Helvetica" 20
__gnuplot_set__ output "hoge.eps"
replot
