fixed initial condition of IF models
This commit is contained in:
@@ -28,7 +28,7 @@ function spikes = lifouspikes( trials, input, tmaxdt, D, outau )
|
||||
times = [];
|
||||
j = 1;
|
||||
n = 0.0;
|
||||
v = vreset;
|
||||
v = vreset + (vthresh-vreset)*rand();
|
||||
noise = sqrt(2.0*D)*randn( length( input ), 1 )/sqrt(dt);
|
||||
for i=1:length( noise )
|
||||
n = n + ( - n + noise(i))*dt/outau;
|
||||
|
||||
@@ -28,7 +28,7 @@ function spikes = pifouspikes( trials, input, tmaxdt, D, outau )
|
||||
times = [];
|
||||
j = 1;
|
||||
n = 0.0;
|
||||
v = vreset;
|
||||
v = vreset + (vthresh-vreset)*rand();
|
||||
noise = sqrt(2.0*D)*randn( length( input ), 1 )/sqrt(dt);
|
||||
for i=1:length( noise )
|
||||
n = n + ( - n + noise(i))*dt/outau;
|
||||
|
||||
Reference in New Issue
Block a user