File: cell.g

package info (click to toggle)
genesis 2.1-1.1
  • links: PTS
  • area: main
  • in suites: potato
  • size: 14,288 kB
  • ctags: 10,667
  • sloc: ansic: 111,959; makefile: 2,240; yacc: 1,797; lex: 976; csh: 54; sh: 13
file content (62 lines) | stat: -rw-r--r-- 2,326 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
//genesis
// cell.g
/* 
	functions defined in this script
=============================================================================
	FUNCTION NAME		ARGUMENTS
=============================================================================
	makeneuron		(path,soma_l,soma_d,dend_l,dend_d)
	reset_kludge
=============================================================================
*/

//=================================================
//                    NEURON
//=================================================
function makeneuron(path, soma_l, soma_d, dend_l, dend_d)
    str path
    float soma_l, soma_d
    float dend_l, dend_d

    // 100% of the soma active
    float active_area = soma_l*PI*soma_d*1.0

    create neutral {path}
    pushe {path}
    //=============================================
    //                   cell body
    //=============================================
    makecompartment soma {soma_l} {soma_d} {Eleak}
    position soma I I R{-soma_l/2.0}
    setfield soma initVm {EREST_ACT}  // properly initialize Vm on reset
    //=============================================
    //          voltage dependent conductances
    //=============================================
    make_hhNa soma Ex_channel {active_area} {ENa} {EREST_ACT}
    make_hhK soma Inh_channel {active_area} {EK} {EREST_ACT}

    //=============================================
    //                   dendrites
    //=============================================
    makecompartment dend1 {dend_l} {dend_d} {EREST}
    link_compartment dend1 soma
    makecompartment dend2 {dend_l} {dend_d} {EREST}
    link_compartment dend2 dend1
    //=============================================
    //    synaptic conductances on the dendrites
    //=============================================
    makechannel dend1 Ex_channel {EEx} 3.0 3.0 {GEx}
    makechannel dend1 Inh_channel {EInh} 3.0 3.0 {GInh}
    makechannel dend2 Ex_channel {EEx} 3.0 3.0 {GEx}
    makechannel dend2 Inh_channel {EInh} 3.0 3.0 {GInh}

    pope
end

// reset_kludge was a kludge to properly initialize soma Vm to EREST on reset
// In 2.0, this is handled by initVm field
function reset_kludge
    reset
    /* Should add some tricky business to allow cycling of colors with
      overlayed soma Vm plots, as was done in 1.4 version          */
end