Running two simulations

Anything that doesn't fit elsewhere.
Post Reply
shyam_u2
Posts: 77
Joined: Sun Feb 20, 2011 7:15 pm

Running two simulations

Post by shyam_u2 »

In my network model I want to run two simulations. Simulation 1 runs for 1000 ms and Simulation 2 for another 1000 ms.
Simulation 2 uses a variable 'var1' which is calculated from the results of simulation 1. How do I do this ? The condition is that simulation 2 should not be a continuation of simulation 1. It should start fresh (just that a variable in sim 2 is computed from result of sim 1).

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

Re: Running two simulations

Post by ted »

Code: Select all

// $1 and $2 are durations of the first and second parts of the simulation

proc runrun() {
  tstop = $1
  run()
  mycustomstuff() // analyzes results and changes one or more parameters
                  // note:  mycustomstuff() shouldn't destroy the contents
                  // of any Vector that was capturing data
  cvode.re_init()
  continuerun($2)
}
Post Reply