The following piece of pseudo-code describes the format found in a segment file:

c.....nmax is the number of segments is the number of points on segment n
c.....imax is the number of points

integer ni(nmax)

real x(imax), y(imax), z(imax)
do n = 1, nmax

write(1,*) ni(n)
do i = 1, ni(n)
write(1,*) x(i,n), y(i,n), z(i,n)
end do
end do