Skip to content

Instantly share code, notes, and snippets.

@imalsogreg
Last active July 14, 2023 22:01
Show Gist options
  • Save imalsogreg/93ffa7d7a0d1469600ce456abd52cc7f to your computer and use it in GitHub Desktop.
Save imalsogreg/93ffa7d7a0d1469600ce456abd52cc7f to your computer and use it in GitHub Desktop.
A soma and axon with two stimulators - action potentials should collide and cancel
let
defaultSwcNeuron = https://raw.githubusercontent.com/reuron/reuron-lib/main/defaultSwcNeuron.ffg
let
stimulator =
Neuron/stimulator {
envelope: {
period_sec: 0.02,
onset_sec: 0.01,
offset_sec: 0.0105
},
current_shape: SquareWave {
on_current_uamps_per_square_cm: 200.0,
off_current_uamps_per_square_cm: -1.0
}
} in
Neuron/scene {
neurons: [
{ neuron: defaultSwcNeuron [
{ id: 1, parent: -1, x: -500.0, y: 0.0, z: 0.0, r: 0.5, type: 1 },
{ id: 2, parent: 1, x: -400.0, y: 0.0, z: 0.0, r: 0.5, type: 2 },
{ id: 3, parent: 2, x: -300.0, y: 0.0, z: 0.0, r: 0.5, type: 2 },
{ id: 4, parent: 3, x: -200.0, y: 0.0, z: 0.0, r: 0.5, type: 2 },
{ id: 5, parent: 4, x: -100.0, y: 0.0, z: 0.0, r: 0.5, type: 2 },
{ id: 6, parent: 5, x: 000.0, y: 0.0, z: 0.0, r: 0.5, type: 2 },
{ id: 7, parent: 6, x: 100.0, y: 0.0, z: 0.0, r: 0.5, type: 2 },
{ id: 8, parent: 7, x: 200.0, y: 0.0, z: 0.0, r: 0.5, type: 2 },
{ id: 9, parent: 8, x: 300.0, y: 0.0, z: 0.0, r: 0.5, type: 2 },
{ id: 10, parent: 9, x: 400.0, y: 0.0, z: 0.0, r: 0.5, type: 2 },
]
, location: { x_mm: 0.0, y_mm: 0.0, z_mm: 0.0 }
, stimulator_segments: [
{ segment: 1, stimulator: stimulator },
{ segment: 10, stimulator: stimulator },
]
},
],
synapses: []
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment