/* Dentage Gyrus Granule Cell model associated with the papers: 

J. Tejada, G.M. Arisi, N. Garcia-Cairasco, A.C. Roque, Morphological alterations in newly born dentate gyrus granule cells that emerge after status epilepticus contribute to make them less excitable, PLoS ONE. 7 (2012) e40726. doi:10.1371/journal.pone.0040726.

J. Tejada, N. Garcia-Cairasco, A.C. Roque, Combined role of seizure-induced dendritic morphology alterations and spine loss in newborn granule cells with mossy fiber sprouting on the hyperexcitability of a computer model of the dentate gyrus, PLoS Comput. Biol. 10 (2014) e1003601. doi:10.1371/journal.pcbi.1003601.

julian.tejada@gmail.com - 2014  */

//Defining granule cell

	begintemplate GranuleCell14

// Original name on neuroMorpho.org n14-cont02-sl1.CNG.swc

ndend1=23

  
public  pre_list, connect_pre, subsets, is_art, is_connected
public  vbc2gc, vmc2gc, vhc2gc, vgc2bc, vbc2bc, vmc2bc, vhc2bc, vgc2mc, vbc2mc, vmc2mc, vhc2mc, vgc2hc, vmc2hc
public soma, dend
public all, gcldend, pdend, mdend, ddend

nst=10
	objectvar stim[nst]
double stimdur[nst], stimdel[nst], stimamp[nst]
public stim, stimdur, stimamp, stimdel
create soma, dend[ndend1]
objref syn, pre_list


proc init() {
	pre_list = new List()
	subsets()
	gctemp()
	synapse()
}
objref all, gcldend, pdend, mdend, ddend
proc subsets(){ local i
	objref all, gcldend, pdend, mdend, ddend
	all = new SectionList()
		soma all.append()
		for i=0, 22 dend[i] all.append()
// 		for i=0, 3 gcdend2 [i] all.append()

	gcldend  = new SectionList()
		dend[0] gcldend.append()


	pdend  = new SectionList()
		for i=1, 2 dend[i] pdend.append()
// 		for i=5, 6 dend[i] pdend.append()		  
		


	mdend  = new SectionList()
		for i=3, 8 dend[i] mdend.append()
// 		for i=7, 8 dend[i] mdend.append()		  
		  
		

	ddend  = new SectionList()
		
		for i=9, 22 dend[i] ddend.append()
		  
}
proc gctemp() {

// 	soma {nseg=1 L=16.329 diam=11.165} // changed L & diam
// 		
// 	dend [0] {nseg=1  L=20.05632 diam=2.6}
// 	dend [1] {nseg=1  L=80.78021 diam=1.6478}
// 	dend [2] {nseg=1  L=10.61434 diam=1.1833}
// 	dend [3] {nseg=1  L=25.82767 diam=1.0346}
// 	dend [4] {nseg=1  L=30.89202 diam=0.7664}
// 	dend [5] {nseg=1  L=43.53635 diam=0.9072}
// 	dend [6] {nseg=1  L=37.46003 diam=0.9215}
// 	dend [7] {nseg=1  L=85.47885 diam=0.5756}
// 	dend [8] {nseg=1  L=121.54242 diam=0.6968}
// 	dend [9] {nseg=1  L=78.91646 diam=0.6705}
// 	dend [10] {nseg=1 L=97.50034 diam=0.7203}
// 	dend [11] {nseg=1 L=19.96318 diam=0.8309}
// 	dend [12] {nseg=1 L=125.23049 diam=0.5746}
// 	dend [13] {nseg=1 L=117.23326 diam=0.6059}
// 	dend [14] {nseg=1 L=31.96199 diam=0.6411}
// 	dend [15] {nseg=1 L=45.48879 diam=0.6389}
// 	dend [16] {nseg=1 L=22.50602 diam=0.5591}
// 	dend [17] {nseg=1 L=37.40208 diam=0.6970}
// 	dend [18] {nseg=1 L=20.88699 diam=0.6050}
// 	dend [19] {nseg=1 L=10.10732 diam=0.5985}
	
// 	for i = 1, 20	dend [i] {nseg=1 L=150 diam=3}

// 	gcdend2 [0] {nseg=1 L=50 diam=3}
// 	for i = 1, 3	gcdend2 [i] {nseg=1 L=150 diam=3}	 	

    
	forsec all {
		insert ccanl
	catau_ccanl = 10
	caiinf_ccanl = 0.000005
	Ra=210
	}

	soma {insert ichan2  //ildikos ichan
	gnatbar_ichan2=0.12  //original 0.030 to .055 
	gkfbar_ichan2=0.016  //original 0.015
	gksbar_ichan2=0.006
		insert borgka
	gkabar_borgka=0.012
		insert nca  // HAV-N- Ca channel
	gncabar_nca=0.002  // check to modify- original 0.004
		insert lca 
	glcabar_lca=0.005
		insert cat
	gcatbar_cat=0.000037
		insert gskch
	gskbar_gskch=0.001
		insert cagk
	gkbar_cagk=0.0006
	gl_ichan2 = 0.00004
	cm=1

} 

		forsec gcldend {insert ichan2
	gnatbar_ichan2=0.018  //original 0.015
	gkfbar_ichan2=0.004
	gksbar_ichan2=0.006
		insert nca  // HAV-N- Ca channel
	gncabar_nca=0.003  // check to modify- original 0.004
		insert lca 
	glcabar_lca=0.0075
		insert cat
	gcatbar_cat=0.000075
		insert gskch
	gskbar_gskch=0.0004
		insert cagk
	gkbar_cagk=0.0006
	gl_ichan2 = 0.00004
	cm=1}
		
		forsec pdend {insert ichan2
	gnatbar_ichan2=0.013 
	gkfbar_ichan2=0.004
	gksbar_ichan2=0.006
		insert nca  // HAV-N- Ca channel
	gncabar_nca=0.001  // check to modify- original 0.004
		insert lca 
	glcabar_lca=0.0075
		insert cat
	gcatbar_cat=0.00025
		insert gskch
	gskbar_gskch=0.0002
		insert cagk
	gkbar_cagk=0.001
	gl_ichan2 = 0.000063
	cm=1.0 
        insert pas 
      g_pas = 4e-05
	}
		
	 	forsec mdend {insert ichan2
	gnatbar_ichan2=0.008 
	gkfbar_ichan2=0.001
	gksbar_ichan2=0.006
		insert nca  // HAV-N- Ca channel
	gncabar_nca=0.001  // check to modify- original 0.004
		insert lca 
	glcabar_lca=0.0005
		insert cat
	gcatbar_cat=0.0005
		insert gskch
	gskbar_gskch=0.0
		insert cagk
	gkbar_cagk=0.0024
	gl_ichan2 = 0.000063

	cm=1.0 
        insert pas 
      g_pas = 4e-05}

		forsec ddend {insert ichan2
	gnatbar_ichan2=0.008 
	gkfbar_ichan2=0.001
	gksbar_ichan2=0.008
		insert nca  // HAV-N- Ca channel
	gncabar_nca=0.001  // check to modify- original 0.004
		insert lca 
	glcabar_lca=0.0
		insert cat
	gcatbar_cat=0.001
		insert gskch
	gskbar_gskch=0.0
		insert cagk
	gkbar_cagk=0.0024
	gl_ichan2 = 0.000063
	cm=1.0 
        insert pas 
      g_pas = 4e-05}
		
	
// 	connect dend[0](0), soma(1)
// 	connect gcdend2[0](0), soma(1)
// 	for i=1,3 {
// 	connect dend[i](0), dend[i-1](1)
// 	}
// 	for i=1,3 {
// 	connect gcdend2[i](0), gcdend2[i-1](1)
// 	}

// 	  connect dend(0), soma(1)
	  for i = 0, 1 connect dend[i](0), soma(1)
	  for i = 2, 3 connect dend[i](0), dend(1)
	  for i = 4, 5 connect dend[i](0), dend[1](1)
	  for i = 6, 7 connect dend[i](0), dend[2](1)
	  for i = 8, 9 connect dend[i](0), dend[4](1)
	  for i = 10, 11 connect dend[i](0), dend[5](1)
	  for i = 12, 13 connect dend[i](0), dend[6](1)
	  for i = 14, 15 connect dend[i](0), dend[10](1)
	  for i = 16, 17 connect dend[i](0), dend[13](1)
	  for i = 18, 19 connect dend[i](0), dend[14](1)
	  basic_shape()
// 	  for i = 1, 2 connect dend[i](0), dend(1)
// 	  for i = 3, 4 connect dend[i](0), dend[1](1)
// 	  for i = 5, 6 connect dend[i](0), dend[2](1)
// 	  for i = 7, 8 connect dend[i](0), dend[3](1)
// 	  for i = 9, 10 connect dend[i](0), dend[5](1)
// 	  for i = 11, 12 connect dend[i](0), dend[6](1)
// 	  for i = 13, 14 connect dend[i](0), dend[7](1)
// 	  for i = 15, 16 connect dend[i](0), dend[8](1)
// 	  for i = 17, 18 connect dend[i](0), dend[12](1)
// 	  for i = 19, 20 connect dend[i](0), dend[18](1)
// 	  connect axon(1), soma(0)


	forsec all {enat = 45 ekf = -90 eks = -90  ek=-90  elca=130 etca=130	 esk=-90
		 el_ichan2 =-70

		cao_ccanl=2 }  // make catau slower70e-3 	cao=2 cai=50.e-6 

// current injection
//for i=0,0 {
//stimdel[i]=500
//stimdur[i]=200
//stimamp[i]=0.2

//soma stim[i] = new IClamp(0.5)
//stim.del[i]=stimdel[i]
//stim.dur[i]=stimdur[i]
//stim.amp[i]=stimamp[i]
//}


		}
		
		
  

