function drawGasket(x,y,L,t)
% DRAWGASKET draws Sierpinski Gasket in the 2-dimensional plane
% at (x,y) with the base length L.
% t is the number of iteration.
% Usage: drawGasket(x,y,L,t)

% Copyright(C) 2002 Tohru Ikeguchi, All Rights Reserved

% Default value setting.
if nargin<1, x=0; end
if nargin<2, y=0; end
if nargin<3, L=1; end
if nargin<4, t=0; end

% Main
% If t = 0, just draw an equilateral triangle.
if t==0,
    drawTriangle(x,y,L);
else
% Else, draw three small equilateral triangles.
    hold on
%    
    drawGasket....    
    drawGasket....    
    drawGasket....    
%
    hold off
end

axis square
axis off
