An Icosahedron this time.
The code includes putting the
points into data.
Which didn't work out.
restore edges
read tips
dim s(tips)
dim e(tips)
for a=1 to tips
read s(a)
read e(a)
next a
point=10
dim r(point)
dim x(point)
dim y(point)
dim l(point)
dim d(point)
dim s(point)
dim m(point)
rad=pi/180
ang=360/(point/2)
for a=1 to point
l(a)=400
s(a)=3
m(a)=.005
next a
for a=1 to 5
r(a)=a*ang*rad
d(a)=-0.35
next a
for a=6 to 10
r(a)=(a+0.5)*ang*rad
d(a)=0.35
next a
x=320
y=256
open window 640,512
repeat
setdrawbuf vm
vm=1-vm
setdispbuf vm
clear window
text 250,12,"ICOSAHEDRON"
text 250,24," 12 points"
text 250,36,"20 triangles"
text 250,48," 40 lines"
for a=1 to point
x(a)=cos(r(a))/(sin(r(a))+s(a))*l(a)+x
y(a)=d(a)/(sin(r(a))+s(a))*l(a)+y
next a
for a=1 to point
r(a)=r(a)+m(a)
if m(a)>360 m(a)=0
next a
for a=1 to 5
line x,y-120 to x(a),y(a)
next a
for a=6 to 10
line x,y+120 to x(a),y(a)
next a
line x(1),y(1) to x(2),y(2)
line x(2),y(2) to x(3),y(3)
line x(3),y(3) to x(4),y(4)
line x(4),y(4) to x(5),y(5)
line x(5),y(5) to x(1),y(1)
line x(1),y(1) to x(6),y(6)
line x(2),y(2) to x(6),y(6)
line x(2),y(2) to x(7),y(7)
line x(3),y(3) to x(7),y(7)
line x(3),y(3) to x(8),y(8)
line x(4),y(4) to x(8),y(8)
line x(4),y(4) to x(9),y(9)
line x(5),y(5) to x(9),y(9)
line x(5),y(5) to x(10),y(10)
line x(1),y(1) to x(10),y(10)
line x(6),y(6) to x(7),y(7)
line x(7),y(7) to x(8),y(8)
line x(8),y(8) to x(9),y(9)
line x(9),y(9) to x(10),y(10)
line x(10),y(10) to x(6),y(6)
for a=1 to point
'text x(a),y(a),str$(a)
next a
for a=1 to tips
'line x(s(a)),y(s(a)) to x(e(a)),y(e(a))
next a
until (1=0)
label edges
data 20
data 1,2
data 2,3
data 3,4
data 4,5
data 5,1
data 1,6
data 2,6
data 2,7
data 3,7
data 3,8
data 4,8
data 4,9
data 5,9
data 5,10
data 1,10
data 6,7
data 7,8
data 8,9
data 9,10
data 10,6