22 #ifndef __SAMPLE_INDIVIDUAL_H__
23 #define __SAMPLE_INDIVIDUAL_H__
35 #include "boost/smart_ptr.hpp"
54 genes.resize(names.size(), 0.0);
58 template<
class Archive>
77 "Variable '" +
name +
"' not contained.");
87 void print(std::ostream &out)
const {
89 for (
unsigned int i = 0; i <
genes.size(); ++ i) {
PartBunchBase< T, Dim >::ConstIterator end(PartBunchBase< T, Dim > const &bunch)
PartBunchBase< T, Dim >::ConstIterator begin(PartBunchBase< T, Dim > const &bunch)
std::ostream & operator<<(std::ostream &out, const SampleIndividual &ind)
Inform & endl(Inform &inf)
const T * find(const T table[], const std::string &name)
Look up name.
std::vector< std::string > names_t
gene names
genes_t genes
genes of an individual
names_t names_m
gene names
std::vector< double > objectives_t
objectives array
SampleIndividual(names_t names)
int getIndex(std::string name)
std::vector< double > genes_t
representation of genes
void serialize(Archive &ar, const unsigned int)
serialization of structure
objectives_t objectives
values of objectives of an individual
std::string getName(size_t i)
void print(std::ostream &out) const
The base class for all OPAL exceptions.