/*----------------------------------------------------------------
%W%  %G%
ctty118b.asc  translated Mon Dec 16 17:00:35 1996 by ntscable 2.0
source file syntax: Eutectic
output file syntax: CABLE
soma: diameter = 11.74 um  length = 22.8518 um  area = 842.828 um2
      16 three-D points; 18 outline points numbered 1-18
      outline diameter = 17.9524 um
3 primary neurites
18 branches totaling 725.066 um in length, 821.882 um2 in area
216 tree points translated to 88 segments (1 requested)
Neurites divided into segments of equal dx between adjacent digitized
branch points.
Segment length constrained to be < 10 um.
No. points    234
No. trees       4
Text  T11118BO, HRP and DAB, 2/2/89                                                                                           

----------------------------------------------------------------*/
					/* create sections */
create    soma,\
          dend1[19],\
          dend2[7],\
          dend3[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


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

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

    for i = 0,6 {
        dend3[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,6 {
        dend2[fscan()] connect dend2[i] (0), fscan()
    }

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

}

geometry()


SOMA COORDINATES AND DIAMETERS:

    16
   -10.5        0     -0.5        0
    -9.5    0.375     -0.5     6.25
    -8.5 -0.16667     -0.5   10.667
      -8        0  -0.5625   12.001
    -6.5   -0.525    -0.75   13.959
      -3 -0.65625    -0.75    16.32
    -2.5 -0.71429    -0.75   16.579
     0.5     -0.5    -0.75   17.007
       2    -0.85    -0.75   15.708
     4.5     -1.6    -0.75   13.209
     5.5       -2    -0.75    12.01
     6.5     -2.2    -0.75   10.412
       8    -2.35     -0.9   8.3024
       9    -1.25       -1      4.5
       9    -0.25       -1      2.5
       9        1       -1        0


NEURITE COORDINATES AND DIAMETERS:

    1 4
      -2      3.5        6      1.5
    -1.5        6      6.5      1.5
      -1      9.5      5.5      1.5
    -1.5     11.5      5.5      1.7

    2 4
    -1.5     11.5      5.5      1.7
    -5.5     14.5        4      1.7
   -10.5     14.5      5.5      1.7
     -13     14.5      5.5      1.7

    2 5
     -13     14.5      5.5      1.7
     -15       17        7        1
   -19.5     19.5        8        1
   -22.5       21       10        1
   -26.5       23     10.5      0.8

    2 4
   -26.5       23     10.5      0.8
     -33       25      9.5      0.5
   -37.5     25.5       11      0.5
     -40       25       11      0.5

    2 6
     -40       25       11      0.5
   -42.5     22.5       11      0.1
     -45       19     10.5      0.1
     -46       18     10.5      0.1
     -49       18      9.5      0.1
     -49       18     12.5      0.1

    1 3
     -49       18     12.5      0.1
   -51.5     21.5     12.5      0.1
     -53       24       13      0.1

    1 3
     -49       18     12.5      0.1
     -49       14       14      0.1
   -51.5     13.5       13      0.1

    2 7
   -51.5     13.5       13      0.1
     -48     10.5     14.5      0.1
   -43.5        9       15      0.1
     -43       11     14.5      0.1
     -41       13       14      0.1
   -41.5     14.5       14      0.1
   -44.5       15       14      0.1

    2 6
   -51.5     13.5       13      0.1
   -53.5     11.5       12      0.1
     -54        8       12      0.1
     -56      6.5     12.5      0.1
   -58.5      5.5     12.5      0.1
   -58.5      5.5     12.5      0.1

    5 12
     -40       25       11      0.5
   -45.5     25.5     11.5      0.1
     -49       26     11.5      0.1
     -52       26       12      0.1
     -56       26     13.5      0.1
   -60.5       26     13.5      0.1
   -66.5     26.5       16      0.1
   -69.5       26     15.5      0.1
   -76.5     25.5     16.5      0.1
   -79.5       24       17      0.1
     -83       23       19      0.1
   -87.5     22.5     17.5      0.1

    3 6
   -26.5       23     10.5      0.8
   -31.5       28     12.5      0.1
     -34       30     13.5      0.1
     -37     34.5     13.5      0.1
     -42       36     10.5      0.1
     -44       37     12.5      0.1

    1 3
     -13     14.5      5.5      1.7
     -17       13      5.5      0.7
     -20       12      6.5      0.7

    3 8
     -20       12      6.5      0.7
     -23     13.5      7.5      0.4
     -24     12.5      7.5      0.4
   -27.5       14        8      0.4
   -32.5     11.5     11.5      0.4
     -36        9       12      0.4
   -39.5      7.5       14      0.2
   -42.5      5.5     14.5      0.2

    1 3
   -42.5      5.5     14.5      0.2
   -42.5      2.5       15      0.1
     -45       -1       18      0.1

    2 2
   -42.5      5.5     14.5      0.2
   -47.5      3.5       26      0.1

    9 25
     -20       12      6.5      0.7
     -22     10.5      6.5      0.3
   -23.5      9.5      6.5      0.3
   -23.5        6      6.5      0.3
     -26      4.5      6.5      0.3
   -28.5       -5      6.5      0.3
     -28     -8.5      6.5      0.3
   -29.5    -13.5      6.5      0.3
   -29.5      -18      6.5      0.3
   -30.5      -20        7      0.3
   -30.5    -22.5      6.5      0.3
     -32    -23.5      6.5      0.3
   -33.5    -25.5        7      0.3
     -36      -28      7.5      0.3
     -36    -30.5        7      0.3
     -39      -32      7.5      0.3
   -40.5      -33        8      0.3
   -40.5      -38        8      0.1
     -42    -42.5      8.5      0.1
     -46      -48      8.5      0.1
   -47.5    -49.5        8      0.1
     -52    -50.5      8.5      0.1
   -54.5      -51      8.5      0.1
     -57    -48.5      8.5      0.1
   -56.5      -49      8.5      0.1

    2 6
    -1.5     11.5      5.5      1.7
     0.5     13.5      5.5      0.4
       0     16.5        6      0.4
       1     19.5        4      0.4
       2     20.5      4.5      0.4
       5     21.5      4.5      0.4

    1 4
       5     21.5      4.5      0.4
     6.5     17.5        5      0.1
       7     12.5        5      0.1
       7       12        5      0.1

    2 6
       5     21.5      4.5      0.4
     4.5       24        5      0.1
       7       24        8      0.1
       7       26      7.5      0.1
       9     28.5      7.5      0.1
    10.5       30      7.5      0.1

    1 3
       0     -9.5        1        3
     0.5      -12        5      1.9
       1    -13.5        5      1.9

    2 6
       1    -13.5        5      1.9
     0.5      -16        5      1.1
     0.5      -20        6      0.9
      -2      -23      6.5      0.7
    -3.5      -26      6.5      0.7
    -5.5      -28      6.5      0.7

    3 9
    -5.5      -28      6.5      0.7
      -4      -29      6.5      0.1
      -3      -30      6.5      0.1
    -0.5    -29.5      6.5      0.1
    -0.5      -32        6      0.1
     0.5      -33        6      0.1
     2.5    -34.5        8      0.1
       5    -32.5        6      0.1
     8.5    -33.5        6      0.1

    2 4
    -5.5      -28      6.5      0.7
      -8      -28        8      0.4
   -12.5      -28     11.5      0.4
   -16.5    -29.5       11      0.4

    3 6
   -16.5    -29.5       11      0.4
   -18.5      -32       11      0.1
   -18.5    -35.5       11      0.1
   -20.5    -39.5     11.5      0.1
     -21    -42.5     11.5      0.1
     -21      -46       21      0.1

    6 14
   -16.5    -29.5       11      0.4
     -19      -28     11.5      0.3
     -21      -26     13.5      0.3
     -23    -26.5     13.5      0.3
   -26.5    -28.5     13.5      0.3
   -31.5    -29.5       16      0.3
     -35      -29     16.5      0.3
     -38    -29.5     16.5      0.3
     -41      -29     18.5      0.3
   -43.5      -29     20.5      0.3
     -46      -31     20.5      0.3
   -46.5      -35     19.5      0.3
     -48      -40     20.5      0.1
     -48      -46       22      0.1

    5 19
       1    -13.5        5      1.9
     4.5    -14.5      2.5      0.8
     6.5    -14.5        3      0.8
       9      -16        3      0.8
      10    -15.5        3      0.8
      13      -16        3      0.8
    14.5      -12      0.5      0.8
      14      -15     -0.5      0.1
    14.5      -17        1      0.1
    14.5    -15.5     -2.5      0.1
      14      -14     -2.5      0.1
      12      -14     -3.5      0.1
      11    -14.5     -3.5      0.1
      10    -13.5     -3.5      0.1
      10    -11.5     -3.5      0.1
     9.5     -8.5       -5      0.1
      10     -6.5       -5      0.1
      11       -5     -4.5      0.1
      11       -3     -4.5      0.1

    3 12
    -0.5    -11.5      5.5      1.2
    -2.5      -12      6.5      0.9
      -4      -13        8      0.9
    -3.5    -10.5       11      0.6
      -3      -10      8.5      0.6
      -5    -12.5        9      0.6
    -7.5      -13       11      0.6
    -9.5    -13.5       10      0.6
      -9      -11       13      0.6
   -10.5    -10.5       13      0.6
   -12.5    -12.5       13      0.6
   -13.5      -12       13      0.6

    10 32
   -13.5      -12       13      0.6
   -13.5    -10.5       14      0.3
     -12      -10       14      0.3
     -13    -12.5       15      0.3
   -13.5      -14     16.5      0.3
     -12      -15       16      0.3
     -11    -15.5       17      0.3
     -11    -18.5       17      0.3
   -11.5      -21       18      0.3
   -12.5      -22       18      0.3
     -14    -23.5       18      0.3
   -13.5      -26     17.5      0.3
   -13.5    -28.5       18      0.3
     -15      -31     18.5      0.3
     -14    -33.5       19      0.3
     -13    -35.5       19      0.3
     -13    -39.5       19      0.3
   -10.5    -41.5       20      0.3
   -11.5    -45.5       20      0.3
    -9.5    -48.5       20      0.3
    -8.5    -52.5       20      0.3
      -9      -56       18      0.3
      -7      -58       18      0.3
      -4    -62.5       17      0.3
    -2.5    -67.5       16      0.3
      -1      -70       16      0.3
     2.5    -72.5       15      0.3
     3.5    -74.5       14      0.3
     5.5      -74       14      0.3
       6    -75.5     15.5      0.3
       8    -78.5     15.5      0.3
     9.5    -81.5     15.5      0.3

    1 4
   -13.5      -12       13      0.6
     -15      -11       13      0.3
     -16    -11.5     13.5      0.3
     -17      -14       16      0.1

    2 5
     -17      -14       16      0.1
   -20.5      -14       16      0.1
     -23      -15       17      0.1
     -26    -18.5       17      0.1
     -30    -21.5     17.5      0.1

    1 5
     -17      -14       16      0.1
   -18.5    -15.5     15.5      0.1
   -20.5    -17.5     15.5      0.1
   -22.5    -19.5       16      0.1
     -23      -20     16.5      0.1

    2 5
     -23      -20     16.5      0.1
     -25      -23     16.5      0.1
     -27      -24       17      0.1
     -30      -25       17      0.1
   -32.5    -25.5       16      0.1

    2 5
     -23      -20     16.5      0.1
     -23      -23       16      0.1
   -24.5      -27       16      0.1
     -26    -34.5     11.5      0.1
     -26    -34.5     11.5      0.1


CONNECTIONS:
        0    1
        1    1
        2    1
        3    1
        4    1
        4    1
        6    1
        6    1
        3    1
        2    1
        1    1
       11    1
       12    1
       12    1
       11    1
        0    1
       16    1
       16    1

        0    1
        1    1
        1    1
        3    1
        3    1
        0    1

        0    1
        0    1
        2    1
        2    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")
}