8 #include "IonChannel.h"
92 #pragma region Accessor-Mutators
240 THROW_TEXT_ERROR(Rn_Err_lNotChemSpikeSyn, Rn_Err_strNotChemSpikeSyn,
"ID: " +
m_strID +
": FacilD");
245 THROW_TEXT_ERROR(Rn_Err_lSynpaseTypeNotDefined, Rn_Err_strSynpaseTypeNotDefined,
"ID: " +
m_strID +
": FacilD");
263 THROW_TEXT_ERROR(Rn_Err_lNotChemSpikeSyn, Rn_Err_strNotChemSpikeSyn,
"ID: " +
m_strID +
": RelFacil");
268 THROW_TEXT_ERROR(Rn_Err_lSynpaseTypeNotDefined, Rn_Err_strSynpaseTypeNotDefined,
"ID: " +
m_strID +
": RelFacil");
308 THROW_TEXT_ERROR(Rn_Err_lSynpaseTypeNotDefined, Rn_Err_strSynpaseTypeNotDefined,
"ID: " +
m_strID +
": VoltDep");
331 THROW_TEXT_ERROR(Rn_Err_lSynpaseTypeNotDefined, Rn_Err_strSynpaseTypeNotDefined,
"ID: " +
m_strID +
": Hebbian");
349 THROW_TEXT_ERROR(Rn_Err_lNotChemSpikeSyn, Rn_Err_strNotChemSpikeSyn,
"ID: " +
m_strID +
": HebbIncrement");
354 THROW_TEXT_ERROR(Rn_Err_lSynpaseTypeNotDefined, Rn_Err_strSynpaseTypeNotDefined,
"ID: " +
m_strID +
": HebbIncrement");
372 THROW_TEXT_ERROR(Rn_Err_lNotChemSpikeSyn, Rn_Err_strNotChemSpikeSyn,
"ID: " +
m_strID +
": HebbTimeWindow");
377 THROW_TEXT_ERROR(Rn_Err_lSynpaseTypeNotDefined, Rn_Err_strSynpaseTypeNotDefined,
"ID: " +
m_strID +
": HebbTimeWindow");
395 THROW_TEXT_ERROR(Rn_Err_lNotChemSpikeSyn, Rn_Err_strNotChemSpikeSyn,
"ID: " +
m_strID +
": MaxGHebb");
400 THROW_TEXT_ERROR(Rn_Err_lSynpaseTypeNotDefined, Rn_Err_strSynpaseTypeNotDefined,
"ID: " +
m_strID +
": MaxGHebb");
423 THROW_TEXT_ERROR(Rn_Err_lSynpaseTypeNotDefined, Rn_Err_strSynpaseTypeNotDefined,
"ID: " +
m_strID +
": AllowForgetting");
441 THROW_TEXT_ERROR(Rn_Err_lNotChemSpikeSyn, Rn_Err_strNotChemSpikeSyn,
"ID: " +
m_strID +
": ForgettingWindow");
446 THROW_TEXT_ERROR(Rn_Err_lSynpaseTypeNotDefined, Rn_Err_strSynpaseTypeNotDefined,
"ID: " +
m_strID +
": ForgettingWindow");
464 THROW_TEXT_ERROR(Rn_Err_lNotChemSpikeSyn, Rn_Err_strNotChemSpikeSyn,
"ID: " +
m_strID +
": Consolidation");
469 THROW_TEXT_ERROR(Rn_Err_lSynpaseTypeNotDefined, Rn_Err_strSynpaseTypeNotDefined,
"ID: " +
m_strID +
": Consolidation");
487 THROW_TEXT_ERROR(Rn_Err_lNotChemSpikeSyn, Rn_Err_strNotChemSpikeSyn,
"ID: " +
m_strID +
": MaxGVoltDepRel");
492 THROW_TEXT_ERROR(Rn_Err_lSynpaseTypeNotDefined, Rn_Err_strSynpaseTypeNotDefined,
"ID: " +
m_strID +
": MaxGVoltDepRel");
496 void Connexion::Load(CStdXml &oXml)
498 AnimatBase::Load(oXml);
507 m_iType=oXml.GetChildInt(
"Type");
513 Delay(oXml.GetChildDouble(
"Delay"));
536 if (pTimeToNext==NULL)
541 if (
Hebbian() && !FreezeLearning)
543 bool bTimedOut=
false;
547 if (pTimeToNext==NULL)
551 if ((*pTimeToNext)<=0)
574 double newG, *pTimeLeftInHebbWindow;
578 if (pTimeLeftInHebbWindow==NULL)
679 return(STD_MAX((
double) 0,G));
692 AnimatBase::SetSystemPointers(lpSim, lpStructure, lpModule, lpNode,
false);
701 AnimatBase::VerifySystemPointers();
704 THROW_PARAM_ERROR(Al_Err_lStructureNotDefined, Al_Err_strStructureNotDefined,
"IGFModule: ",
m_strID);
707 #pragma region DataAccesMethods
713 if(strType ==
"CONDUCTANCE")
716 if(strType ==
"FACILITATION")
720 THROW_PARAM_ERROR(Rn_Err_lInvalidNeuronDataType, Rn_Err_strInvalidNeuronDataType,
"Neuron Data Type", strDataType);
725 bool Connexion::SetData(
const std::string &strDataType,
const std::string &strValue,
bool bThrowError)
729 if(Link::SetData(strDataType, strValue,
false))
732 if(strType ==
"SYNAPTICCONDUCTANCE")
738 if(strType ==
"CONDUCTIONDELAY")
740 Delay(atof(strValue.c_str()));
744 if(strType ==
"SYNAPSETYPEID")
753 THROW_PARAM_ERROR(Al_Err_lInvalidDataType, Al_Err_strInvalidDataType,
"Data Type", strDataType);
758 void Connexion::QueryProperties(CStdPtrArray<TypeProperty> &aryProperties)
760 Link::QueryProperties(aryProperties);
762 aryProperties.Add(
new TypeProperty(
"Conductance", AnimatPropertyType::Float, AnimatPropertyDirection::Get));
763 aryProperties.Add(
new TypeProperty(
"Facilitation", AnimatPropertyType::Float, AnimatPropertyDirection::Get));
765 aryProperties.Add(
new TypeProperty(
"SynapticConductance", AnimatPropertyType::Float, AnimatPropertyDirection::Set));
766 aryProperties.Add(
new TypeProperty(
"ConductionDelay", AnimatPropertyType::Float, AnimatPropertyDirection::Set));
767 aryProperties.Add(
new TypeProperty(
"SynapseTypeID", AnimatPropertyType::String, AnimatPropertyDirection::Set));
void ResetIDs()
Resets the IDs of the synapse types.
Neuron * m_lpSource
Pointer to the source Neuron.
int Del(void)
Deletes this object.
void DecrementLatencies(double dt, bool FreezeLearning=false)
Decrements latencies.
double ForgettingWindow()
Gets the forgetting time window.
double * Iterate(void)
Gets the iterate.
bool VoltDep()
Gets whether this synapse is voltage dependent.
int m_iType
Zero-based index of the synaspe type.
Spiking chemical synapse type.
Declares the integrate fire module class.
Integrate and fire neural module.
void IncrementHebbian()
Increments hebbian values.
double HebbIncrement()
Increments the hebbian weight.
DoubleList m_TransitCx
Sets whether there is a partial block hold.
double m_dPreviousSpikeLatency
The partial block.
Connexion()
Default constructor.
int NeuronID()
Gets the neuron ID.
virtual float * GetDataPointer(const std::string &strDataType)
Returns a float pointer to a data item of interest in this object.
double MaxGVoltDepRel()
Gets the maximum relative conductance.
double m_dGFacilCx
facilitated increase in g when input occurs
Declares the connexion class.
std::string SynapseTypeID()
Gets the synapse type identifier.
double Delay()
Gets the synaptic delay.
double MaxGHebb()
Gets the maximum hebbian conductance.
virtual std::string ID()
Gets the unique GUID ID of this object.
double RelFacil()
Gets the relative facilitation.
virtual void ResetSimulation()
Resets the simulation back to time 0.
double FacilD()
Gets the facilitation decrement value.
int SynapseTypeID()
Gets the synapse type identifier.
double HebbTimeWindow()
Gets the learning time window.
double Consolidation()
Gets the consolidation factor.
std::string TargetID()
Gets the target neuron ID.
float m_fltGReport
The reported variable for synaptic conductance.
int m_iTarget
Zero-based index of the target neuron.
Declares the spiking chemical synapse class.
double ProcessOutput(bool bFreezeHebb=false)
Process the output described of the connection.
std::string m_strID
The unique Id for this object.
double BaseConductance()
Gets the base conductance.
void PreCalc()
Performs pre-step calculations.
void Hebbian(bool bVal)
Sets whether this synapse uses Hebbian learning.
std::string SourceID()
Gets the source neuron ID.
virtual ~Connexion()
Destructor.
Neuron * m_lpTarget
Pointer to the target Neuron.
int AddTail(double d)
Adds a tail.
Declares the ca activation class.
virtual void VerifySystemPointers()
Verify that system pointers have been set correctly.
double m_dBaseG
The base conductance.
double m_dTimeSincePrevHebbEvent
The time since previous hebb event.
IntegrateFireNeuralModule * m_lpIGFModule
The pointer to the parent IntegrateFireNeuralModule.
double MaxGVoltDepRel()
Gets the maximum conductance for voltage dependent.
double HebbTimeWindow()
Gets the hebbian time window.
float m_fltGFailCxReport
reported variable for facilitated increase in g when input occurs
bool Hebbian()
Gets if the synapse type is Hebbian.
std::string m_strSynapseTypeID
GUID ID for the synapse type to use.
double ForgettingWindow()
Gets the forgetting time window.
virtual bool SetData(const std::string &strDataType, const std::string &strValue, bool bThrowError=true)
Set a variable based on a string data type name.
bool VoltDep()
Gets whether the synapse type is voltage dependent.
Declares the synapse type class.
double m_dG
The synaptic conductance.
SynapseType * m_lpSynType
Pointer to the synapse type for this connection.
double MaxGHebb()
Gets the maximum augmented conductance.
void Release(void)
Releases this object.
Declares the electrical synapse class.
double HebbIncrement()
Gets the hebbian increment.
double RelFacil()
Gets the relative facilitation.
std::string m_strTargetID
GUID ID for the target Neuron.
bool AllowForgetting()
Gets whether forgetting is allowed.
DoubleList m_HebbList
List of hebbian events.
std::string Std_CheckString(std::string strVal)
Converts a string to upper case and trims it.
double GetProspectiveCond(bool bFreezeHebb)
Gets a prospective condutance.
double FacilD()
Gets the facilitation decrement value.
double Consolidation()
Gets the consolidation factor.
int m_iID
Identifier ID for this connection.
std::string m_strSourceID
GUID ID for the source Neuron.
int m_iSource
Zero-based index of the source neuron.
void AllowForgetting(bool bVal)
Sets whether forgetting is allowed.
void DecrementFacilitation()
Decrements the facilitation.
double m_dDelay
The synaptic delay.
Contains all of the classes to implement a basic integrate and fire neural model. ...
Declares the non spiking chemical synapse class.
Declares the neuron class.