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

nn.h

00001 /***************************************************************************
00002                           nn.h  -  description
00003                              -------------------
00004     begin                : Sat Apr 12 2003
00005     copyright            : (C) 2003 by root
00006     email                : root@localhost.localdomain
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; either version 2 of the License, or     *
00014  *   (at your option) any later version.                                   *
00015  *                                                                         *
00016  ***************************************************************************/
00017 
00018 #ifndef NN_H
00019 #define NN_H
00020 
00021 #define MAXLEVEL 4
00022 #define MAXNODES 50
00023 #define MAXPARAMS 300
00024 #include <stdio.h>
00025 #include <math.h>
00026 #include "serializable.h"
00027 
00037 class NN :public Serializable{
00038 public: 
00039     NN();
00040     ~NN();
00042     int nlevels;
00044     int nnodes[MAXLEVEL];
00049     float wm[MAXLEVEL-1][MAXNODES][MAXNODES];
00052     float thresh[MAXLEVEL-1][MAXNODES];
00055     float activ[MAXLEVEL][MAXNODES];
00059     int nparams;
00060     float params[MAXPARAMS];
00061     void calcres(float *inp);
00072     void calcresSpecial(float *inp);
00074     void printThresholds();
00076     void printWeights();
00078     void printActivations();
00083     void saveNetwork(FILE *f);
00084     void loadNetwork(FILE *f);
00085     void Serialize(FILE *f);
00086     void Deserialize(FILE *f);
00087 };
00088 
00089 #endif

Generated on Thu Feb 12 18:42:57 2004 for ParallelizedEvolutionSystem by doxygen1.2.18