ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/osprai/osprai/trunk/mdl_module.py
(Generate patch)
# Line 2 | Line 2
2   mdl: Example model functions module for SPRI data.
3   Christopher Lausted, Institute for Systems Biology,
4   OSPRAI developers
5 < Last modified on 100421 (yymmdd)
5 > Last modified on 100425 (yymmdd)
6  
7 < Example:
7 > Examples:
8   #import mdl_module as mdl
9 < #params = {'Rate': {'value':1, 'min':-100.0, 'max':100.0, 'fixed':False} }
10 < #params = dict(Rate = dict(value=1, min=0, max=10, fixed=False))
11 < #times = range(100)
12 < #data1 = drift(time, data0, params)
13 < print data1
9 > #import numpy as np
10 > #times = np.arange(100)
11 > #data = np.zeros(100)
12 > #
13 > #params1 = dict(rate=dict(value=1.0, min=-100.0, max=100.0, fixed=True))
14 > #data1 = drift(time, data, param1)
15 > #
16 > #param2 = {'t1': {'value':30.0, 'min':30.0, 'max':30.0, 'fixed':True} }
17 > #param2['rmax'] =  {'value': 100.0}
18 > #param2['conc'] =  {'value': 1e-6}
19 > #param2['kon'] =   {'value': 2e4}
20 > #param2['t2'] =    {'value': 150.0}
21 > #param2['koff'] =  {'value': 1e-3}
22 > #param2['t3'] =    {'value': 270.0}
23 > #data2 = simple1to1(time, data, param2)
24   """
25 < __version__ = "100421"
25 > __version__ = "100425"
26  
27  
28   ## Import libraries
# Line 41 | Line 51
51          y[i] = y[i-1] + dy
52          
53      return y
54 +    ## End of drift() function.
55  
56  
57   def simple1to1(time, data, params):
# Line 85 | Line 96
96              y[i] = y[i-1] + dy * (time[i] - time[i-1])
97              
98      return y
99 +    ## End of simple1to1() function
100  
101 +
102 + ################################# End of module #################################

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines