25 #ifndef PAGMO_MIGRATION_HV_FAIR_R_POLICY_H
26 #define PAGMO_MIGRATION_HV_FAIR_R_POLICY_H
31 #include "../config.h"
32 #include "../population.h"
33 #include "../serialization.h"
35 #include "base_r_policy.h"
37 namespace pagmo {
namespace migration {
56 std::vector<std::pair<population::size_type,std::vector<population::individual_type>::size_type> >
57 select(
const std::vector<population::individual_type> &,
const population &)
const;
59 static bool ind_cmp(
const std::pair<unsigned int, double> &,
const std::pair<unsigned int, double> &);
60 static bool sort_point_pairs_asc(
const std::pair<unsigned int, double> &a,
const std::pair<unsigned int, double> &b);
61 const double m_nadir_eps;
63 friend class boost::serialization::access;
64 template <
class Archive>
65 void serialize(Archive &ar,
const unsigned int)
67 ar & boost::serialization::base_object<base_r_policy>(*this);
68 ar &
const_cast<double &
>(m_nadir_eps);
Base class for migration replacement policies.
boost::shared_ptr< base_r_policy > base_r_policy_ptr
Shared pointer to base replacement policy.
Replace the 'n' least contributors with the incoming set.
Migration rate is interpreted as the absolute number of individuals to migrate.
rate_type
Type of migration rate.