InheritanceArithmetic

所属分类:人工智能/神经网络/深度学习
开发工具:Visual C++
文件大小:527KB
下载次数:35
上传日期:2006-11-18 16:47:55
上 传 者wangdengwei
说明:  我在此上传的源代码为遗传算法的实现代码程序运行效果良好
(I uploaded the source code for the genetic algorithm code procedures to achieve good results)

文件列表:
遗传算法源代码\说明.txt (28, 2006-08-22)
遗传算法源代码\_desktop.ini (9, 2006-08-27)
遗传算法源代码\基本遗传算法\基本遗传算法\A_LIFE.C (25468, 2000-05-23)
遗传算法源代码\基本遗传算法\基本遗传算法\cfile1.txt (187, 2000-05-15)
遗传算法源代码\基本遗传算法\基本遗传算法\cfile.txt (1364, 2000-05-15)
遗传算法源代码\基本遗传算法\基本遗传算法\efile.txt (1, 2000-05-15)
遗传算法源代码\基本遗传算法\基本遗传算法\EGAVGA.BGI (5363, 1988-08-29)
遗传算法源代码\基本遗传算法\基本遗传算法\ga.c (18941, 2000-05-23)
遗传算法源代码\基本遗传算法\基本遗传算法\GA_NN.C (10639, 2000-05-23)
遗传算法源代码\基本遗传算法\基本遗传算法\gaopt.c (12564, 2000-05-23)
遗传算法源代码\基本遗传算法\基本遗传算法\gfile.txt (23, 2000-05-15)
遗传算法源代码\基本遗传算法\基本遗传算法\graph.c (11177, 2000-05-23)
遗传算法源代码\基本遗传算法\基本遗传算法\HZK16 (267616, 1995-12-22)
遗传算法源代码\基本遗传算法\基本遗传算法\HZK24S (498528, 1995-08-12)
遗传算法源代码\基本遗传算法\基本遗传算法\INPUT (37, 2000-05-15)
遗传算法源代码\基本遗传算法\基本遗传算法\operator.c (2568, 2000-05-23)
遗传算法源代码\基本遗传算法\基本遗传算法\PATMAT.c (13003, 2000-05-23)
遗传算法源代码\基本遗传算法\基本遗传算法\PFILE.TXT (684, 2000-05-15)
遗传算法源代码\基本遗传算法\基本遗传算法\REP.TXT (7283, 2000-05-15)
遗传算法源代码\基本遗传算法\基本遗传算法\rfile.txt (5, 2000-05-15)
遗传算法源代码\基本遗传算法\基本遗传算法\SAMPLE (8848, 2000-05-23)
遗传算法源代码\基本遗传算法\基本遗传算法\scs.c (37062, 2000-05-23)
遗传算法源代码\基本遗传算法\基本遗传算法\scs.cpp (37261, 2000-05-23)
遗传算法源代码\基本遗传算法\基本遗传算法\scs.dsp (4596, 2000-07-10)
遗传算法源代码\基本遗传算法\基本遗传算法\scs.dsw (529, 2000-06-03)
遗传算法源代码\基本遗传算法\基本遗传算法\scs.ncb (50176, 2001-07-05)
遗传算法源代码\基本遗传算法\基本遗传算法\sga.c (19016, 2000-05-23)
遗传算法源代码\基本遗传算法\基本遗传算法\tfile.txt (26, 2000-05-15)
遗传算法源代码\基本遗传算法\基本遗传算法\WORLD (534, 2000-05-15)
遗传算法源代码\基本遗传算法\基本遗传算法\Debug (0, 2006-08-23)
遗传算法源代码\基本遗传算法\基本遗传算法\scs.opt (48640, 2006-08-23)
遗传算法源代码\基本遗传算法\基本遗传算法\_desktop.ini (9, 2006-08-27)
遗传算法源代码\基本遗传算法\基本遗传算法 (0, 2005-04-19)
遗传算法源代码\基本遗传算法\_desktop.ini (9, 2006-08-27)
遗传算法源代码\基本遗传算法 (0, 2006-08-23)
遗传算法源代码\遗传算法代码\遗传算法代码\gasample.cpp (17665, 2003-05-22)
遗传算法源代码\遗传算法代码\遗传算法代码\_desktop.ini (9, 2006-08-27)
遗传算法源代码\遗传算法代码\遗传算法代码 (0, 2004-03-16)
遗传算法源代码\遗传算法代码\_desktop.ini (9, 2006-08-27)
... ...

