TDConnection.h

Go to the documentation of this file.
00001 /************************************************************************
00002 * Verve                                                                 *
00003 * Copyright (C) 2004-2006                                               *
00004 * Tyler Streeter  tylerstreeter@gmail.com                               *
00005 * All rights reserved.                                                  *
00006 * Web: http://verve-agents.sourceforge.net                              *
00007 *                                                                       *
00008 * This library is free software; you can redistribute it and/or         *
00009 * modify it under the terms of EITHER:                                  *
00010 *   (1) The GNU Lesser General Public License as published by the Free  *
00011 *       Software Foundation; either version 2.1 of the License, or (at  *
00012 *       your option) any later version. The text of the GNU Lesser      *
00013 *       General Public License is included with this library in the     *
00014 *       file license-LGPL.txt.                                          *
00015 *   (2) The BSD-style license that is included with this library in     *
00016 *       the file license-BSD.txt.                                       *
00017 *                                                                       *
00018 * This library is distributed in the hope that it will be useful,       *
00019 * but WITHOUT ANY WARRANTY; without even the implied warranty of        *
00020 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files    *
00021 * license-LGPL.txt and license-BSD.txt for more details.                *
00022 ************************************************************************/
00023 
00024 #ifndef VERVE_TD_CONNECTION_H
00025 #define VERVE_TD_CONNECTION_H
00026 
00027 #include "Connection.h"
00028 
00029 namespace verve
00030 {
00031         class Neuron;
00032 
00034         enum TDConnectionType
00035         {
00037                 VALUE_FUNCTION_TDCONNECTION,
00038 
00040                 POLICY_TDCONNECTION
00041         };
00042 
00044         class TDConnection : public Connection
00045         {
00046         public:
00047                 VERVE_DECL TDConnection(Neuron* preNeuron, Neuron* postNeuron, 
00048                         TDConnectionType type);
00049 
00054                 VERVE_DECL virtual ~TDConnection();
00055 
00057                 VERVE_DECL virtual TDConnectionType VERVE_CALL getTDConnectionType();
00058 
00060                 VERVE_DECL virtual void VERVE_CALL increaseETrace();
00061 
00063                 VERVE_DECL virtual void VERVE_CALL decayETrace();
00064 
00067                 VERVE_DECL virtual void VERVE_CALL setETraceDecayFactor(real value);
00068 
00071                 VERVE_DECL virtual void VERVE_CALL setTDDiscountFactor(real value);
00072 
00074                 VERVE_DECL virtual void VERVE_CALL setETrace(real trace);
00075 
00077                 VERVE_DECL virtual real VERVE_CALL getETrace()const;
00078 
00081                 VERVE_DECL virtual void VERVE_CALL resetShortTermMemory();
00082 
00084                 VERVE_DECL virtual void VERVE_CALL applyTDLearning(
00085                         real learningFactorTimesTDError);
00086 
00088                 VERVE_DECL virtual void VERVE_CALL setIsInActiveList(bool inList);
00089 
00092                 VERVE_DECL virtual bool VERVE_CALL isInActiveList();
00093 
00094         protected:
00097                 real mETrace;
00098 
00100                 TDConnectionType mTDConnectionType;
00101 
00103                 real mETraceDecayFactor;
00104 
00106                 real mTDDiscountFactor;
00107 
00110                 bool mIsInActiveList;
00111         };
00112 }
00113 
00114 #endif

Generated on Tue Jan 24 21:46:37 2006 for Verve by  doxygen 1.4.6-NO