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

📄 make_genotype_es.cpp

📁 这是linux下的进化计算的源代码。 === === === === === === === === === === === ===== check latest news at http:
💻 CPP
字号:
/* (c) Maarten Keijzer, Marc Schoenauer and GeNeura Team, 2001This library is free software; you can redistribute it and/or modify it underthe terms of the GNU Lesser General Public License as published by the FreeSoftware Foundation; either version 2 of the License, or (at your option) anylater version.This library is distributed in the hope that it will be useful, but WITHOUT ANYWARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR APARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.You should have received a copy of the GNU Lesser General Public License alongwith this library; if not, write to the Free Software Foundation, Inc., 59Temple Place, Suite 330, Boston, MA 02111-1307 USAContact: http://eodev.sourceforge.net         todos@geneura.ugr.es, http://geneura.ugr.es         Marc.Schoenauer@polytechnique.fr         mkeijzer@dhi.dk*/#ifdef _MSC_VER// to avoid long name warnings#pragma warning(disable:4786)#endif/** Init functionsThis file contains ***INSTANCIATED DEFINITIONS*** of eoReal Init fnsIt should be included in the file that calls any of the correspondingfns Compiling this file allows one to generate part of the library(i.e. object files that you just need to link with your own main andfitness code).The corresponding ***INSTANCIATED DECLARATIONS*** are contained insrc/es/make_real.h while the TEMPLATIZED code is define inmake_genotype_real.hIt is instanciated in src/es/make_genotype_real.cpp - and incorporatedin the ga/libga.aIt returns an eoInit<EOT> that can later be used to initialize thepopulation (see make_pop.h).It uses a parser (to get user parameters) and a state (to store thememory) the last argument is to disambiguate the call upon differentinstanciations.WARNING: that last argument will generally be the result of callingthe default ctor of EOT, resulting in most cases in an EOT that is***not properly initialized****/// the templatized code (same for real and es here)#include <es/make_genotype_real.h>/// The following function merely call the templatized do_* functionseoRealInitBounded<eoEsSimple<double> >& make_genotype(eoParser& _parser,                                                      eoState& _state,                                                      eoEsSimple<double> _eo){    return do_make_genotype(_parser, _state, _eo);}eoRealInitBounded<eoEsSimple<eoMinimizingFitness> >& make_genotype(eoParser& _parser,                                                                   eoState& _state,                                                                   eoEsSimple<eoMinimizingFitness> _eo){    return do_make_genotype(_parser, _state, _eo);}eoRealInitBounded<eoEsStdev<double> >& make_genotype(eoParser& _parser,                                                     eoState& _state,                                                     eoEsStdev<double> _eo){    return do_make_genotype(_parser, _state, _eo);}eoRealInitBounded<eoEsStdev<eoMinimizingFitness> >& make_genotype(eoParser& _parser,                                                                  eoState& _state,                                                                  eoEsStdev<eoMinimizingFitness> _eo){    return do_make_genotype(_parser, _state, _eo);}eoRealInitBounded<eoEsFull<double> > & make_genotype(eoParser& _parser,                                                     eoState& _state,                                                     eoEsFull<double> _eo){    return do_make_genotype(_parser, _state, _eo);}eoRealInitBounded<eoEsFull<eoMinimizingFitness> >& make_genotype(eoParser& _parser,                                                                 eoState& _state,                                                                 eoEsFull<eoMinimizingFitness> _eo){    return do_make_genotype(_parser, _state, _eo);}// Local Variables:// coding: iso-8859-1// c-file-style: "Stroustrup"// comment-column: 35// fill-column: 80// End:

⌨️ 快捷键说明

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