************************************************************************* GPQUICK A simple Genetic Programming system in C++ Version 2, released 2/12/94 ************************************************************************* Copyright Andy Singleton, 1993,1994 This code is released for non-commercial use only For questions or upgrades contact: Andy Singleton Creation Mechanics, Inc. PO Box 248, Peterborough, NH 03458 Internet: p00396@psilink.com Compuserve: 73313,757 Phone: (603) 563-7757 Further documentation appears in the associated Byte Magazine article "Genetic Programming with C++", February, 1994 ************************************************************************* Packing List ************************************************************************* Source Files: CHROME.H // Core object definitions and GP code CHROME.CPP PRIMITIV.H // Standard GP primitive functions PRIMITIV.CPP SELECTOR.H // A utility GA fitness selector object SELECTOR.CPP PCH.H // Standard headers for "precompiled headers" SSPROB.CPP // A "Simple Symbolic Regression" sample problem // Contains "main" and most user modified sections ANTPROB.CPP // The "Artificial Ant" sample problem SANTAFE.TRL // A trail of food required by the artificial ant Other Files: README.TXT // This file The DOS package may also include GPUICK.EXE // DOS executable of SSPROB GPQUICK.PRJ // Borland project file Optional Files (at McGraw Hill's option) BYTEGP.PS,TXT,WRI // The associated magazine article // It is a general introduction to GP, // but it contains some helpful technical doc ************************************************************************* Instructions ************************************************************************* To Make: Compile CHROME.CPP, PRIMITIV.CPP, SELECTOR.CPP and SSPROB.CPP Link with SSPROB as the main You can substitute ANTPROB or any compatible problem for SSPROB The code is ANSI C++, but you may encounter a few portability issues. It was originally compiled with 16 bit Borland C++ under DOS and MS Windows. Configure for UNIX by uncommenting "#define UNIX" in file PCH.H I will share alterations for other compilers and OS as users provide them. Know Problem: If you run under MS-DOS, you WILL run out of memory with populations larger than 2000. I don't check the return values of the "new" allocations, so the program will just bomb. I strongly recommend compiling under Windows, EasyWin, QuickWin, or a dos extender, which will get you enough memory to comfortably run a population of 10,000 on a typical Windows PC. Runtime Behavior: The sample problem, SSPROB, will attempt to evolve an expression equivalent to John*(George-Paul)+2.5*Ringo. Every 5 seconds or 1000 expression evaluations, it will list to the console the best expression found so far. It will run for 80,000 evaluations, until it finds the right answer, or (under DOS) until you hit a key. The sample problem ANTPROB will attempt to evolve an artificial ant which can traverse the trail of food. The ant moves across a 32x32 grid, and it can sense food immediately ahead, move forward, or turn. As the problem runs, it will display the best ant by the amount of food found. After the ant finds all of the food (89 pieces on the Santa Fe trail), or after 25,000 generates, the problem terminates and prints the path of the best ant to file "RESULT.TXT". This is a replication of the problem described by John Koza in "A-Life II" and "Genetic Programming". Exercises: You can evolve more interesting or useful behavior by editing the problems provide to create your own GP problems. Please: If you develop an interesting problem, send me a copy. Technical Details: GPQUICK as provided here uses a steady state GA, tournament selection three types of mutation, and subtree crossover. It uses tournament selection with a tournament size of six, and a "kill tournament" size of 2. It uses a node mutation (switching a node for another node of the same arity), constant mutation (small adjustments to constant values) and shrink mutation (promote a sub-subtree to replace a subtree) 10% of the time each, a copy with reevaluation on new cases 10% of the time, and subtree crossover 70% of the time. The default population size is 2000. GPQUICK also supports both crossover and mutation "annealing" operations, which replace a parent instead of reproducing into a target site. These can make a small population look big, improve hill climbing, and reduce convergence. The GP representation is a linear array of 2 byte nodes, suggested as "linear prefix jump table" by Mike Keith. This version also contains the FASTEVAL option for fast eval calls. The function argument/return values can be any floating point number. Numeric constants must be integers from -128 to +127. Unless you adjust the constants with hill-climbing methods, the precise constant values are not important. GPQUICK features an elegant object architecture with function (Function), program (Chrome), GA (Pop) and problem (Problem) classes. ************************************************************************* Improvements in version 2 ************************************************************************* In atonement for past sins, I am offering an updated version of GPQUICK. The new version of GPQUICK has the following improvements: Several bug fixes Unified UNIX/DOS/ANSI source More extensible object structure FitnessValue object for carrying problem specific fitness information (in response to popular demand from the GP mailing list) Streamlined Problem files Improved function constructor Standard primitive library, including a working IF and IFLTE. Annealing 2 more mutations Artificial Ant problem ************************************************************************* For More GP fun ************************************************************************* DOODLE GARDEN, a GP toy and "Grow your own" screen saver, is software which allows you to experiment interactively with a wide variety of primitives and genetic operators. Doodle Garden is an MS Windows package which allows the user to evolve programs that draw pictures, or "doodles" by mutating and crossing other doodles. Doodle Garden is available from Creation Mechanics for $39.00. Creation Mechanics will provide a professional GP system called GP-GIM (Genetic Programming - Genetic Induction Machine). If you use the evaluation macros, GPQUICK problems should be source code compatible with GP-GIM problems. GP-GIM includes: * Built in Problems for regression, classification, and selection from data * Problems plug in at runtime as DLL's * Rich set of primitive functions, with many add in function packs * Numerous GA options, operators, and over 50 parameters * Meta-GA for automated primitive selection, parameter selection and generalization * Subroutine defining structures, constrained crossover, fixed roots * Interactive user interface * Runtime libraries for using and distributing the resulting code * High speed implementation * "Desktop Supercomputing" architecture linking a network of PC's or workstations into a parallel GP machine. Rack mounted clusters are also available. For more information, contact Creation Mechanics at the phone number and address listed on the top of this file.

近期下载者

相关文件


收藏者