Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members  

netiodata.h

00001 /***************************************************************************
00002                           netiodata.h  -  description
00003                              -------------------
00004     copyright            : (C) 2000 by Matt Grover
00005     email                : mgrover@amygdala.org
00006  ***************************************************************************/
00007 
00008 /***************************************************************************
00009  *                                                                         *
00010  *   This program is free software; you can redistribute it and/or modify  *
00011  *   it under the terms of the GNU General Public License as published by  *
00012  *   the Free Software Foundation; either version 2 of the License, or     *
00013  *   (at your option) any later version.                                   *
00014  *                                                                         *
00015  ***************************************************************************/
00016 
00017 #ifndef NETIODATA_H
00018 #define NETIODATA_H
00019 
00020 using namespace std;
00021 #include <vector>
00022 
00027 class NetIOData {
00028 public:
00029     NetIOData(int size);
00030     virtual ~NetIOData();
00031 
00036     virtual int AddSynapse(unsigned int neuronId, unsigned int synapseId, float weight);
00037 
00042     virtual unsigned int FirstNeuron();
00043 
00048     virtual unsigned int NextNeuron();
00049 
00054     virtual int FirstSynapse(unsigned int& synId, float& val);
00055 
00060     virtual int NextSynapse(unsigned int& synId, float& val);
00061 
00062 protected:
00063 
00064     unsigned int netSize;
00065 
00066     // synapse weight storage
00067     struct SynapseData {
00068         unsigned int neuronId;
00069         float weightVal;
00070     };
00071 
00072     vector<SynapseData>* synapse;
00073     vector<SynapseData> tempSynapse;
00074     unsigned int* indexId;
00075     unsigned int currNeuronIdx;
00076     unsigned int currSynIdx;
00077 };
00078 
00079 #endif

Generated on Wed Sep 4 02:30:35 2002 for Amygdala by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002