Changing NetStim parameters during runtime.

Anything that doesn't fit elsewhere.
Post Reply
delarue
Posts: 8
Joined: Tue Jun 24, 2008 12:53 pm

Changing NetStim parameters during runtime.

Post by delarue » Thu Apr 01, 2010 4:36 pm

Hello,
I want to simulate synaptic stimulation with the pattern of stimulation that depends on some conditions at the moment. That is, something like this -

1. At time t_1, stimulate with N_1 pulses at frequency f_1
2. At time t_2 (t_2 sufficiently larger than t_1 not to overlap with earlier stimulations) compute "the state" -
2a. if condition C_1 holds, then stimulate with N_2a pulses at frequency f_2a
2b. otherwise, stimulate with N_2b pulses at frequency f_2b

I was thinking that the best way to implement this would be by using the same NetStim with dynamically (depending on the state) updated stimulation parameters. It seems though that NetStim "reads" the first set of parameters (at time t_1) and does not recognize any modifications that I am trying to introduce later in the course of the simulation.

Is there any way to overcome this issue and have NetStim parameters updated dynamically?

THanks.

ted
Site Admin
Posts: 5593
Joined: Wed May 18, 2005 4:50 pm
Location: Yale University School of Medicine
Contact:

Re: Changing NetStim parameters during runtime.

Post by ted » Fri Apr 02, 2010 1:20 pm

You want to create a state machine. Forget about NetStim; use the NetCon class's event() method instead. You'll probably also find the CVode class's event() method and the FInitializeHandler class to be helpful. These are all described in the Programmer's Reference.

Post Reply