Projet du cours MPRI 2.24.2 "Résolution de problèmes d'optimisation avec heuristiques de recherche" : https://wikimpri.dptinfo.ens-cachan.fr/doku.php?id=cours:c-2-24-2
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

crossover-rate.h 1.4KB

  1. #ifndef CROSSOVER-RATE_H_INCLUDED
  2. #define CROSSOVER-RATE_H_INCLUDED
  3. #include <vector>
  4. #include <fstream>
  5. #include "ParameterOptimizer.h"
  6. #include "GA.h"
  7. class CrossoverProbaFromLambdaOptimizer : public ParameterOptimizer {
  8. public:
  9. CrossoverProbaFromLambdaOptimizer(int nb_cases, int lda_initial, std::default_random_engine& randomizer) : ParameterOptimizer(randomizer), n{nb_cases}, lambda_initial{lda_initial} {};
  10. SearchHeuristic* get_context(unsigned int i, double parameter, std::default_random_engine& randomizer);
  11. std::string display_context(unsigned int num_context);
  12. std::string get_context_for_csvfile(unsigned int num_context);
  13. private:
  14. int n;
  15. int lambda_initial;
  16. };
  17. void script_crossover_proba_global_optim(std::default_random_engine& randomizer, std::string namefile="global-crossover-proba.csv", bool restart=false, unsigned int restart_n=5, unsigned int restart_lambda=2);
  18. double crossover_model_linearization(double x);
  19. void crossover_model_filtering(std::string input, std::string output, std::string modeling, int filtered_n, int filtered_lda);
  20. void crossover_model_optimization(std::string namefile="global-crossover-proba.csv");
  21. void crossover_model_validation(std::string namefile, double slope1, double intercept1, double slope2, double intercept2);
  22. double cr(int n, int lambda);
  23. #endif // CROSSOVER-RATE_H_INCLUDED