11 #include "aux_functions.h" 25 MPI_Comm_rank(MPI_COMM_WORLD, &
my_rank);
26 MPI_Comm_size(MPI_COMM_WORLD, &
nb_proc);
34 virtual void put_to_best() {};
49 void Init_previous(
double prev_dev,
double new_dev,
int psize,
double *prev_soln);
56 bool check_success(
int t,
double *current_fitarray,
double *memory_fitarray,
int data_size,
double t_goal,
bool *mem_ptype,
int *numvar,
int N_cut,
double *memory_forT);
59 double Final_select(
double *fit,
double *solution,
double *fitarray);
60 double avg_Final_select(
double* solution,
int repeat,
double *soln_fit,
double *fitarray);
62 void dev_gen(
double *dev_array,
double prev_dev,
double new_dev,
int cut_off);
106 void family_gen(
int* fam,
int p,
int fam_size);
128 inline void find_index(
int *prev,
int *forw,
int p);
129 inline int find_fitness(
int prev,
double prev_fit,
int forw,
double forw_fit,
int p,
double fit);
void write_param(double *param_array)
Definition: mpi_pso.cpp:10
void combination()
Definition: mpi_pso.cpp:178
void Best_fitness(int p)
Definition: mpi_optalg.cpp:80
void read_param(double *param_array)
Definition: mpi_pso.cpp:3
void Cont_fitness(int p)
Definition: mpi_optalg.cpp:64
virtual void write_param(double *param_array)
Definition: mpi_optalg.h:39
void find_global()
Definition: mpi_optalg.h:98
double Final_select(double *fit, double *solution, double *fitarray)
Definition: mpi_optalg.cpp:98
void fit_to_global()
Definition: mpi_optalg.h:124
virtual void read_param(double *param_array)
Definition: mpi_optalg.h:40
DE class contains the functions that are specific to this particular optimization algorithm.
Definition: mpi_optalg.h:88
void read_param(double *param_array)
Definition: mpi_de.cpp:14
int num
Definition: problem.h:39
Problem class contains the prototype of the functions in the optimization problem that OptAlg class n...
Definition: problem.h:9
bool success
Definition: mpi_optalg.h:67
int total_pop
Definition: mpi_optalg.h:80
void update_popfit()
Definition: mpi_optalg.cpp:89
int t
Definition: mpi_optalg.h:76
int find_max(double *fit)
Definition: mpi_optalg.cpp:288
int my_rank
Definition: mpi_optalg.h:81
PSO class contains the functions that are specific to this particular optimization algorithm.
Definition: mpi_optalg.h:113
void write_param(double *param_array)
Definition: mpi_de.cpp:9
void put_to_best()
Definition: mpi_pso.cpp:145
bool goal
Definition: mpi_optalg.h:78
Candidate class contains arrays to be used by optimization algorithm to store data of a solution cand...
Definition: candidate.h:11
int nb_proc
Definition: mpi_optalg.h:82
double avg_Final_select(double *solution, int repeat, double *soln_fit, double *fitarray)
Definition: mpi_optalg.cpp:190
Candidate * pop
Definition: mpi_optalg.h:77
int pop_size
Definition: mpi_optalg.h:74
int num_fit
Definition: mpi_optalg.h:72
void combination()
Definition: mpi_de.cpp:36
void Init_population(int psize)
Definition: mpi_optalg.cpp:5
virtual void find_global()
Definition: mpi_optalg.h:42
Problem * prob
Definition: mpi_optalg.h:42
void selection()
Definition: mpi_de.cpp:25
Rng * gaussian_rng
Definition: mpi_optalg.h:73
int num
Definition: mpi_optalg.h:71
virtual void combination()
Definition: mpi_optalg.h:36
virtual void selection()
Definition: mpi_optalg.h:38
bool policy_type
Definition: mpi_optalg.h:68
void Init_previous(double prev_dev, double new_dev, int psize, double *prev_soln)
Definition: mpi_optalg.cpp:31
bool check_success(int t, double *current_fitarray, double *memory_fitarray, int data_size, double t_goal, bool *mem_ptype, int *numvar, int N_cut, double *memory_forT)
Definition: mpi_optalg.cpp:316
void dev_gen(double *dev_array, double prev_dev, double new_dev, int cut_off)
Definition: mpi_optalg.cpp:341
int T
Definition: mpi_optalg.h:75
void find_global()
Definition: mpi_pso.cpp:17
void set_success(int iter, bool goal)
Definition: mpi_optalg.cpp:307
OptAlg class contains the functions that can be used to contruct an optimization algorithm in the mai...
Definition: mpi_optalg.h:17
void selection()
Definition: mpi_pso.cpp:165
void fit_to_global()
Definition: mpi_de.cpp:19
virtual void fit_to_global()
Definition: mpi_optalg.h:41