/*----------------------------------------------------------------
%W%  %G%
ctt3219r.asc  translated Mon Dec 16 17:00:31 1996 by ntscable 2.0
source file syntax: Eutectic
output file syntax: CABLE
soma: diameter = 11.9541 um  length = 21.7894 um  area = 818.302 um2
      16 three-D points; 19 outline points numbered 1-19
      outline diameter = 17.3849 um
4 primary neurites
17 branches totaling 619.808 um in length, 960.986 um2 in area
170 tree points translated to 80 segments (1 requested)
Neurites divided into segments of equal dx between adjacent digitized
branch points.
Segment length constrained to be < 10 um.
No. points    189
No. trees       5
Text  CTT3219R.GR1                                                                                                            

----------------------------------------------------------------*/
					/* create sections */
create    soma,\
          dend1[19],\
          dend2[1],\
          dend3[3],\
          dend4[7]



/*----------------------------------------------------------------*/
proc geometry() { local i, j

						/* soma geometry */
    soma {
        nseg = 1
        pt3dclear()
        for j = 1, fscan() {
            pt3dadd(fscan(),fscan(),fscan(),fscan())
        }
    }

					/* connect primary neurites */
    soma connect dend1[0] (0), 0.5
    soma connect dend2[0] (0), 0.5
    soma connect dend3[0] (0), 0.5
    soma connect dend4[0] (0), 0.5


					/* neurite geometry*/
    for i = 0,18 {
        dend1[i] {
            nseg = fscan()
            pt3dclear()
            for j = 1, fscan() {
                pt3dadd(fscan(),fscan(),fscan(),fscan())
            }
        }
    }

    for i = 0,0 {
        dend2[i] {
            nseg = fscan()
            pt3dclear()
            for j = 1, fscan() {
                pt3dadd(fscan(),fscan(),fscan(),fscan())
            }
        }
    }

    for i = 0,2 {
        dend3[i] {
            nseg = fscan()
            pt3dclear()
            for j = 1, fscan() {
                pt3dadd(fscan(),fscan(),fscan(),fscan())
            }
        }
    }

    for i = 0,6 {
        dend4[i] {
            nseg = fscan()
            pt3dclear()
            for j = 1, fscan() {
                pt3dadd(fscan(),fscan(),fscan(),fscan())
            }
        }
    }



					/* branching topology*/
    for i = 1,18 {
        dend1[fscan()] connect dend1[i] (0), fscan()
    }

    for i = 1,0 {
        dend2[fscan()] connect dend2[i] (0), fscan()
    }

    for i = 1,2 {
        dend3[fscan()] connect dend3[i] (0), fscan()
    }

    for i = 1,6 {
        dend4[fscan()] connect dend4[i] (0), fscan()
    }

}

geometry()


SOMA COORDINATES AND DIAMETERS:

    16
      -9     -2.5     -0.5        0
      -8  -2.8333     -0.5   5.3333
    -7.5  -2.5625     -0.5    7.125
      -6  -2.1875     -0.5   11.625
    -5.5  -1.7778 -0.52778   12.556
    -2.5 0.055556 -0.69444   16.893
    -1.5  0.28571    -0.75   17.579
     0.5  0.85714    -0.25   18.721
       1     1.15    -0.25   18.707
       3     1.55    -0.25   17.107
     3.5    1.625  -0.3125   16.754
       5      0.5     -0.5       13
     6.5        0     -0.5        8
       9 -0.33333     -0.5   5.3333
     9.5  -0.0625     -0.5    4.125
      11      0.5     -0.5        0


