⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gen.h

📁 GENETIC ALGORITHM FOR NEURAL NETWORKS ON TRANSPUTERS (Source code and Reference)
💻 H
字号:
/* Declarations of general genetic algorithms */#ifndef GEN_H#define GEN_H	1#include "defs.h"char *GenOptStr();char *GenUsage();char GenParamStr[256]; /* CONSTANTS */int Pcopy;	/* % of indiv. to copy per gen. */int Pmutate;	/* % of indiv. to mutate per gen.*/int Pcrossover;	/* % of indiv. to crossover per gen. */	int Ncopy;	/* no. of indiv. to copy per gen. */int Nmutate;	/* no. of indiv. to mutate per gen.*/int Ncrossover;	/* no. of indiv. to crossover per gen. */	int Decimation;	/* initial decimation factor */float DecErrMin;float DecErrAvg;int HashLen;	/* lenth of hashkey 9n bits */int HashSize;	/* size of hashtable *//* Variables set by calcerr */int Nunique;	/* no. of different indiv. */int Nredundant;	/* no. of redundant indiv. */int Nmismatch;	/* no. of mismatches */float ErrMin;float ErrAvg;int TopInd;/* Arrays */ind    *Pop;	/* Poulation */errtyp *Err;	/* errorlist of Populaton *//* Procedures */int handleGenOpt(char opt,char* arg);int initGen(int popsize,int popmem);void randomPop(int popsize);int hashfct(ind x);void clearerrtab();errtyp geterr(int n);void mutate(ind x0,ind x1);void crossover(ind x0,ind y0,ind x1,ind y1);void copy(ind x0,ind x1);void calcerrors(int popsize);void selection(int popsize);#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -