亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? nsga2.c

?? 在c語言中實現的多目標優化
?? C
?? 第 1 頁 / 共 2 頁
字號:
/* This is a Multi-Objective GA program.***********************************************************************  This program is the implementation of the NSGA-2 proposed by      **                                                                    **  Prof. Kalyanmoy Deb and his students .                            **                                                                    **  copyright Kalyanmoy Deb**********************************************************************The user have to give the input manualy or through a data file.The user needs to enter objective functions in func-con.hThe code can also take care of the constraints. Enter the constraintsin the space provided in the func-con.h file.Constraints must be of the following type:g(x) >= 0.0Also normalize all constraints (see the example problem in func-con.h)If your program asks you to increase the values of some parameters in theprogram come to main program and accordingly changed the values which aredefined against #define ...The program generates few output files. These are described as1.output.out*           This file has the detailed record for all the variables,*           the fitness values, constraint values, overall constraint            violation (penalty)  and their ranks for all the members*           of old population in the left hand side of the |**|*           and of new population in the right hand side.2.all_fitness.out*         This file prints the record of all the fitness values for*         different individual of new popultion created at all*         generations.3.g_rank_record.out*        This file maintains the record of individuals in global pop-*        -ulation at different ranks for all the generations.4.ranks.out*         This file prints the number of individual at different ranks*          in old and new population and finds rank ratios5.final_fitness.out*                 This file has the fitness value of all feasible and                  non-dominated individuals at the final generation6.final_var.out*                 This file has the all the variables of the feasible                  and non-dominated individuals at the final generation.                  The i-th solutions here corresponds to the i-th solution                  in the final_fitness.out file. 7.plot.out        This file contains gnuplot-based file for plotting                  the non-dominated feasible solutions obtained by the code.**************************************************************************         This is recommended to delete or rename all the *.out files*         obtained from the previous runs as some files are opened in*         append mode so they give false resemblence of data if the*         user is not carefulCompilation procedure:  gcc nsga2.c -lmRun ./a.out with or without an input fileInput data files: Three files are included, but at one time one is neededdepending on the type of variables used:inp-r (template file input-real)  : All variables are real-codedinp-b (template file input-binary): All variables are binary-codedinp-rb(template file input-rl+bin): Some variables are real and some are binary  */#include <stdio.h>#include <stdlib.h>#include <math.h>#define square(x) ((x)*(x))#define maxpop   500  /*Max population */#define maxchrom 200  /*Max chromosome length*/#define maxvar    20  /*Max no. of variables*/#define maxfun    10  /*Max no. of functions */#define maxcons   20  /*Max no. of Constraints*/int gener,       /*No of generations*/  nvar,nchrom,          /*No of variables*/  ncons,         /*No of Constraints*/  vlen[maxvar],  /*Array to store no of bits for each variable*/  nmut,          /* No of Mutations */  ncross,        /*No of crossovers*/  ans;float seed,      /*Random Seed*/  pcross,        /*Cross-over Probability*/  pmut_b, pmut_r,          /*Mutation Probability*/  lim_b[maxvar][2], lim_r[maxvar][2];/*Limits of variable in array*/float di,        /*Distribution Index for the Cross-over*/  dim,           /*Distribution Index for the Mutation*/  delta_fit,     /* variables required forfitness for fitness sharing */  min_fit,  front_ratio;int optype,      /*Cross-over type*/  nfunc,         /*No of functions*/  sharespace;    /*Sharing space (either parameter or fitness)*/double coef[maxvar]; /*Variable used for decoding*/static int popsize,  /*Population Size*/  chrom;             /*Chromosome size*/typedef struct       /*individual properties*/{  int genes[maxchrom], /*bianry chromosome*/    rank,              /*Rank of the individual*/    flag;              /*Flag for ranking*/  float xreal[maxvar], /*list of real variables*/    xbin[maxvar];      /*list of decoded value of the chromosome */  float fitness[maxfun],/*Fitness values */    constr[maxcons],     /*Constraints values*/    cub_len,             /*crowding distance of the individual*/    error;              /* overall constraint violation for the individual*/}individual;        /*Structure defining individual*/typedef struct{  int maxrank;            /*Maximum rank present in the population*/  float rankrat[maxpop];  /*Rank Ratio*/  int rankno[maxpop];     /*Individual at different ranks*/  individual ind[maxpop], /*Different Individuals*/    *ind_ptr; }population ;             /*Popuation Structure*/#include "random.h"       /*Random Number Generator*/#include "input.h"        /*File Takes Input from user*/#include "realinit.h"     /*Random Initialization of the populaiton*/#include "init.h"         /*Random Initialization of the population*/#include "decode.h"       /*File decoding the binary dtrings*/#include "ranking.h"      /*File Creating the Pareto Fronts*/#include "rancon.h"       /*File Creating the Pareto Fronts when			    Constraints are specified*/#include "dfit.h"         /*File Assigning Dummyfitness*/#include "func-con.h"     /*File Having the Function*/#include "select.h"       /*File for Tournament Selection*/#include "crossover.h"    /*Binary Cross-over*/#include "uniformxr.h"    /*Uniform Cross-over*/#include "realcross2.h"   /*Real Cross-over*/#include "mut.h"          /*Binary Mutation*/#include "realmut1.h"     /*Real Mutation*/#include "keepaliven.h"   /*File For Elitism and Sharing Scheme*/#include "report.h"       /*Printing the report*/population oldpop,  newpop,  matepop,  *old_pop_ptr,  *new_pop_ptr,  *mate_pop_ptr;/*Defining the population Structures*/main(){  /*Some Local variables to this Problem (Counters And some other pointers*/  int i,j,l,f,maxrank1;  float *ptr,tot;  FILE     *rep_ptr,    *gen_ptr,    *rep2_ptr,    *end_ptr,    *g_var,    *lastit;  /*File Pointers*/  rep_ptr = fopen("output.out","w");  gen_ptr =fopen("all_fitness.out","w");  rep2_ptr = fopen("ranks.out","w");  end_ptr = fopen("final_fitness.out","w");  g_var = fopen("final_var.out","w");  lastit = fopen("plot.out","w");  /*Opening the files*/  old_pop_ptr = &(oldpop);  nmut = 0;  ncross = 0;  /*Get the input from the file input.h*/  input(rep_ptr);  fprintf(rep_ptr,"Results in a file\n");  fprintf(end_ptr,"# Last generation population (Feasible and non-dominated)\n");  fprintf(end_ptr,"# Fitness_vector (first %d)  Constraint_violation (next %d)  Overall_penalty\n",nfunc,ncons);  fprintf(g_var,"#Feasible Variable_vectors for non-dominated solutions at last generation\n");  fprintf(g_var,"# Real (first %d)  Binary (next %d)\n",nvar,nchrom);  fprintf(lastit,"# Feasible and Non-dominated Objective Vector\n");  /*Initialize the random no generator*/  warmup_random(seed);   /*Binary Initializaton*/  if (nchrom > 0)    init(old_pop_ptr);    if (nvar > 0)    realinit(old_pop_ptr);    old_pop_ptr = &(oldpop);  // decode binary strings  decode(old_pop_ptr);   old_pop_ptr = &(oldpop);  new_pop_ptr = &(newpop);    for(j = 0;j < popsize;j++)    {      /*Initializing the Rank array having different individuals	at a particular  rank to zero*/       old_pop_ptr->rankno[j] = 0;       new_pop_ptr->rankno[j] = 0;    }    old_pop_ptr = &(oldpop);    func(old_pop_ptr);   /*Function Calculaiton*/    fprintf(rep_ptr,"----------------------------------------------------\n");

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产女同性恋一区二区| 国产乱码精品一区二区三区五月婷 | 色综合天天综合网天天狠天天| 国产日韩欧美精品一区| 成人免费的视频| 中文字幕一区不卡| 在线影视一区二区三区| 亚洲国产精品久久久久秋霞影院| 欧美亚洲一区二区在线| 日本成人在线网站| 久久久夜色精品亚洲| 不卡视频免费播放| 无码av免费一区二区三区试看| 欧美变态tickling挠脚心| 国产91在线观看丝袜| 一区二区三区日韩欧美| 91精品国产入口| 六月丁香婷婷色狠狠久久| 国产日韩欧美制服另类| 在线亚洲高清视频| 精品伊人久久久久7777人| 中文字幕va一区二区三区| 色狠狠色噜噜噜综合网| 免费一级片91| 1区2区3区欧美| 911国产精品| 成人99免费视频| 日韩精彩视频在线观看| 欧美激情一区二区三区不卡| 欧美午夜免费电影| 国产精品1区2区3区| 亚洲自拍偷拍九九九| 精品国产一区二区在线观看| 99久久er热在这里只有精品66| 亚瑟在线精品视频| 欧美国产精品一区二区| 欧美福利视频导航| 成人午夜免费视频| 蜜臀精品一区二区三区在线观看 | 粉嫩欧美一区二区三区高清影视| 亚洲欧美精品午睡沙发| 欧美成人video| www.欧美.com| 精品一区二区三区不卡| 亚洲男人的天堂网| 久久综合色8888| 欧洲在线/亚洲| 粉嫩久久99精品久久久久久夜| 午夜精品一区二区三区电影天堂| 日本一区二区三区在线观看| 56国语精品自产拍在线观看| 99re视频精品| 国产成a人亚洲精品| 麻豆国产精品视频| 亚洲国产一区二区三区| 国产精品久久精品日日| 欧美不卡视频一区| 欧美日韩夫妻久久| 色一情一伦一子一伦一区| 国产在线看一区| 蜜臀a∨国产成人精品| 亚洲综合免费观看高清完整版| 欧美高清在线一区| 国产日韩欧美一区二区三区综合| 日韩午夜在线播放| 91.xcao| 欧美色欧美亚洲另类二区| 99国产精品99久久久久久| 国产成人av一区| 国产超碰在线一区| 狠狠色综合日日| 精品一区二区三区的国产在线播放 | 国产精品视频免费看| www国产成人| 精品国产一区二区三区四区四| 欧美一区二区视频在线观看2020| 91福利国产成人精品照片| 波多野结衣的一区二区三区| 国产福利91精品| 成人精品国产一区二区4080| 高清久久久久久| 国产精华液一区二区三区| 国产一区三区三区| 国产精品一二三区| 国产东北露脸精品视频| 国产成人99久久亚洲综合精品| 精品亚洲porn| 国产精品综合在线视频| 国产成人免费av在线| 成人永久看片免费视频天堂| 成人丝袜视频网| 91亚洲午夜精品久久久久久| 欧美在线一区二区三区| 欧美日韩在线电影| 欧美成人一区二区三区片免费 | 94-欧美-setu| 欧美日韩在线播放三区四区| 欧美精品三级日韩久久| 精品少妇一区二区三区在线视频| 久久久影视传媒| 日韩一区欧美一区| 亚洲午夜羞羞片| 久久国产精品第一页| 国产99久久久久久免费看农村| 99re在线精品| 91精品国产一区二区三区香蕉 | 成人毛片视频在线观看| 色美美综合视频| 欧美久久久久中文字幕| 精品国产在天天线2019| 亚洲色图清纯唯美| 日韩高清在线不卡| 成人一区二区三区在线观看| 色哟哟精品一区| 精品日韩在线观看| 最新日韩av在线| 麻豆精品视频在线观看免费| 不卡的av网站| 精品日本一线二线三线不卡| 综合久久国产九一剧情麻豆| 日韩二区三区在线观看| 成人av网址在线| 欧美电影免费观看高清完整版在线 | 一区二区在线观看免费| 强制捆绑调教一区二区| 福利视频网站一区二区三区| 欧美亚洲自拍偷拍| 中文字幕+乱码+中文字幕一区| 丝袜美腿亚洲综合| 成人av动漫网站| 久久综合给合久久狠狠狠97色69| 亚洲黄一区二区三区| 国产精品一区二区三区99| 欧美色图在线观看| 国产精品网站在线观看| 奇米精品一区二区三区在线观看| 成人久久久精品乱码一区二区三区| 91精品午夜视频| 亚洲一区二区在线免费看| 国产成人综合精品三级| 91精品国产91久久综合桃花 | 国产日韩欧美精品电影三级在线| 天堂久久久久va久久久久| 99精品国产热久久91蜜凸| 精品福利二区三区| 日韩精品欧美精品| 91成人免费在线| 亚洲色图另类专区| 国产精品一区不卡| 日韩欧美成人激情| 欧美a一区二区| 91精品国产高清一区二区三区蜜臀| 亚洲精品久久久蜜桃| hitomi一区二区三区精品| 国产欧美一区二区在线观看| 裸体在线国模精品偷拍| 91精品中文字幕一区二区三区| 亚洲国产综合91精品麻豆| 一本一本大道香蕉久在线精品| 国产精品日韩精品欧美在线| 粉嫩av一区二区三区在线播放| 欧美一区二区三区在| 日韩va欧美va亚洲va久久| 在线播放91灌醉迷j高跟美女 | 91精品免费在线观看| 午夜精品视频在线观看| 欧美高清精品3d| 美女国产一区二区三区| 日韩一区二区三区免费看| 美女视频黄 久久| 久久综合久久综合九色| 九九**精品视频免费播放| 欧美成人免费网站| 狠狠狠色丁香婷婷综合激情| 久久久久久麻豆| 成人av在线一区二区| 亚洲免费在线电影| 欧美无砖专区一中文字| 五月天亚洲婷婷| 欧美变态口味重另类| 国产精品一区二区久久精品爱涩| 国产欧美1区2区3区| 色婷婷激情综合| 日韩极品在线观看| 久久久99精品免费观看| 成人h动漫精品一区二| 亚洲综合激情另类小说区| 在线综合视频播放| 国产成人免费9x9x人网站视频| 国产精品第四页| 欧美体内she精视频| 青青草国产精品97视觉盛宴| 久久久精品黄色| 91美女在线看| 日本成人在线不卡视频| 久久久久久久久99精品| 日本韩国精品在线| 日韩成人免费电影| 国产日韩影视精品| 精品视频一区三区九区|