#@(#)combine	1.2 (rl) 92/08/12
#******************************************************
# kaleido
#
#	Kaleidoscopic construction of uniform polyhedra
#
#	Author:
#		Dr. Zvi Har'El,
#		Deptartment of Mathematics,
#		Technion, Israel Institue of Technology,
#		Haifa 32000, Israel.
#		E-Mail: rl@gauss.technion.ac.il
#******************************************************

# Combine seperate picture files.
#
# They are oredered such that three uniform polyhedra are followed
# by their three duals, to allow printing six polyhedra in two columns.
#
echo ".bp"
echo ".2C"
i=000
while :
do
	i1=`expr $i + 1`
	case $i1 in
	[0-9]) i1=00$i1;;
	[0-9][0-9]) i1=0$i1;;
	esac
	i2=`expr $i1 + 1`
	case $i2 in
	[0-9]) i2=00$i2;;
	[0-9][0-9]) i2=0$i2;;
	esac
	if test ! -s poly.$i -o ! -s dual.$i
	then
		break
	fi
	if test ! -s poly.$i1 -o ! -s dual.$i1
	then
		cat poly.$i
		echo ".sp 6i"
		cat dual.$i
		break
	fi
	if test ! -s poly.$i2 -o ! -s dual.$i2
	then
		cat poly.$i poly.$i1
		echo ".sp 3i"
		cat dual.$i dual.$i1
		break
	fi
	cat poly.$i poly.$i1 poly.$i2 dual.$i dual.$i1 dual.$i2 
	i=`expr $i2 + 1`
	case $i in
	[0-9]) i=00$i;;
	[0-9][0-9]) i=0$i;;
	esac
done
