makefiles almost work
This commit is contained in:
parent
5fe7510807
commit
28219fcc12
5 changed files with 9 additions and 6 deletions
|
|
@ -4,11 +4,11 @@
|
||||||
##
|
##
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
|
||||||
SUBDIRS = es ga gp obsolete other utils
|
SUBDIRS = es ga gp obsolete utils # other
|
||||||
|
|
||||||
lib_LIBRARIES = libeo.a
|
lib_LIBRARIES = libeo.a
|
||||||
libeo_a_SOURCES = eoPrintable.o eoPersistent.o
|
libeo_a_SOURCES = eoPrintable.cpp eoPersistent.cpp
|
||||||
#libeo_a_LIBADD = libeoutils.a
|
libeo_a_LIBADD = obsolete/eoParserUtils.o utils/eoParser.o utils/eoRNG.o utils/eoState.o
|
||||||
|
|
||||||
libeoincdir = $(includedir)/eo
|
libeoincdir = $(includedir)/eo
|
||||||
libeoinc_HEADERS = EO.h eoDup.h eoKill.h eoProportionalGOpSelector.h eoTournament.h eo1d.h eoEasyEA.h eoLottery.h eoProportionalOpSel.h eoTranspose.h eo1dWDistance.h eoEvalFunc.h eoMerge.h eoRandomBreed.h eoUniform.h eo2d.h eoEvalFuncPtr.h eoMutation.h eoRandomIndiSelector.h eoUniformSelect.h eo2dVector.h eoEvalFuncPtrCnt.h eoNegExp.h eoRandomSelect.h eoUniformXOver.h eoAlgo.h eoFactory.h eoNonUniform.h eoRank.h eoVector.h eoAtomBitFlip.h eoFitTerm.h eoNormal.h eoRnd.h eoWrappedOps.h eoAtomCreep.h eoFitness.h eoObject.h eoScalarFitness.h eoXOver2.h eoAtomMutation.h eoGOpBreeder.h eoOp.h eoScheme.h eoAtomMutator.h eoGOpSelector.h eoOpFactory.h eoSelectFactory.h eoBreeder.h eoID.h eoPersistent.h eoSteadyStateGeneration.h eoAtomRandom.h eoGenTerm.h eoOpSelMason.h eoSequentialGOpSelector.h eoBackInserter.h eoGeneration.h eoOpSelector.h eoSteadyStateEA.h eoDetTournament.h eoInclusion.h eoPop.h eoSteadyStateInserter.h eoDetTournamentIndiSelector.h eoIndiSelector.h eoPopOps.h eoStochTournament.h eoDetTournamentInserter.h eoInserter.h eoPrintable.h eoStochTournamentInserter.h eoDistance.h eoInsertion.h eoProportionalGOpSel.h eoTerm.h \
|
libeoinc_HEADERS = EO.h eoDup.h eoKill.h eoProportionalGOpSelector.h eoTournament.h eo1d.h eoEasyEA.h eoLottery.h eoProportionalOpSel.h eoTranspose.h eo1dWDistance.h eoEvalFunc.h eoMerge.h eoRandomBreed.h eoUniform.h eo2d.h eoEvalFuncPtr.h eoMutation.h eoRandomIndiSelector.h eoUniformSelect.h eo2dVector.h eoEvalFuncPtrCnt.h eoNegExp.h eoRandomSelect.h eoUniformXOver.h eoAlgo.h eoFactory.h eoNonUniform.h eoRank.h eoVector.h eoAtomBitFlip.h eoFitTerm.h eoNormal.h eoRnd.h eoWrappedOps.h eoAtomCreep.h eoFitness.h eoObject.h eoScalarFitness.h eoXOver2.h eoAtomMutation.h eoGOpBreeder.h eoOp.h eoScheme.h eoAtomMutator.h eoGOpSelector.h eoOpFactory.h eoSelectFactory.h eoBreeder.h eoID.h eoPersistent.h eoSteadyStateGeneration.h eoAtomRandom.h eoGenTerm.h eoOpSelMason.h eoSequentialGOpSelector.h eoBackInserter.h eoGeneration.h eoOpSelector.h eoSteadyStateEA.h eoDetTournament.h eoInclusion.h eoPop.h eoSteadyStateInserter.h eoDetTournamentIndiSelector.h eoIndiSelector.h eoPopOps.h eoStochTournament.h eoDetTournamentInserter.h eoInserter.h eoPrintable.h eoStochTournamentInserter.h eoDistance.h eoInsertion.h eoProportionalGOpSel.h eoTerm.h \
|
||||||
|
|
|
||||||
|
|
@ -92,7 +92,8 @@ class eoBinPopOp: public eoObject{
|
||||||
@param _parents the initial generation. Will be kept constant
|
@param _parents the initial generation. Will be kept constant
|
||||||
@param _siblings the created offspring. Will be usually an empty population
|
@param _siblings the created offspring. Will be usually an empty population
|
||||||
*/
|
*/
|
||||||
virtual void operator () ( eoPop<EOT>& _parents, eoPop<EOT>& _siblings ) = 0;
|
virtual void operator () (const eoPop<EOT>& _parents,
|
||||||
|
eoPop<EOT>& _siblings ) = 0;
|
||||||
|
|
||||||
/** @name Methods from eoObject */
|
/** @name Methods from eoObject */
|
||||||
//@{
|
//@{
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,7 @@
|
||||||
#ifndef eoExternalEO_h
|
#ifndef eoExternalEO_h
|
||||||
#define eoExternalEO_h
|
#define eoExternalEO_h
|
||||||
|
|
||||||
#include <EO.h>
|
#include <EO.h> // EO
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Definition of an object that allows an external struct
|
* Definition of an object that allows an external struct
|
||||||
|
|
|
||||||
|
|
@ -37,6 +37,7 @@ main()
|
||||||
}
|
}
|
||||||
|
|
||||||
cout << "original population:" << endl;
|
cout << "original population:" << endl;
|
||||||
|
sort(pop.begin(), pop.end());
|
||||||
for (i = 0; i < pop.size(); i++)
|
for (i = 0; i < pop.size(); i++)
|
||||||
cout << pop[i] << " " << pop[i].fitness() << endl;
|
cout << pop[i] << " " << pop[i].fitness() << endl;
|
||||||
|
|
||||||
|
|
@ -44,6 +45,7 @@ main()
|
||||||
lottery(pop, pop2);
|
lottery(pop, pop2);
|
||||||
|
|
||||||
cout << "selected by lottery population:" << endl;
|
cout << "selected by lottery population:" << endl;
|
||||||
|
sort(pop2.begin(), pop2.end());
|
||||||
for (i = 0; i < pop2.size(); i++)
|
for (i = 0; i < pop2.size(); i++)
|
||||||
cout << pop2[i] << " " << pop2[i].fitness() << endl;
|
cout << pop2[i] << " " << pop2[i].fitness() << endl;
|
||||||
|
|
||||||
|
|
|
||||||
Reference in a new issue