Skip to content

Commit

Permalink
allow self-loops for chemical synapses
Browse files Browse the repository at this point in the history
  • Loading branch information
pmendes committed Aug 27, 2024
1 parent 435ccd2 commit 7c1ab3d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions sbmodelr
Original file line number Diff line number Diff line change
Expand Up @@ -1416,9 +1416,9 @@ if( odelink ):
set_parameters(oname, exact=True, type='ode', expression=odexpr, model=newmodel)
if( args.network ):
for link in links:
# check if we have a self-connection and ignore it
if( link[0] == link[1]):
print(f' Warning: diffusive or synaptic coupling onto the same unit not allowed, ignoring {link[0]} -> {link[1]}')
# check if we have a self-connection and ignore it for diffusive connections
if( (link[0] == link[1]) and linktype=='d'):
print(f' Warning: diffusive coupling onto the same unit not allowed, ignoring {link[0]} -> {link[1]}')
continue
suffa = f'{link[0]}'
oaname = f'{ode}_{suffa}'
Expand Down

0 comments on commit 7c1ab3d

Please sign in to comment.