001: //
002: // Heccer : a compartmental solver that implements efficient Crank-Nicolson
003: // integration for neuronal models.
004: //
005: 
006: //////////////////////////////////////////////////////////////////////////////
007: //'
008: //' Heccer : testbed C implementation
009: //'
010: //' Copyright (C) 2006-2008 Hugo Cornelis
011: //'
012: //' functional ideas ..   Hugo Cornelis, hugo.cornelis@gmail.com
013: //'
014: //' coding ............   Hugo Cornelis, hugo.cornelis@gmail.com
015: //'
016: //////////////////////////////////////////////////////////////////////////////
017: 
018: 
019: #include "../../heccer/compartment.h"
020: #include "../../heccer/heccer.h"
021: 
022: 
023: struct Compartment comp[] =
024: {
025:     {
026:         //m administrative overhead
027: 
028:         {
029:             //m type of structure
030: 
031:             MATH_TYPE_Compartment,
032:         },
033: 
034:         //m index of parent compartment, -1 for none
035: 
036:         -1,
037: 
038: /* 	//m first mechanism */
039: 
040: /* 	NULL, */
041: 
042: /* 	//m number of mechanisms */
043: 
044: /* 	0, */
045: 
046:         //m descriptive values, alphabetical order
047: 
048: /*     double dCm; */
049: 
050:         4.57537e-11, // unscaled 0.0164,
051: 
052: /*     double dEm; */
053: 
054:         -0.08,
055: 
056: /*     double dInitVm; */
057: 
058:         -0.068,
059: 
060: /*     double dInject;		 */
061: 
062:         0,
063: 
064: /*     double dRa; */
065: 
066:         360502, // unscaled 2.5,
067: 
068: /*     double dRm; */
069: 
070:         3.58441e+08, // unscaled 1
071:     },
072: 
073:     {
074:         //m administrative overhead
075: 
076:         {
077:             //m type of structure
078: 
079:             MATH_TYPE_Compartment,
080:         },
081: 
082:         //m index of parent compartment, -1 for none
083: 
084:         0,
085: 
086: /* 	//m first mechanism */
087: 
088: /* 	NULL, */
089: 
090: /* 	//m number of mechanisms */
091: 
092: /* 	0, */
093: 
094:         //m descriptive values, alphabetical order
095: 
096: /*     double dCm; */
097: 
098:         4.57537e-11, // unscaled 0.0164,
099: 
100: /*     double dEm; */
101: 
102:         -0.08,
103: 
104: /*     double dInitVm; */
105: 
106:         -0.068,
107: 
108: /*     double dInject;		 */
109: 
110:         0,
111: 
112: /*     double dRa; */
113: 
114:         360502, // unscaled 2.5,
115: 
116: /*     double dRm; */
117: 
118:         3.58441e+08, // unscaled 1
119:     },
120: 
121:     {
122:         //m administrative overhead
123: 
124:         {
125:             //m type of structure
126: 
127:             MATH_TYPE_Compartment,
128:         },
129: 
130:         //m index of parent compartment, -1 for none
131: 
132:         0,
133: 
134: /* 	//m first mechanism */
135: 
136: /* 	NULL, */
137: 
138: /* 	//m number of mechanisms */
139: 
140: /* 	0, */
141: 
142:         //m descriptive values, alphabetical order
143: 
144: /*     double dCm; */
145: 
146:         4.57537e-11, // unscaled 0.0164,
147: 
148: /*     double dEm; */
149: 
150:         -0.08,
151: 
152: /*     double dInitVm; */
153: 
154:         -0.068,
155: 
156: /*     double dInject;		 */
157: 
158:         0,
159: 
160: /*     double dRa; */
161: 
162:         360502, // unscaled 2.5,
163: 
164: /*     double dRm; */
165: 
166:         3.58441e+08, // unscaled 1
167:     },
168: 
169:     {
170:         //m administrative overhead
171: 
172:         {
173:             //m type of structure
174: 
175:             MATH_TYPE_Compartment,
176:         },
177: 
178:         //m index of parent compartment, -1 for none
179: 
180:         2,
181: 
182: /* 	//m first mechanism */
183: 
184: /* 	NULL, */
185: 
186: /* 	//m number of mechanisms */
187: 
188: /* 	0, */
189: 
190:         //m descriptive values, alphabetical order
191: 
192: /*     double dCm; */
193: 
194:         4.57537e-11, // unscaled 0.0164,
195: 
196: /*     double dEm; */
197: 
198:         -0.08,
199: 
200: /*     double dInitVm; */
201: 
202:         -0.068,
203: 
204: /*     double dInject;		 */
205: 
206:         0,
207: 
208: /*     double dRa; */
209: 
210:         360502, // unscaled 2.5,
211: 
212: /*     double dRm; */
213: 
214:         3.58441e+08, // unscaled 1
215:     },
216: };
217: 
218: 
219: int piC2m[] =
220: {
221:     0,
222:     0,
223:     0,
224:     0,
225:     -1,
226: };
227: 
228: 
229: struct Intermediary inter =
230: {
231:     //m compartment array
232: 
233:     4,
234: 
235:     comp,
236: 
237:     //m all other mathematical components
238: 
239:     NULL,
240: 
241:     //m compartment 2 first mechanism number
242: 
243:     piC2m,
244: };
245: 
246: 
247: #include "main.c"
248: 
249: