g_SYN = [0.25] E_SYN = [-80] tauDx = [10] tauRx = [0.4] fanout = [Inf] IC = [0.1] IC_noise = [0] Nmax = max(Npre,Npost) srcpos = linspace(1,Nmax,Npre)'*ones(1,Npost) dstpos = (linspace(1,Nmax,Npost)'*ones(1,Npre))' netcon = (abs(srcpos-dstpos)<=fanout) ISYN(V,s) = (g_SYN.*(s*netcon).*(V-E_SYN)) s' = -s./tauDx + ((1-s)/tauRx).*(1+tanh(IN/10)); s(0) = IC+IC_noise.*rand(1,Npre) current => -ISYN(OUT,s)