PaGMO  1.1.5
Public Types | Public Member Functions | Protected Member Functions | Friends
pagmo::algorithm::inverover Class Reference

Inver-Over Algorithm (IO) More...

#include <inverover.h>

Inheritance diagram for pagmo::algorithm::inverover:
Inheritance graph
[legend]

Public Types

enum  initialization_type { random = 0, nn = 1 }
 

Public Member Functions

 inverover (int gen=10000, double ri=0.05, initialization_type ini_type=random)
 Constructor. More...
 
base_ptr clone () const
 Clone method.
 
void evolve (population &) const
 Evolve implementation. More...
 
std::string get_name () const
 Algorithm name.
 
- Public Member Functions inherited from pagmo::algorithm::base
 base ()
 Default constructor. More...
 
virtual ~base ()
 Trivial destructor. More...
 
std::string human_readable () const
 Return human readable representation of the algorithm. More...
 
void set_screen_output (const bool p)
 Setter-Getter for protected m_screen_output data. More...
 
bool get_screen_output () const
 Gets screen output. More...
 
void reset_rngs (const unsigned int) const
 Resets the seed of the internal rngs using a user-provided seed. More...
 

Protected Member Functions

std::string human_readable_extra () const
 Extra human readable algorithm info. More...
 

Friends

class boost::serialization::access
 

Additional Inherited Members

- Protected Attributes inherited from pagmo::algorithm::base
bool m_screen_output
 Indicates to the derived class whether to print stuff on screen.
 
rng_double m_drng
 Random number generator for double-precision floating point values.
 
rng_uint32 m_urng
 Random number generator for unsigned integer values.
 
unsigned int m_fevals
 A counter for the number of function evaluations.
 

Detailed Description

Inver-Over Algorithm (IO)

The Inver-Over algorithm is a state-of-the-art genetic algorithm for the Travelling Salesman Problem. It was designed by G. Tao and Z. Michalewicz in 1998.

Note: The algorithm was sightly changed (choice of the next city in a series of inverisons) since with this choice better performance (tour length, computational time) was observed.

Note2: The value for the population size is advised to be no smaller than 20. To not have premature convergence, values around 100 are observed to work well.

Note3: The inversion sequence for cases where city1 is later in the tour than city2 is chosen as in the original paper (city1 -> city2). Some papers invert the complementary part of the tour (city2 -> city1).

Author
Ingmar Getzner (ingma.nosp@m.r.ge.nosp@m.tzner.nosp@m.@gma.nosp@m.il.co.nosp@m.m)

Definition at line 55 of file inverover.h.

Constructor & Destructor Documentation

pagmo::algorithm::inverover::inverover ( int  gen = 10000,
double  ri = 0.05,
initialization_type  ini_type = random 
)

Constructor.

Allows to specify in detail all the parameters of the algorithm.

Parameters
[in]genNumber of generations to evolve.
[in]riProbability of performing a random invert (mutation probability)

Definition at line 49 of file inverover.cpp.

Member Function Documentation

void pagmo::algorithm::inverover::evolve ( population pop) const
virtual

Evolve implementation.

Runs the Inverover algorithm for the number of generations specified in the constructor.

Parameters
[in,out]popinput/output pagmo::population to be evolved.

Implements pagmo::algorithm::base.

Definition at line 74 of file inverover.cpp.

std::string pagmo::algorithm::inverover::human_readable_extra ( ) const
protectedvirtual

Extra human readable algorithm info.

Returns
a formatted string displaying the parameters of the algorithm.

Reimplemented from pagmo::algorithm::base.

Definition at line 291 of file inverover.cpp.


The documentation for this class was generated from the following files: