NEST  2.6.0,not_revisioned_source_dir@0
archiving_node.h
Go to the documentation of this file.
1 /*
2  * archiving_node.h
3  *
4  * This file is part of NEST.
5  *
6  * Copyright (C) 2004 The NEST Initiative
7  *
8  * NEST is free software: you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation, either version 2 of the License, or
11  * (at your option) any later version.
12  *
13  * NEST is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License
19  * along with NEST. If not, see <http://www.gnu.org/licenses/>.
20  *
21  */
22 
31 #ifndef ARCHIVING_NODE_H
32 #define ARCHIVING_NODE_H
33 
34 #include "nest.h"
35 #include "node.h"
36 #include "dictdatum.h"
37 #include "nest_time.h"
38 #include "histentry.h"
39 #include <deque>
40 
41 #define DEBUG_ARCHIVER 1
42 
43 namespace nest {
44 
51  public Node
52 {
53 
54  public:
55 
56 
62 
68 
69 
75 
82  void get_K_values(double_t t, double_t& Kminus, double_t& triplet_Kminus);
83 
89  double_t get_triplet_K_value(const std::deque<histentry>::iterator &iter);
90 
95  void get_history(double_t t1, double_t t2,
96  std::deque<histentry>::iterator* start,
97  std::deque<histentry>::iterator* finish);
98 
104  void register_stdp_connection(double_t t_first_read);
105 
110  void unregister_stdp_connection(double_t t_last_read);
111 
112 
113  void get_status(DictionaryDatum & d) const;
114  void set_status(const DictionaryDatum & d);
115 
116  protected:
117 
122  void set_spiketime(Time const & t_sp);
123 
128  inline double_t get_spiketime_ms() const;
129 
134  void clear_history();
135 
136 
137  private:
138 
139  // number of incoming connections from stdp connectors.
140  // needed to determine, if every incoming connection has
141  // read the spikehistory for a given point in time
142  size_t n_incoming_;
143 
144  // sum exp(-(t-ti)/tau_minus)
146 
147  // sum exp(-(t-ti)/tau_minus_triplet)
149 
151 
152  // time constant for triplet low pass filtering of "post" spike train
154 
156 
157  // spiking history needed by stdp synapses
158  std::deque<histentry> history_;
159 
160 };
161 
162 inline
164 {
165  return last_spike_;
166 }
167 
168 } // of namespace
169 
170 #endif
171 
172 
173 
double_t Kminus_
Definition: archiving_node.h:145
void get_history(double_t t1, double_t t2, std::deque< histentry >::iterator *start, std::deque< histentry >::iterator *finish)
return the spike times (in steps) of spikes which occurred in the range (t1,t2].
Definition: archiving_node.cpp:126
void unregister_stdp_connection(double_t t_last_read)
Unregister this incoming connection.
Definition: archiving_node.cpp:71
double_t last_spike_
Definition: archiving_node.h:155
const Name d("d")
Specific to Izhikevich 2003.
Definition: nest_names.h:83
Declarations for base class Node.
Part of definition of Archiving_Node which is capable of recording and managing a spike history...
size_t n_incoming_
Definition: archiving_node.h:142
void clear_history()
clear spike history
Definition: archiving_node.cpp:206
void register_stdp_connection(double_t t_first_read)
Register a new incoming STDP connection.
Definition: archiving_node.cpp:56
double_t triplet_Kminus_
Definition: archiving_node.h:148
Definition: nest_time.h:130
double_t get_K_value(double_t t)
return the Kminus value at t (in ms).
Definition: archiving_node.cpp:86
double_t tau_minus_triplet_
Definition: archiving_node.h:153
void set_status(const DictionaryDatum &d)
Definition: archiving_node.cpp:185
std::deque< histentry > history_
Definition: archiving_node.h:158
const Name start("start")
Device parameters.
Definition: nest_names.h:263
a node which archives spike history for the purposes of timing dependent plasticity ...
Definition: archiving_node.h:50
void set_spiketime(Time const &t_sp)
record spike history
Definition: archiving_node.cpp:150
double double_t
Double precision floating point numbers.
Definition: nest.h:93
Default types used by the NEST kernel.
void get_status(DictionaryDatum &d) const
Definition: archiving_node.cpp:175
Archiving_Node()
Constructor.
Definition: archiving_node.cpp:37
Base class for all NEST network objects.
Definition: node.h:96
double_t get_triplet_K_value(const std::deque< histentry >::iterator &iter)
return the triplet Kminus value for the associated iterator.
double_t get_spiketime_ms() const
Definition: archiving_node.h:163
double_t tau_minus_
Definition: archiving_node.h:150
void get_K_values(double_t t, double_t &Kminus, double_t &triplet_Kminus)
write the Kminus and triplet_Kminus values at t (in ms) to the provided locations.
Definition: archiving_node.cpp:99