#!/usr/bin/perl
use Graphics::Libplot ':ALL';

# type of plotting device
$device = 'X';
if (@ARGV) {
    $device = $ARGV[0];	
#    die "Uknown device: $ARGV[0]" unless $ARGV[0] =~ /^ps|X|fig$/;
}

{   # environment for local variables

my $SIZE=100;
my ($i,$f,$s,$sf);
pl_parampl ("BITMAPSIZE", "700x700");
$handle = pl_newpl($device, stdin, stdout, stderr); # open xwindow display
pl_selectpl($handle); 
pl_openpl();
pl_fspace(-$SIZE,-$SIZE, $SIZE, $SIZE); # specify user coord system 
pl_pencolorname ("blue");
pl_fontname("HersheySerif");
$s = 10;
$f = 10;
$sf = 1- .0012;
for($i=1;$i<3000;$i++){
    pl_fscale($sf,$sf);
    pl_fbox(60+$s*sin($i/$f),
	 60+$s*sin($i/$f),
	 75-$s*cos($i/$f),
	 75-$s*cos($i/$f));
    pl_frotate(1);
}

}
pl_closepl();
pl_selectpl(0);
pl_deletepl($handle);

1; #OK

