10 #include "../basecode/header.h"
11 #include "../basecode/global.h"
21 "Sends out a trigger for an event.");
31 "Handles process call",
34 "Handles reinit call",
37 static Finfo* processShared[] =
43 "Shared message to receive Process message from scheduler",
44 processShared,
sizeof( processShared ) /
sizeof(
Finfo* ) );
55 "Specifies rate for random spike train. Note that this is"
56 "probabilistic, so the instantaneous rate may differ. "
57 "If the rate is assigned be message and it varies slowly then "
58 "the average firing rate will approach the specified rate",
68 "Absolute refractory time. Synonym for refractT.",
73 "Flag: when false, do Poisson process with specified mean rate.\n"
74 "When true, fire periodically at specified rate.\n"
75 "Defaults to false. Note that refractory time overrides this: "
76 "Rate cannot exceed 1/refractT.",
81 "True if RandSpike has just fired",
85 static Finfo* spikeGenFinfos[] =
99 "Author",
"Upi Bhalla",
100 "Description",
"RandSpike object, generates random or regular "
102 "specified mean rate. Based closely on GENESIS randspike. "
108 spikeGenFinfos,
sizeof( spikeGenFinfos ) /
sizeof(
Finfo* ),
111 sizeof(doc)/
sizeof(
string)
141 cout <<
"Warning: RandSpike::setRate: Rate must be >= 0. Using 0.\n";
148 cout <<
"Warning: RandSpike::setRate: Rate is too high compared to refractory time\n";
227 double m = 1.0 /
rate_;
static const Cinfo * spikeGenCinfo
static const Cinfo * initCinfo()
void setRate(double rate)
void process(const Eref &e, ProcPtr p)
void log(string msg, serverity_level_ type=debug, bool redirectToConsole=true, bool removeTicks=true)
Log to console (and to a log-file)
bool getDoPeriodic() const
void reinit(const Eref &e, ProcPtr p)
static SrcFinfo1< double > * spikeOut()
double mtrand(void)
Generate a random double between 0 and 1.
static const Cinfo * initCinfo()
void setRefractT(double val)
double getRefractT() const
void setDoPeriodic(bool val)