NEURITE COORDINATES AND DIAMETERS:

    2 5
      11      0.5        0      2.5
    11.5        1      0.5      2.5
    15.5      1.5        3      2.5
    18.5      1.5      4.5      2.5
      23        0        5      2.2

    1 3
      23        0        5      2.2
      26        1        6      1.6
    28.5        1        6      1.6

    1 2
    28.5        1        6      1.6
    31.5        4      7.5      1.6

    1 3
    31.5        4      7.5      1.6
      32      5.5      7.5      0.4
    32.5      7.5        8      0.4

    6 15
    32.5      7.5        8      0.4
    35.5        8       10      0.1
    37.5       11     12.5      0.1
    41.5     11.5     12.5      0.1
    43.5     16.5     12.5      0.1
      46       17     12.5      0.1
      50       21     10.5      0.1
    53.5       22     10.5      0.1
    58.5     24.5     10.5      0.1
      60       28     10.5      0.1
    61.5     30.5      9.5      0.1
    62.5       34       11      0.1
    64.5       36       11      0.1
      67       38       11      0.1
      68       39     10.5      0.1

    5 13
    32.5      7.5        8      0.4
    31.5        9        9      0.1
    29.5     11.5        9      0.1
    28.5       14      7.5      0.1
      27     15.5      7.5      0.1
    26.5       18        7      0.1
      25     20.5      8.5      0.1
      25     23.5        8      0.1
      22     25.5        8      0.1
      23     28.5        8      0.1
    21.5       33        8      0.1
      20       37        8      0.1
      20       42        8      0.1

    2 5
    31.5        4      7.5      1.6
      33        3     10.5      1.7
      36        3     13.5      1.7
      39        3     14.5        1
    44.5        3       14        1

    4 14
    44.5        3       14        1
      47        5     15.5      0.9
    50.5      7.5     15.5      0.8
    51.5     10.5     14.5      0.8
    54.5     13.5       14      0.6
    54.5       15       14      0.6
      53       16       14      0.6
      54       20       14      0.6
      54     23.5       14      0.6
      53     25.5     13.5      0.6
      54     27.5       13      0.6
    53.5       29     12.5      0.4
      54       31     12.5      0.4
      54       33     10.5      0.2

    6 15
      54       33     10.5      0.2
    51.5     35.5     10.5      0.1
      47     36.5     10.5      0.1
      42       38     10.5      0.1
      36     40.5       11      0.1
      31       42       11      0.1
      28     43.5     10.5      0.1
      25       46     10.5      0.1
    21.5       46     10.5      0.1
    15.5     44.5       12      0.1
    11.5     42.5       12      0.1
     7.5     41.5       12      0.1
       4     43.5       12      0.1
       1     43.5     12.5      0.1
       1     43.5     12.5      0.1

    3 7
      54       33     10.5      0.2
    56.5       35       10      0.1
      58       38       12      0.1
      61     40.5     11.5      0.1
      62     43.5     11.5      0.1
    63.5     45.5     10.5      0.1
    67.5     47.5     10.5      0.1

    1 3
    44.5        3       14        1
      47        1       15      0.1
      49     -0.5       15      0.1

    1 4
    28.5        1        6      1.6
      29       -1        6      0.1
      32     -3.5        6      0.1
      32     -3.5        6      0.1

    1 3
      32     -3.5        6      0.1
      34       -2      5.5      0.1
      35     -0.5      5.5      0.1

    2 4
      32     -3.5        6      0.1
    33.5       -6        6      0.1
      36       -9      4.5      0.1
      36      -12      4.5      0.1

    2 5
      23        0        5      2.2
    23.5       -2        5      1.2
      24     -5.5        5      1.2
      25       -8        6      1.1
      28      -12      6.5      1.1

    2 5
      28      -12      6.5      1.1
    30.5    -11.5      7.5      0.1
      32    -10.5        5      0.1
      37    -10.5        8      0.1
    40.5      -12        9      0.1

    3 8
      28      -12      6.5      1.1
      28      -14      5.5      0.6
      31    -16.5      5.5      0.6
    32.5    -18.5      5.5      0.6
    32.5      -22      5.5      0.6
      34      -23      5.5      0.6
      37      -23      7.5      0.6
    44.5      -23        7      0.6

    2 4
    44.5      -23        7      0.6
      47      -21        8      0.3
    54.5      -18        8      0.3
      59    -17.5        7      0.3

    1 3
    44.5      -23        7      0.6
    46.5    -25.5      6.5      0.1
    50.5      -28      7.5      0.1

    4 14
       3     10.5     -0.5      2.2
       4       13     -0.5      1.5
     2.5     16.5      1.5      0.9
     1.5     19.5      0.5      0.7
       3     21.5       -2      0.6
       3       24     -2.5      0.4
       3       25       -1      0.2
     1.5     26.5       -1      0.1
       2     28.5       -1      0.1
     3.5       29     -1.5      0.1
     5.5       30     -1.5      0.1
       5     32.5       -5      0.1
       4       36       -5      0.1
       4       36       -5      0.1

    5 7
      -8       -2       -1      0.9
     -10     -2.5      5.5      0.6
   -14.5     -3.5      5.5      0.6
     -19       -4      5.5      0.6
   -25.5       -5      5.5      0.6
   -35.5     -5.5      5.5      0.6
     -48       -6      5.5      0.6

    3 9
     -48       -6      5.5      0.6
     -49       -4      5.5      0.5
   -50.5     -1.5      5.5      0.5
   -45.5      1.5      4.5      0.2
     -45      4.5      5.5      0.2
   -43.5        6      5.5      0.2
   -44.5      8.5      5.5      0.2
     -42     11.5        6      0.2
   -41.5       14        6      0.2

    4 8
     -48       -6      5.5      0.6
     -51     -7.5        5      0.2
     -57     -8.5        7      0.2
     -60     -8.5        7      0.2
   -63.5       -6        7      0.2
     -68     -3.5        7      0.1
   -73.5     -0.5        7      0.1
     -77        0      8.5      0.1

    1 2
      -1     -7.5        0      2.1
      -1      -12        5      2.1

    2 4
      -1      -12        5      2.1
     1.5      -15        5      1.2
     2.5      -19        4      1.2
       3      -21        5      1.2

    2 4
       3      -21        5      1.2
       5      -24        5      0.4
     6.5      -28        6      0.1
     6.5    -31.5        6      0.1

    1 3
       3      -21        5      1.2
       1      -24      4.5      0.1
       0      -26      4.5      0.1

    3 6
      -1      -12        5      2.1
      -3      -12      5.5      1.2
    -5.5      -14        7      1.2
    -7.5      -18      6.5      1.2
     -10    -21.5      2.5      0.8
     -15      -24      2.5      0.8

    3 6
     -15      -24      2.5      0.8
   -16.5      -27      2.5      0.4
     -18      -31      4.5      0.2
     -21    -33.5        4      0.1
   -25.5    -34.5        4      0.1
     -29      -35        4      0.1

    5 12
     -15      -24      2.5      0.8
     -17      -23        3      0.4
     -22      -22        2      0.4
     -26      -21        2      0.4
   -30.5    -20.5        2      0.4
   -35.5    -20.5      3.5      0.4
     -38    -22.5      3.5      0.4
   -40.5    -24.5      3.5      0.2
   -44.5    -28.5      4.5      0.2
     -49      -32      4.5      0.2
     -51      -33        8      0.2
   -53.5      -34      5.5      0.2


CONNECTIONS:
        0    1
        1    1
        2    1
        3    1
        3    1
        2    1
        6    1
        7    1
        7    1
        6    1
        1    1
       11    1
       11    1
        0    1
       14    1
       14    1
       16    1
       16    1


        0    1
        0    1

        0    1
        1    1
        1    1
        0    1
        4    1
        4    1


/*----------------------------------------------------------------*/
proc geometry() { 

	/* NULL geometry procedure: keeps the user from
	calling the geometry procedure in isolation. */

    printf("\nYou must re-read the entire geometry\n")
    printf("file to execute geometry().\n\n")
}