proc shape3d_1() {
//   axon {pt3dclear()
// 	pt3dadd(0.5085, -38, 0.01, 0.2)
// 	pt3dadd(0.5085, -18, 0.01, 10)
//   }

  soma {pt3dclear()
	pt3dadd(0.5085, -18, 0.01, 10)
	pt3dadd(0.5085, -0.8769, 0, 9.471)
  }
  dend {pt3dclear()
	pt3dadd(0.5085, -0.8769, 0, 9.471)
	pt3dadd(1.95, -5.33, 0.3, 3.15)
	pt3dadd(2.5, -6.8, 0.3, 2.97)
	pt3dadd(3.06, -8.09, 0.82, 2.97)
  }
  dend[1] {pt3dclear()
	pt3dadd(3.06, -8.09, 0.82, 2.97)
	pt3dadd(1.91, -9.15, 2.32, 1.3)
	pt3dadd(1.35, -10.35, 2.32, 1.3)
	pt3dadd(1.35, -11.73, 3.06, 1.11)
	pt3dadd(0.61, -12.83, 3.3, 1.3)
	pt3dadd(-0.23, -14.11, 3.28, 1.3)
	pt3dadd(-0.41, -15.49, 3.55, 1.3)
	pt3dadd(-0.69, -16.6, 3.55, 1.48)
	pt3dadd(-0.97, -17.61, 3.55, 1.76)
	pt3dadd(-2.08, -18.8, 2.8, 1.58)
	pt3dadd(-2.82, -20.27, 3.51, 1.58)
	pt3dadd(-3.94, -22.02, 3.87, 1.58)
	pt3dadd(-4.77, -23.67, 3.82, 1.58)
	pt3dadd(-5.61, -24.78, 3.8, 1.48)
	pt3dadd(-6.44, -26.25, 3.81, 1.39)
	pt3dadd(-6.76, -27.14, 4.08, 1.39)
	pt3dadd(-7.31, -28.43, 4.09, 1.58)
	pt3dadd(-7.68, -29.9, 3.23, 1.95)
	pt3dadd(-8.06, -31.1, 3.23, 2.32)
  }
  dend[2] {pt3dclear()
	pt3dadd(3.06, -8.09, 0.82, 2.97)
	pt3dadd(4.45, -9.65, 1.38, 2.04)
	pt3dadd(5.38, -10.75, 0.95, 2.04)
	pt3dadd(5.57, -11.58, 0.95, 2.04)
  }
  dend[3] {pt3dclear()
	pt3dadd(-8.06, -31.1, 3.23, 2.32)
	pt3dadd(-9.93, -31.81, 3.92, 1.21)
	pt3dadd(-11.23, -32.46, 3.92, 1.02)
	pt3dadd(-12.43, -33.38, 4.23, 0.83)
	pt3dadd(-13.54, -35.03, 4.23, 0.83)
	pt3dadd(-14.84, -35.95, 3.49, 1.02)
	pt3dadd(-15.77, -37.33, 3.49, 1.02)
	pt3dadd(-16.7, -38.43, 3.06, 0.74)
	pt3dadd(-17.44, -39.81, 2.96, 0.74)
	pt3dadd(-18.28, -41.56, 3, 0.74)
	pt3dadd(-18.74, -43.12, 3, 0.74)
	pt3dadd(-19.39, -44.31, 2.54, 0.74)
	pt3dadd(-20.22, -45.97, 2.54, 0.74)
	pt3dadd(-20.41, -47.44, 1.99, 0.93)
	pt3dadd(-20.87, -48.91, 1.99, 0.93)
	pt3dadd(-21.34, -50.38, 1.99, 0.93)
	pt3dadd(-21.31, -51.87, 2.26, 0.74)
	pt3dadd(-21.59, -53.89, 2.31, 0.93)
	pt3dadd(-21.86, -55.36, 2.24, 0.93)
	pt3dadd(-22.33, -57.29, 1.57, 0.93)
	pt3dadd(-22.88, -58.85, 1.57, 0.93)
	pt3dadd(-24, -61.43, 1.86, 0.93)
	pt3dadd(-24.46, -62.99, 2.32, 0.93)
	pt3dadd(-24.65, -64.18, 2.32, 1.02)
	pt3dadd(-24.93, -65.2, 2.25, 1.21)
  }
  dend[4] {pt3dclear()
	pt3dadd(-8.06, -31.1, 3.23, 2.32)
	pt3dadd(-5.92, -32.57, 3.12, 0.93)
	pt3dadd(-4.99, -33.49, 3.12, 0.93)
	pt3dadd(-4.53, -34.96, 3.12, 0.93)
	pt3dadd(-4.16, -36.43, 3.12, 0.93)
	pt3dadd(-3.14, -37.25, 2.53, 0.74)
	pt3dadd(-2.03, -37.25, 2.53, 0.74)
	pt3dadd(-1.1, -38.08, 2.24, 0.93)
	pt3dadd(-1.1, -39.46, 2.4, 0.93)
	pt3dadd(-1.01, -40.65, 2.93, 0.65)
	pt3dadd(-0.82, -41.76, 2.93, 0.65)
	pt3dadd(-1.19, -43.04, 3.06, 0.65)
	pt3dadd(-1.75, -43.69, 3.06, 0.65)
	pt3dadd(-1.28, -44.52, 3.06, 0.65)
	pt3dadd(-0.65, -45.26, 3.17, 0.65)
	pt3dadd(0.18, -46.36, 3.17, 0.56)
	pt3dadd(0.09, -47.65, 3.17, 0.74)
	pt3dadd(-0.09, -49.3, 2.69, 0.83)
	pt3dadd(-0.09, -50.68, 2.69, 0.83)
	pt3dadd(-0.19, -51.79, 3.18, 0.74)
	pt3dadd(-0.84, -52.43, 3.18, 0.74)
	pt3dadd(-0.93, -53.35, 3.18, 0.56)
	pt3dadd(-0.37, -54.36, 3.45, 0.56)
	pt3dadd(-0.47, -55.92, 3.21, 0.74)
	pt3dadd(-0.65, -57.21, 3.21, 0.74)
	pt3dadd(-1.21, -58.4, 3.51, 0.74)
	pt3dadd(-1.95, -58.77, 3.37, 0.56)
	pt3dadd(-2.78, -60.06, 3.9, 0.56)
	pt3dadd(-2.88, -60.79, 3.94, 0.56)
	pt3dadd(-2.6, -61.8, 3.53, 0.56)
	pt3dadd(-2.51, -62.72, 3.53, 0.74)
	pt3dadd(-2.27, -63.74, 3.65, 0.93)
	pt3dadd(-2.09, -64.65, 4.42, 0.93)
	pt3dadd(-1.99, -65.85, 4.42, 0.83)
	pt3dadd(-1.72, -67.14, 4.71, 0.83)
	pt3dadd(-1.53, -68.51, 5.03, 0.74)
	pt3dadd(-2.27, -68.97, 4.68, 0.74)
	pt3dadd(-2.64, -69.71, 5.08, 0.74)
	pt3dadd(-3.01, -70.72, 5.36, 0.83)
	pt3dadd(-3.11, -71.92, 5.62, 0.74)
	pt3dadd(-3.48, -73.2, 5.09, 0.74)
	pt3dadd(-3.94, -74.4, 5.09, 0.74)
	pt3dadd(-4.22, -75.5, 5.09, 0.65)
	pt3dadd(-4.59, -76.42, 5.09, 0.83)
	pt3dadd(-4.78, -77.89, 5.45, 0.83)
	pt3dadd(-4.78, -79.09, 5.45, 0.93)
	pt3dadd(-4.68, -79.91, 5.45, 0.93)
	pt3dadd(-4.59, -81.38, 5.45, 0.93)
	pt3dadd(-4.3, -83.45, 6.47, 0.93)
	pt3dadd(-3.93, -84.92, 6.71, 1.02)
	pt3dadd(-3.65, -86.3, 6.7, 0.93)
	pt3dadd(-3.09, -87.95, 7.1, 0.93)
	pt3dadd(-3.47, -89.05, 7.1, 0.83)
	pt3dadd(-3.74, -89.7, 7, 0.74)
	pt3dadd(-3, -90.71, 7, 0.74)
	pt3dadd(-2.82, -91.72, 6.93, 0.93)
	pt3dadd(-2.63, -92.64, 6.93, 1.21)
	pt3dadd(-2.45, -93.65, 7.87, 1.21)
	pt3dadd(-2.26, -94.2, 7.87, 1.21)
  }
  dend[5] {pt3dclear()
	pt3dadd(5.57, -11.58, 0.95, 2.04)
	pt3dadd(7.64, -11.74, 1.53, 0.74)
	pt3dadd(9.31, -12.66, 2.27, 0.74)
	pt3dadd(10.24, -13.67, 2.91, 0.83)
	pt3dadd(11.35, -15.05, 2.63, 0.93)
	pt3dadd(13.02, -16.15, 2.63, 0.93)
	pt3dadd(14.41, -17.35, 2.69, 0.74)
	pt3dadd(16.45, -18.45, 2.65, 0.74)
	pt3dadd(18.03, -19.37, 2.65, 0.74)
	pt3dadd(19.05, -20.75, 2.65, 0.74)
	pt3dadd(19.44, -22.11, 2.69, 0.74)
	pt3dadd(20.83, -23.77, 2.69, 0.65)
	pt3dadd(22.78, -24.87, 2.69, 0.65)
	pt3dadd(24.73, -25.33, 2.75, 0.65)
	pt3dadd(27.05, -25.42, 2.75, 0.65)
	pt3dadd(29.18, -25.88, 2.51, 0.56)
	pt3dadd(30.76, -26.43, 2.37, 0.56)
	pt3dadd(32.71, -27.81, 2.37, 0.74)
	pt3dadd(32.58, -28.84, 2.37, 0.56)
	pt3dadd(34.35, -29.85, 2.37, 0.56)
	pt3dadd(36.57, -30.68, 3.23, 0.56)
	pt3dadd(38.06, -31.42, 3.29, 0.56)
	pt3dadd(39.73, -31.42, 3.29, 0.74)
	pt3dadd(40.84, -31.6, 3.29, 0.74)
	pt3dadd(42.23, -32.06, 3.29, 0.65)
	pt3dadd(43.25, -32.89, 2.95, 0.65)
	pt3dadd(44.46, -33.9, 2.95, 0.74)
	pt3dadd(45.66, -34.91, 2.95, 0.74)
	pt3dadd(46.51, -36.39, 3.47, 0.56)
	pt3dadd(46.98, -37.4, 3.73, 0.56)
	pt3dadd(48.46, -38.5, 3.16, 0.46)
	pt3dadd(49.94, -38.96, 3.84, 0.46)
	pt3dadd(51.61, -38.68, 3.84, 0.56)
	pt3dadd(53.38, -38.59, 3.58, 0.56)
	pt3dadd(55.32, -38.87, 3.25, 0.56)
	pt3dadd(56.81, -39.79, 3.94, 0.74)
	pt3dadd(57.74, -40.61, 3.95, 0.74)
	pt3dadd(58.76, -41.44, 3.95, 0.74)
	pt3dadd(59.81, -42.53, 4.77, 0.74)
	pt3dadd(60.55, -43.26, 5.31, 0.74)
	pt3dadd(61.48, -44.18, 5.58, 0.56)
	pt3dadd(62.69, -44.73, 5.58, 0.56)
	pt3dadd(64.17, -45.1, 5.44, 0.74)
	pt3dadd(65.75, -45.19, 5.44, 0.56)
	pt3dadd(67.51, -45.47, 5.44, 0.56)
	pt3dadd(67.14, -47.4, 5.8, 0.56)
	pt3dadd(67.05, -48.59, 5.8, 0.56)
	pt3dadd(69, -49.6, 6.15, 0.56)
	pt3dadd(70.29, -50.06, 6.14, 0.56)
	pt3dadd(71.22, -51.53, 6.44, 0.56)
	pt3dadd(72.43, -53.1, 6.22, 0.56)
	pt3dadd(73.43, -54.69, 6.22, 0.56)
	pt3dadd(74.35, -54.87, 6.22, 0.74)
	pt3dadd(76.21, -55.33, 6.96, 0.74)
	pt3dadd(77.51, -55.97, 6.62, 0.56)
	pt3dadd(78.53, -56.8, 6.48, 0.83)
	pt3dadd(79.64, -57.26, 7.56, 0.65)
	pt3dadd(80.94, -58.09, 7.17, 0.65)
	pt3dadd(82.33, -58.64, 6.79, 0.65)
	pt3dadd(84, -59.37, 7.36, 0.65)
	pt3dadd(84.84, -60.57, 7.81, 0.74)
	pt3dadd(85.21, -61.76, 8.05, 0.74)
	pt3dadd(84.09, -61.94, 7.98, 0.74)
  }
  dend[6] {pt3dclear()
	pt3dadd(5.57, -11.58, 0.95, 2.04)
	pt3dadd(4.45, -13.14, 0.84, 1.3)
	pt3dadd(4.36, -14.8, 0.84, 1.11)
	pt3dadd(4.27, -16.54, 1.38, 1.11)
	pt3dadd(4.17, -18.93, 1.38, 1.11)
	pt3dadd(3.99, -21.32, 1.63, 0.93)
	pt3dadd(4.27, -22.34, 1.63, 0.93)
	pt3dadd(3.99, -23.99, 1.63, 0.93)
	pt3dadd(3.74, -25.95, 1.15, 0.93)
	pt3dadd(3.36, -28.53, 0.59, 0.93)
	pt3dadd(2.53, -30.09, 0.09, 0.93)
	pt3dadd(2.34, -30.92, -0.12, 0.93)
	pt3dadd(2.9, -31.93, -0.12, 1.02)
	pt3dadd(3.64, -33.03, -1.22, 0.83)
	pt3dadd(3.74, -35.33, 0.1, 0.74)
	pt3dadd(3.09, -37.44, -0.18, 0.74)
	pt3dadd(2.16, -39.28, -1.13, 0.74)
	pt3dadd(1.14, -42.32, -1.13, 0.74)
	pt3dadd(2.85, -43.55, -1.07, 0.56)
	pt3dadd(4.25, -44.65, -1.07, 0.56)
	pt3dadd(5.45, -45.94, -1.28, 0.56)
	pt3dadd(6.1, -47.14, -1.19, 1.11)
	pt3dadd(6.94, -47.96, -1.19, 0.74)
	pt3dadd(8.23, -49.07, -0.21, 0.74)
  }
}
proc shape3d_2() {
  dend[6] {	pt3dadd(10.09, -49.8, -0.21, 0.74)
	pt3dadd(11.39, -50.35, -0.21, 0.56)
	pt3dadd(12.22, -51.92, -0.57, 0.56)
	pt3dadd(12.32, -53.02, 0.28, 0.56)
	pt3dadd(13.34, -53.02, 0.05, 0.74)
	pt3dadd(14.17, -52.93, 0.05, 0.74)
	pt3dadd(16.05, -53.12, 1.05, 0.56)
	pt3dadd(14.1, -54.23, 1.32, 0.56)
	pt3dadd(13.82, -55.7, 1.86, 0.56)
	pt3dadd(14.56, -56.98, 2.43, 0.56)
	pt3dadd(15.49, -58.27, 2.83, 0.56)
	pt3dadd(16.33, -58.91, 2.65, 0.65)
	pt3dadd(17.35, -59.83, 2.79, 0.56)
	pt3dadd(18.09, -61.12, 2.4, 0.56)
	pt3dadd(18.27, -62.41, 2.91, 0.56)
  }
  dend[7] {pt3dclear()
	pt3dadd(-24.93, -65.2, 2.25, 1.21)
	pt3dadd(-24.46, -66.57, 2.25, 0.74)
	pt3dadd(-24.55, -67.68, 1.66, 0.74)
	pt3dadd(-24.55, -68.78, 1.66, 0.74)
	pt3dadd(-24.3, -70.34, 1.76, 0.74)
	pt3dadd(-24.12, -71.9, 1.45, 0.74)
	pt3dadd(-23.47, -74.2, 1.94, 0.74)
	pt3dadd(-23.47, -76.13, 1.71, 0.74)
	pt3dadd(-23.56, -77.87, 1.71, 0.83)
	pt3dadd(-23.84, -79.43, 1.5, 0.74)
	pt3dadd(-23.65, -81, 1.44, 0.74)
	pt3dadd(-23.19, -82.1, 1.03, 0.93)
	pt3dadd(-23, -83.48, 1.03, 0.93)
	pt3dadd(-23, -84.49, 1.41, 0.83)
	pt3dadd(-23.19, -85.78, 1.36, 0.74)
	pt3dadd(-23.19, -87.25, 0.88, 0.83)
	pt3dadd(-22.94, -88.65, 1.33, 0.83)
	pt3dadd(-22.94, -90.4, 0.83, 1.11)
	pt3dadd(-23.22, -91.68, 0.79, 0.74)
	pt3dadd(-23.22, -93.71, 0.89, 0.83)
	pt3dadd(-23.59, -95.18, 0.68, 0.83)
	pt3dadd(-23.77, -96.64, 0.89, 0.83)
	pt3dadd(-23.86, -98.11, 0.53, 0.74)
	pt3dadd(-24.24, -98.94, 0.53, 0.93)
	pt3dadd(-24.24, -100.4, 0.53, 0.74)
	pt3dadd(-24.33, -102.1, 0.28, 0.74)
	pt3dadd(-24.79, -103.6, 0.36, 0.83)
	pt3dadd(-25.16, -104.5, 0.35, 0.93)
	pt3dadd(-25.53, -105.1, 0.35, 1.21)
  }
  dend[8] {pt3dclear()
	pt3dadd(-24.93, -65.2, 2.25, 1.21)
	pt3dadd(-26.04, -65.93, 1.71, 0.56)
	pt3dadd(-26.97, -66.67, 1.71, 0.56)
	pt3dadd(-28.08, -67.22, 1.91, 0.56)
	pt3dadd(-29.1, -67.68, 2.33, 0.56)
	pt3dadd(-30.4, -67.31, 3.14, 0.56)
  }
  dend[9] {pt3dclear()
	pt3dadd(-2.26, -94.2, 7.87, 1.21)
	pt3dadd(-2.66, -95.96, 6.66, 0.74)
	pt3dadd(-2.29, -97.61, 7.28, 0.83)
	pt3dadd(-2.1, -98.44, 7.28, 0.83)
	pt3dadd(-2.29, -99.36, 7.19, 0.74)
	pt3dadd(-1.73, -100.7, 6.45, 0.83)
	pt3dadd(-1.54, -101.7, 6.45, 0.93)
	pt3dadd(-1.36, -103.1, 6.04, 0.74)
	pt3dadd(-1.08, -104.6, 5.67, 0.74)
	pt3dadd(-0.99, -105.7, 5.42, 0.74)
	pt3dadd(-0.99, -106.8, 5.84, 0.93)
	pt3dadd(-0.8, -107.7, 6.05, 0.74)
	pt3dadd(-0.34, -109.3, 5.24, 0.74)
	pt3dadd(-0.62, -110.5, 5.11, 0.74)
	pt3dadd(-0.43, -111.1, 5.11, 0.93)
	pt3dadd(-0.34, -112.5, 5.86, 0.74)
  }
  dend[10] {pt3dclear()
	pt3dadd(-2.26, -94.2, 7.87, 1.21)
	pt3dadd(-0.13, -94.66, 8.28, 0.65)
	pt3dadd(1.91, -94.84, 8.61, 0.56)
	pt3dadd(3.58, -95.3, 8.61, 0.56)
	pt3dadd(3.58, -96.5, 8.61, 0.56)
	pt3dadd(5.62, -97.79, 8.85, 0.56)
	pt3dadd(7.2, -99.26, 9.58, 0.74)
	pt3dadd(8.22, -100.1, 10.33, 0.74)
	pt3dadd(9.43, -100.5, 10.1, 0.74)
	pt3dadd(11.1, -101.5, 10.67, 0.56)
	pt3dadd(11.47, -104, 10.65, 0.56)
	pt3dadd(12.77, -104.4, 10.8, 0.56)
	pt3dadd(13.97, -105.3, 10.8, 0.56)
	pt3dadd(15.83, -106.5, 11.14, 0.56)
	pt3dadd(15.73, -108.3, 11.17, 0.56)
	pt3dadd(15.83, -110.3, 11.36, 0.65)
	pt3dadd(16.94, -111, 11.36, 0.56)
	pt3dadd(17.4, -112.6, 11.36, 0.56)
	pt3dadd(17.22, -113.8, 11.4, 0.56)
	pt3dadd(18.33, -115.1, 10.52, 0.56)
	pt3dadd(18.79, -116.8, 10.52, 0.74)
	pt3dadd(19.63, -118.4, 10.91, 0.56)
	pt3dadd(20, -119.5, 10.91, 0.56)
	pt3dadd(20.93, -120.5, 10.91, 0.93)
	pt3dadd(21.85, -121.2, 10.91, 0.83)
	pt3dadd(22.5, -122.2, 10.91, 0.65)
	pt3dadd(22.97, -122.9, 10.91, 0.74)
	pt3dadd(23.52, -123.5, 10.91, 0.74)
	pt3dadd(24.17, -124.6, 10.44, 0.65)
	pt3dadd(24.82, -126.5, 10.91, 0.74)
	pt3dadd(25.01, -127.7, 10.91, 0.65)
	pt3dadd(25.75, -129, 10.91, 0.65)
	pt3dadd(25.56, -130.1, 11.17, 0.65)
	pt3dadd(26.12, -131.3, 11.17, 0.65)
	pt3dadd(26.4, -133.2, 10.37, 0.65)
	pt3dadd(26.86, -134, 10.37, 0.65)
	pt3dadd(27.42, -134.9, 10.37, 0.74)
	pt3dadd(27.86, -136.2, 10.58, 0.74)
	pt3dadd(28.42, -137.3, 11.87, 0.56)
	pt3dadd(28.98, -138.8, 11.29, 1.11)
	pt3dadd(29.16, -140.4, 11.7, 0.74)
	pt3dadd(29.25, -141.3, 11.25, 0.93)
	pt3dadd(29.72, -142.4, 11.64, 0.93)
	pt3dadd(31.02, -144, 11.64, 0.93)
	pt3dadd(32.04, -145.3, 12.01, 0.74)
	pt3dadd(32.69, -146.1, 11.74, 0.74)
	pt3dadd(33.24, -147.1, 11.74, 0.83)
	pt3dadd(33.99, -148.4, 11.45, 0.74)
	pt3dadd(34.63, -150.1, 11.78, 0.83)
	pt3dadd(36.12, -151.8, 11.47, 0.74)
	pt3dadd(37.05, -153, 11.47, 0.74)
	pt3dadd(38.12, -154.5, 11.87, 0.74)
	pt3dadd(39.42, -155.3, 11.87, 0.74)
	pt3dadd(40.53, -156.2, 11.87, 0.93)
	pt3dadd(41.55, -156.8, 11.87, 1.02)
	pt3dadd(42.85, -157.6, 11.87, 1.11)
	pt3dadd(44.24, -158, 11.87, 0.93)
	pt3dadd(45.45, -158.2, 11.87, 0.83)
	pt3dadd(46.56, -159.1, 11.87, 0.74)
	pt3dadd(47.3, -160.3, 11.87, 0.93)
	pt3dadd(48.42, -161.3, 11.87, 0.74)
	pt3dadd(48.69, -162.4, 11.87, 0.83)
	pt3dadd(50.09, -163.1, 11.76, 0.74)
	pt3dadd(50.65, -164.1, 11.74, 0.74)
	pt3dadd(51.67, -165.5, 11.63, 0.74)
	pt3dadd(52.04, -166.8, 12.14, 0.74)
	pt3dadd(52.13, -168.1, 12.14, 0.74)
	pt3dadd(52.6, -169.3, 12.42, 0.56)
	pt3dadd(53.43, -170.4, 12.54, 0.74)
	pt3dadd(54.17, -171.2, 12.74, 0.74)
	pt3dadd(55.29, -172.2, 12.97, 0.56)
	pt3dadd(56.59, -172.6, 12.97, 0.56)
	pt3dadd(57.51, -173.3, 12.97, 0.83)
	pt3dadd(58.81, -173.6, 12.97, 0.83)
	pt3dadd(59.74, -174.5, 13.62, 0.93)
	pt3dadd(60.95, -175.3, 12.99, 0.65)
	pt3dadd(61.87, -175.6, 12.99, 0.83)
	pt3dadd(62.62, -176.1, 12.99, 0.83)
  }
  dend[11] {pt3dclear()
	pt3dadd(-25.53, -105.1, 0.35, 1.21)
	pt3dadd(-25.2, -106.7, 0.85, 0.46)
	pt3dadd(-25.48, -108.1, 1.73, 0.46)
	pt3dadd(-25.76, -109.5, 0.82, 0.74)
	pt3dadd(-26.22, -111.1, 0.82, 1.02)
	pt3dadd(-26.13, -112.6, 1.11, 0.83)
	pt3dadd(-26.22, -113.5, 0.82, 0.83)
	pt3dadd(-26.87, -114.8, 0.91, 0.83)
	pt3dadd(-27.15, -115.6, 0.22, 0.83)
  }
  dend[12] {pt3dclear()
	pt3dadd(-25.53, -105.1, 0.35, 1.21)
	pt3dadd(-28.08, -106.1, 1.3, 0.65)
	pt3dadd(-30.31, -107, 1.2, 0.65)
	pt3dadd(-31.89, -107.3, 1.07, 0.65)
	pt3dadd(-32.91, -108.5, 1.21, 0.56)
	pt3dadd(-34.3, -109, 1.21, 0.56)
	pt3dadd(-36.25, -109.7, 0.89, 0.46)
	pt3dadd(-38.1, -110.3, 1.61, 0.46)
	pt3dadd(-39.22, -111.2, 1.61, 0.46)
	pt3dadd(-40.51, -111.9, 1.61, 0.46)
	pt3dadd(-42, -112.7, 1.75, 0.56)
	pt3dadd(-43.57, -113.5, 2.06, 0.56)
	pt3dadd(-44.87, -114.3, 2.06, 0.56)
	pt3dadd(-47.1, -115.3, 2.48, 0.56)
	pt3dadd(-48.68, -116.1, 2.48, 0.56)
	pt3dadd(-50.07, -117, 2.13, 0.56)
	pt3dadd(-51.65, -118.4, 2.75, 0.56)
	pt3dadd(-53.26, -118.7, 2.31, 0.74)
	pt3dadd(-54.93, -119.8, 3.1, 0.46)
	pt3dadd(-56.7, -121, 3.1, 0.46)
	pt3dadd(-58.55, -122.4, 3.57, 0.74)
	pt3dadd(-59.57, -123.1, 3.57, 0.56)
	pt3dadd(-60.78, -124.2, 2.97, 0.46)
	pt3dadd(-61.24, -125, 2.97, 0.56)
	pt3dadd(-62.35, -126, 3.31, 0.37)
	pt3dadd(-63.65, -126.5, 3.31, 0.37)
	pt3dadd(-65.32, -127.1, 2.91, 0.37)
	pt3dadd(-66.81, -128.1, 2.66, 0.37)
	pt3dadd(-69.4, -129.3, 3.22, 0.37)
	pt3dadd(-71.91, -130.4, 3.31, 0.37)
	pt3dadd(-73.76, -131.8, 3.15, 0.37)
	pt3dadd(-76.08, -133.1, 3.08, 0.37)
	pt3dadd(-77.75, -134.4, 3.08, 0.37)
	pt3dadd(-78.05, -135.9, 4.23, 0.37)
	pt3dadd(-78.98, -136.5, 3.52, 0.37)
	pt3dadd(-79.63, -136.9, 3.8, 0.37)
  }
  dend[13] {pt3dclear()
	pt3dadd(-0.34, -112.5, 5.86, 0.74)
	pt3dadd(0.39, -113.4, 5.85, 0.56)
	pt3dadd(0.21, -114.7, 5.88, 0.56)
	pt3dadd(0.48, -116.2, 5.66, 0.56)
	pt3dadd(0.39, -117.5, 5.27, 0.56)
	pt3dadd(0.58, -118.6, 5.17, 0.56)
	pt3dadd(0.86, -121.3, 4.94, 0.56)
	pt3dadd(0.76, -123.1, 5.32, 0.56)
	pt3dadd(0.95, -125.3, 4.23, 0.56)
	pt3dadd(1.13, -126.6, 3.85, 0.56)
	pt3dadd(1.41, -128.1, 3.41, 0.56)
  }
}
proc shape3d_3() {
  dend[13] {	pt3dadd(1.6, -129.6, 3.16, 0.74)
	pt3dadd(1.78, -130.6, 3.01, 0.74)
	pt3dadd(1.81, -132, 3.91, 0.56)
	pt3dadd(2.08, -133.9, 3.61, 0.74)
	pt3dadd(2.08, -135.4, 3.02, 0.56)
	pt3dadd(1.81, -136.3, 3.02, 0.93)
	pt3dadd(2.36, -137.3, 2.91, 0.56)
	pt3dadd(2.73, -138.4, 2.82, 0.56)
	pt3dadd(3.85, -139.5, 2.55, 0.56)
	pt3dadd(4.4, -140.4, 3.05, 0.56)
	pt3dadd(4.77, -141.7, 3.02, 0.74)
	pt3dadd(4.87, -143.1, 2.23, 0.56)
	pt3dadd(5.89, -144.5, 2.52, 0.56)
	pt3dadd(6.54, -145.5, 2.52, 0.56)
	pt3dadd(7.47, -146.3, 2.11, 0.74)
	pt3dadd(8.21, -147.3, 2.11, 0.56)
	pt3dadd(8.76, -148.7, 1.91, 0.56)
	pt3dadd(8.96, -150.2, 3.73, 0.56)
	pt3dadd(9.43, -151.1, 3.13, 0.74)
	pt3dadd(9.89, -151.9, 3.13, 0.93)
	pt3dadd(10.26, -153.1, 2.89, 0.74)
	pt3dadd(11.19, -154.4, 2.38, 0.65)
	pt3dadd(11.37, -156.2, 2.03, 0.56)
	pt3dadd(11.84, -157.2, 2.03, 0.56)
	pt3dadd(12.58, -158.6, 2.66, 0.56)
	pt3dadd(13.51, -159.8, 2.84, 0.56)
	pt3dadd(14.71, -161, 2.3, 0.56)
	pt3dadd(15.92, -162.3, 1.72, 0.56)
	pt3dadd(17.03, -162.9, 1.93, 0.56)
  }
  dend[14] {pt3dclear()
	pt3dadd(-0.34, -112.5, 5.86, 0.74)
	pt3dadd(-0.97, -114.1, 6.04, 0.56)
	pt3dadd(-0.97, -115.4, 6.93, 0.74)
	pt3dadd(-0.69, -116.2, 6.93, 0.74)
	pt3dadd(-0.6, -117.5, 7.47, 0.56)
	pt3dadd(-0.69, -119.1, 7.76, 0.56)
	pt3dadd(-0.51, -120.7, 7.52, 0.65)
	pt3dadd(-0.23, -121.8, 7.52, 0.65)
	pt3dadd(-0.04, -122.6, 7.52, 0.56)
	pt3dadd(-0.69, -123.9, 7.52, 0.74)
	pt3dadd(-1.9, -125.2, 8.39, 0.74)
	pt3dadd(-2.08, -126.7, 8.39, 0.74)
	pt3dadd(-2.08, -128, 8.66, 0.74)
	pt3dadd(-2.73, -129.4, 8.66, 0.74)
	pt3dadd(-2.92, -129.9, 8.66, 0.83)
	pt3dadd(-3.11, -131.1, 8.67, 0.65)
	pt3dadd(-3.64, -132.2, 8.8, 0.65)
	pt3dadd(-4.2, -134, 8.18, 0.56)
	pt3dadd(-4.66, -134.9, 8.49, 0.56)
	pt3dadd(-4.85, -135.5, 8.96, 0.83)
	pt3dadd(-5.22, -137, 8.43, 0.83)
	pt3dadd(-4.94, -138.4, 8.43, 0.65)
	pt3dadd(-4.94, -139.6, 8.79, 1.11)
	pt3dadd(-5.22, -141.1, 9.16, 0.65)
	pt3dadd(-5.41, -142.5, 9.32, 0.65)
	pt3dadd(-5.5, -144.2, 9.87, 0.65)
	pt3dadd(-5.78, -145.7, 9.91, 0.56)
	pt3dadd(-5.87, -146.7, 10.09, 0.56)
	pt3dadd(-5.31, -147.4, 10.09, 1.02)
	pt3dadd(-5.31, -148, 10.09, 1.02)
	pt3dadd(-5.22, -148.9, 10.09, 0.74)
	pt3dadd(-4.72, -150.3, 10.09, 0.65)
	pt3dadd(-4.81, -151.6, 9.98, 0.65)
	pt3dadd(-5.27, -152.2, 9.77, 0.65)
	pt3dadd(-5.64, -153.1, 10.31, 0.65)
	pt3dadd(-5.92, -154.5, 10.11, 0.56)
	pt3dadd(-5.92, -155.9, 9.95, 0.56)
	pt3dadd(-6.48, -156.7, 10.25, 0.83)
	pt3dadd(-6.94, -157.9, 10.38, 0.56)
	pt3dadd(-7.96, -158.8, 10.38, 0.56)
	pt3dadd(-8.05, -160.1, 10.94, 0.74)
	pt3dadd(-7.78, -161.4, 11.45, 0.46)
	pt3dadd(-8.05, -161.8, 11.4, 0.46)
	pt3dadd(-9.26, -161.8, 11.4, 0.46)
	pt3dadd(-9.54, -163.2, 11.14, 0.46)
	pt3dadd(-9.63, -163.8, 11.84, 0.56)
	pt3dadd(-10.47, -164.5, 12.09, 0.56)
	pt3dadd(-11.02, -165.7, 12.49, 0.56)
	pt3dadd(-11.49, -166.1, 11.87, 0.74)
	pt3dadd(-11.95, -166.8, 11.87, 0.74)
	pt3dadd(-12.54, -167.7, 11.75, 0.65)
	pt3dadd(-13.65, -169.8, 10.8, 0.56)
	pt3dadd(-14.67, -172, 10.66, 0.56)
	pt3dadd(-14.48, -173.6, 11.3, 0.56)
	pt3dadd(-14.58, -174.3, 11.65, 0.56)
  }
  dend[15] {pt3dclear()
	pt3dadd(62.62, -176.1, 12.99, 0.83)
	pt3dadd(63.89, -176.3, 13.7, 0.46)
	pt3dadd(65.65, -176.7, 13.97, 0.46)
	pt3dadd(66.49, -177.9, 13.97, 0.46)
	pt3dadd(67.6, -178.4, 13.98, 0.65)
	pt3dadd(68.62, -179, 13.98, 0.83)
	pt3dadd(69.46, -179.9, 13.15, 0.56)
	pt3dadd(70.2, -180.4, 13.15, 0.65)
	pt3dadd(71.5, -180.9, 13.91, 0.46)
	pt3dadd(71.78, -182.3, 13.91, 0.56)
	pt3dadd(72.05, -183.4, 13.51, 0.56)
	pt3dadd(72.42, -184.4, 13.51, 0.56)
	pt3dadd(72.7, -185.3, 13.51, 0.46)
	pt3dadd(72.7, -186.5, 13.84, 0.46)
	pt3dadd(73.26, -187.8, 13.57, 0.46)
	pt3dadd(73.72, -188.7, 13.41, 1.02)
  }
  dend[16] {pt3dclear()
	pt3dadd(62.62, -176.1, 12.99, 0.83)
	pt3dadd(63.61, -177.3, 12.48, 0.56)
	pt3dadd(64.35, -178.9, 12.15, 0.56)
	pt3dadd(65.84, -179.9, 10.86, 0.56)
	pt3dadd(65.84, -181.6, 10.61, 0.56)
	pt3dadd(66.77, -182.8, 10.33, 0.56)
	pt3dadd(67.42, -183.4, 10.33, 0.56)
	pt3dadd(67.6, -184.4, 10.33, 0.93)
	pt3dadd(68.34, -185.2, 11.15, 0.65)
	pt3dadd(69.18, -186.3, 10.41, 0.56)
	pt3dadd(69.83, -187.6, 9.77, 0.56)
	pt3dadd(70.38, -188.8, 9.44, 0.46)
	pt3dadd(71.4, -189.5, 9.33, 0.46)
	pt3dadd(71.78, -191, 9.03, 0.46)
  }
  dend[17] {pt3dclear()
	pt3dadd(-27.15, -115.6, 0.22, 0.83)
	pt3dadd(-28.4, -117, 0.84, 0.46)
	pt3dadd(-30.53, -117.7, 0.84, 0.46)
	pt3dadd(-32.2, -118.8, 0.62, 0.46)
	pt3dadd(-35.26, -119.7, 0.43, 0.46)
	pt3dadd(-37.49, -120.9, 0.07, 0.37)
	pt3dadd(-39.16, -121.9, 0.25, 0.37)
	pt3dadd(-40.09, -122.7, 0.18, 0.56)
	pt3dadd(-41.76, -123.8, 0.66, 0.56)
	pt3dadd(-42.41, -124.4, 0.86, 0.56)
	pt3dadd(-42.96, -125.2, 0.65, 0.56)
	pt3dadd(-44.45, -126, 0.56, 0.46)
	pt3dadd(-45.75, -127.1, 0.48, 0.65)
	pt3dadd(-47.42, -128.2, 0.24, 0.65)
	pt3dadd(-48.53, -129.3, 0.58, 0.83)
	pt3dadd(-50.2, -130.9, 0.48, 0.65)
	pt3dadd(-51.4, -131.9, 0.58, 0.65)
	pt3dadd(-52.89, -132.9, 0.58, 0.65)
	pt3dadd(-53.17, -134, 0.2, 0.65)
	pt3dadd(-54.01, -134.9, 0.2, 0.83)
  }
  dend[18] {pt3dclear()
	pt3dadd(-27.15, -115.6, 0.22, 0.83)
	pt3dadd(-27.06, -117.5, 0.17, 0.46)
	pt3dadd(-27.24, -119.3, 0.5, 0.46)
	pt3dadd(-26.87, -120.6, 0.67, 0.46)
	pt3dadd(-26.87, -122.6, 0.59, 0.37)
	pt3dadd(-25.94, -124.6, 0.53, 0.37)
	pt3dadd(-24.97, -126.8, 0.53, 0.37)
	pt3dadd(-24.22, -128.5, 0.53, 0.46)
	pt3dadd(-23.48, -129.5, 1.08, 0.37)
	pt3dadd(-22.46, -130.8, 1.08, 0.37)
	pt3dadd(-21.72, -132.4, 0.32, 0.37)
	pt3dadd(-21.26, -133.6, 0.02, 0.37)
	pt3dadd(-21.07, -134.9, -0.25, 0.37)
	pt3dadd(-20.61, -136, 0.21, 1.11)
	pt3dadd(-19.96, -137.7, 0.68, 0.65)
	pt3dadd(-19.4, -138.9, 0.69, 0.65)
	pt3dadd(-19.4, -140.3, 1.19, 0.56)
	pt3dadd(-19.03, -141.4, 1.27, 0.56)
	pt3dadd(-19.21, -142.8, 1.48, 0.56)
	pt3dadd(-19.13, -143.7, 1.54, 0.56)
	pt3dadd(-18.94, -145.4, 1.54, 0.56)
	pt3dadd(-18.29, -146.4, 1.54, 0.56)
	pt3dadd(-18.57, -147.5, 1.54, 0.74)
	pt3dadd(-18.57, -148.7, 1.54, 0.74)
	pt3dadd(-18.48, -149.8, 2.05, 0.74)
	pt3dadd(-18.2, -150.8, 2.05, 0.74)
	pt3dadd(-17.37, -151.8, 2.05, 0.56)
	pt3dadd(-17.18, -153.1, 2.05, 0.56)
	pt3dadd(-17.09, -154.2, 1.77, 0.56)
	pt3dadd(-16.53, -155.1, 1.35, 1.02)
	pt3dadd(-16.16, -156, 1.35, 0.93)
	pt3dadd(-15.79, -157.5, 1.81, 0.56)
	pt3dadd(-15.23, -158.3, 1.87, 0.56)
	pt3dadd(-15.14, -159.8, 1.84, 0.56)
	pt3dadd(-15.05, -161.1, 1.84, 0.56)
	pt3dadd(-14.56, -161.9, 2.5, 0.56)
	pt3dadd(-15.02, -162.6, 2.5, 0.56)
	pt3dadd(-14.65, -164, 3.27, 0.56)
	pt3dadd(-14.56, -165.6, 3.56, 0.56)
	pt3dadd(-14.65, -166.4, 3.56, 0.74)
	pt3dadd(-14.19, -167.6, 3.56, 0.46)
	pt3dadd(-14.09, -168.7, 3.25, 0.46)
	pt3dadd(-14.28, -169.4, 3.25, 0.74)
	pt3dadd(-14.47, -170.3, 3.25, 0.74)
  }
  dend[19] {pt3dclear()
	pt3dadd(73.72, -188.7, 13.41, 1.02)
	pt3dadd(73.55, -190.3, 14.16, 0.56)
	pt3dadd(73.18, -191.7, 14.16, 0.56)
	pt3dadd(72.99, -193.8, 14.16, 0.56)
	pt3dadd(72.62, -195.3, 13.71, 0.56)
	pt3dadd(72.9, -197, 14.61, 0.74)
	pt3dadd(72.9, -198.6, 14.61, 0.56)
	pt3dadd(73.09, -200.3, 13.88, 0.56)
	pt3dadd(72.9, -202.5, 13.49, 0.56)
	pt3dadd(72.53, -204.6, 13.49, 0.56)
  }
  dend[20] {pt3dclear()
	pt3dadd(73.72, -188.7, 13.41, 1.02)
	pt3dadd(74.74, -190.2, 14.18, 0.37)
	pt3dadd(76.14, -191.6, 14.64, 0.37)
	pt3dadd(76.01, -193.4, 14.29, 0.37)
	pt3dadd(75.83, -195, 14.29, 0.37)
	pt3dadd(76.01, -196.7, 14.21, 0.37)
	pt3dadd(76.85, -198.9, 14.19, 0.37)
	pt3dadd(77.68, -201.1, 14.19, 0.56)
	pt3dadd(78.61, -202.5, 13.25, 0.74)
	pt3dadd(79.26, -204.4, 13.94, 0.56)
	pt3dadd(80.1, -205.8, 13.28, 0.56)
	pt3dadd(80.47, -207.6, 13.74, 0.56)
  }
}
proc shape3d_4() {
  dend[20] {	pt3dadd(80.47, -208.8, 13.74, 0.56)
	pt3dadd(80.37, -210.3, 13.76, 0.56)
  }
  dend[21] {pt3dclear()
	pt3dadd(-54.01, -134.9, 0.2, 0.83)
	pt3dadd(-54.1, -136.2, 0.12, 0.56)
	pt3dadd(-55.03, -137.1, 0.12, 0.56)
	pt3dadd(-55.86, -138, 0.12, 0.65)
	pt3dadd(-56.23, -138.9, 0.12, 0.56)
	pt3dadd(-56.6, -139.7, -0.06, 0.83)
	pt3dadd(-56.88, -140.8, 0.27, 0.56)
	pt3dadd(-57.62, -141.7, -0.02, 0.93)
	pt3dadd(-58.27, -141.9, -0.02, 0.93)
	pt3dadd(-59.2, -142.7, -0.56, 0.46)
	pt3dadd(-60.69, -143.8, -0.56, 0.56)
	pt3dadd(-61.8, -144.8, -0.86, 0.46)
	pt3dadd(-62.36, -146.1, -0.39, 0.46)
	pt3dadd(-64.67, -147.8, -0.36, 0.46)
	pt3dadd(-65.88, -149.3, -0.86, 0.46)
	pt3dadd(-66.44, -150.7, -0.86, 0.46)
	pt3dadd(-66.57, -151.6, -0.39, 0.46)
	pt3dadd(-68.15, -153.2, -0.79, 0.46)
	pt3dadd(-69.54, -154.3, -0.61, 0.46)
	pt3dadd(-69.91, -154.7, -0.06, 0.46)
  }
  dend[22] {pt3dclear()
	pt3dadd(-54.01, -134.9, 0.2, 0.83)
	pt3dadd(-55.4, -135.5, 0.65, 0.46)
	pt3dadd(-56.7, -136, 0.65, 0.46)
	pt3dadd(-57.07, -136.6, 0.11, 0.65)
	pt3dadd(-58, -137.1, 0.93, 0.56)
	pt3dadd(-59.29, -137.8, 0.93, 0.56)
	pt3dadd(-60.78, -138.2, 1.14, 0.56)
	pt3dadd(-62.82, -138.6, 0.46, 0.56)
	pt3dadd(-63.93, -139, 0.65, 0.56)
  }
}
proc basic_shape() {
  shape3d_1()
  shape3d_2()
  shape3d_3()
  shape3d_4()
}

		
	proc connect_pre() {  // $o1 target point process, $o2 returned NetCon
	soma $o2 = new NetCon (&v(1), $o1)
	//alternative statement		$o1.soma pre_list.append(new NetCon(soma.v(1),syn,0,Delsyn,0))
	}

	objref syn
	objref DistalSynapses 
	objref DistalSynapsePositions 
	objref ProximalSynapses 
	objref ProximalSynapsePositions 
	proc synapse() { 
 
 // //***** PP syn   
 
DistalSynapses = new Vector(0,0) 
DistalSynapses .append(10 , 15 , 16 , 19 , 20) 
DistalSynapsePositions = new Vector(0,0) 
DistalSynapsePositions .append(0.98252   ,      0.5  ,       0.5  ,       0.5,         0.5) 
for i= 0 , 4 { 
dend[DistalSynapses .x[i]] syn = new Exp2Syn(DistalSynapsePositions .x[i]) // PP syn based on Greg and Staley 
syn.tau1 = 1.5	syn.tau2 = 5.5	syn.e = 0  
pre_list.append(syn) // # 0  
} 
 
 // //***** MC syn   
 
ProximalSynapses = new Vector(0,0) 
ProximalSynapses .append(0 , 1 , 2 , 3 , 4 , 5 , 6) 
ProximalSynapsePositions = new Vector(0,0) 
ProximalSynapsePositions .append(0.5     ,    0.5     ,    0.5  ,    0.2023,      0.1133  ,   0.18744   ,  0.29544) 
for i= 0 , 6 { 
dend[ProximalSynapses .x[i]] syn = new Exp2Syn(ProximalSynapsePositions .x[i]) // // MC syn *** Estimated 
syn.tau1 = 1.5	syn.tau2 = 5.5	syn.e = 0 
pre_list.append(syn) // #  
} 
 
 // //***** HIPP   
 
for i= 0 , 4 { 
dend[DistalSynapses .x[i]] syn = new Exp2Syn(DistalSynapsePositions .x[i]) // HIPP  
syn.tau1 = 0.5	syn.tau2 = 6	syn.e = -70 
pre_list.append(syn) // # 4 
} 
 
 // //***** BC syn   
 
soma syn = new Exp2Syn(0.5) // BC  syn syn based on Bartos 
syn.tau1 = 0.26	syn.tau2 = 5.5	syn.e = -70 
pre_list.append(syn) // # 5 
 
 // //***** Sprout   
 
for i= 0 , 6 { 
dend[ProximalSynapses .x[i]] syn = new Exp2Syn(ProximalSynapsePositions .x[i]) // // MC syn *** Estimated 
syn.tau1 = 1.5	syn.tau2 = 5.5	syn.e = 0 
pre_list.append(syn) // # 5 
} 

}
	func is_art() { return 0 }

	endtemplate GranuleCell14
//************************************************************************************************************