Spike
Loading...
Searching...
No Matches
Spike::PIF Class Reference

Implements a perfect integrate-and-fire (PIF) neuron. More...

#include <IF.h>

Public Member Functions

 PIF (double mu, double D)
 Construct PIF from parameters.
 
 PIF (const std::string &input_file)
 Construct PIF from input file.
 
double drift (double v) const override
 Returns drift of the PIF neuron, i.e. mu.
 
void print (std::ostream &out) const override
 Prints the PIF neuron to out stream.
 
- Public Member Functions inherited from Spike::IF
 IF (const std::string &input_file)
 Constructs an IF neuron from a .ini file.
 
 IF (double mu, double D)
 Construct an IF neuron from given parameters.
 
double diffusion () const
 Calculates the diffusion of the IF neurons, i.e. sqrt(2D).
 
void get_spikes (SpikeTrain &spike_train) override
 Obtains spikes by integrating the Langevin equation using an Euler-Maruyama scheme.
 
void get_spikes (Signal &signal, SpikeTrain &spike_train) override
 Obtains spikes by integrating the Langevin equation using an Euler-Maruyama scheme. Neuron is subject to an applied signal.
 
void get_voltage_curve (const TimeFrame &time, std::vector< double > &v)
 Calculates the trajectory, i.e. v(t) for a given time frame.
 
void set_mu (double mu_new)
 Set new mean input current.
 
void set_D (double D_new)
 Set new diffusion coefficient.
 
double get_D () const
 Returns the diffusion coefficient.
 

Additional Inherited Members

- Protected Attributes inherited from Spike::IF
double mu
 mean input current
 
double D
 diffusion coefficient
 
std::random_device rd
 random device (seeding)
 
std::mt19937 generator
 random number generator
 
std::normal_distribution< double > dist
 normal distribution
 

Detailed Description

Implements a perfect integrate-and-fire (PIF) neuron.

Constructor & Destructor Documentation

◆ PIF() [1/2]

Spike::PIF::PIF ( double mu,
double D )

Construct PIF from parameters.

Parameters
muMean input current
DDiffusion coefficient

◆ PIF() [2/2]

Spike::PIF::PIF ( const std::string & input_file)
explicit

Construct PIF from input file.

Parameters
input_filePath to .ini file

Member Function Documentation

◆ drift()

double Spike::PIF::drift ( double v) const
overridevirtual

Returns drift of the PIF neuron, i.e. mu.

Parameters
vVoltage
Returns
Drift of PIF

Implements Spike::IF.

◆ print()

void Spike::PIF::print ( std::ostream & out) const
inlineoverridevirtual

Prints the PIF neuron to out stream.

Parameters
outout stream

Implements Spike::IF.


The documentation for this class was generated from the following files: