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

? 歡迎來(lái)到蟲(chóng)蟲(chóng)下載站! | ?? 資源下載 ?? 資源專(zhuān)輯 ?? 關(guān)于我們
? 蟲(chóng)蟲(chóng)下載站

?? rep.cc

?? c++編寫(xiě)的并行拉馬克遺傳算法的程序。實(shí)現(xiàn)分析對(duì)接程序
?? CC
?? 第 1 頁(yè) / 共 2 頁(yè)
字號(hào):
/* rep.cc *//********************************************************************     The methods associated with the Representation class hierarchy.				rsh 9/95********************************************************************/#include <iostream.h>#include <stdio.h>#include <math.h>#include <limits.h>#include "rep.h"#include "ranlib.h"#include "structs.h"extern FILE *logFile;//  InitializationsFourByteLong IntVector::low = -INT_MAX/4;FourByteLong IntVector::high = INT_MAX/4;//float RealVector::low = -100.0;//float RealVector::high = 100.0;//  For now assume that normalize handles this constraint//float ConstrainedRealVector::low = -100.0;//float ConstrainedRealVector::high = 100.0;//float RealVector::low = -PI;//float RealVector::high = PI;float ConstrainedRealVector::low = -PI;float ConstrainedRealVector::high = PI;double ConstrainedRealVector::sum = 1.0;float BitVector::one_prob = 0.5;//  The member functions for the canonical base classes//  This constructor is used to generate the initial (random) instances//  of an integer vector.IntVector::IntVector(int number_of_els): Representation(number_of_els){   register int i;#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/IntVector::IntVector(int number_of_els=%d) \n",number_of_els);#endif /* DEBUG */   mytype = T_IntV;   vector = new FourByteLong[number_of_els];   for (i=0; i<number_of_els; i++) {      vector[i] = ignuin(low, high);   }}IntVector::IntVector(int num_els, FourByteLong init_low, FourByteLong init_high): Representation(num_els){   register int i;#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/IntVector::IntVector(int num_els=%d, FourByteLong init_low=%ld, FourByteLong init_high=%ld) \n",num_els,init_low,init_high);#endif /* DEBUG */   mytype = T_IntV;   vector = new FourByteLong[num_els];   for (i=0; i<num_els; i++) {      vector[i] = ignuin(init_low, init_high);   }}//  This constructor does an actual copy of the vector.//  We could make gains by doing reference counting, but//  that's for the future.IntVector::IntVector(const IntVector &original): Representation(original.number_of_pts){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/IntVector::IntVector(const IntVector &original) \n");#endif /* DEBUG */   mytype = T_IntV;   if (original.vector!=NULL) { vector = new FourByteLong[number_of_pts];   } else {      vector = NULL;   }   for (register int i=0; i<number_of_pts; i++) {      vector[i] = original.vector[i];   }}void IntVector::write(unsigned char value, int gene){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/void IntVector::write(unsigned char value=%c, int gene=%d) \n",value,gene);#endif /* DEBUG */   (void)fprintf(logFile,"Writing a Bit to an Int!\n"); // used to be "stderr"   (void)fprintf(logFile,"value= \"%c\", gene= %d\n", value, gene); // used to be "stderr"}void IntVector::write(FourByteLong value, int gene){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/void IntVector::write(FourByteLong value=%ld, int gene=%d)` \n",value,gene);#endif /* DEBUG */   if (value<low) {      vector[gene] = low;   } else if (value>high) {      vector[gene] = high;   } else {      vector[gene] = value;   }}void IntVector::write(double value, int gene){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/void IntVector::write(double value=%lf, int gene=%d) \n",value,gene);#endif /* DEBUG */   (void)fprintf(logFile,"Writing a Real to an Int!\n"); // used to be "stderr"   (void)fprintf(logFile,"value= %lf, gene= %d\n", value, gene); // used to be "stderr"}/*void IntVector::write(const void *value, int gene){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/void IntVector::write(const void *value, int gene=%d) \n",gene);#endif // * DEBUG * /   if (*((FourByteLong *)value)<low) {      (void)fprintf(logFile,"Writing out-of-bounds Int!\n"); // used to be "stderr"      vector[gene] = low;   } else if (*((FourByteLong *)value)>high) {      (void)fprintf(logFile,"Writing out-of-bounds Int!\n"); // used to be "stderr"      vector[gene] = high;   } else {      vector[gene] = *((FourByteLong *)value);   }}*/void IntVector::write(const Element value, int gene){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/void IntVector::write(const Element value, int gene=%d) \n",gene);#endif /* DEBUG */   if (value.integer<low) {      (void)fprintf(logFile,"Writing out-of-bounds Int!\n"); // used to be "stderr"      vector[gene] = low;   } else if (value.integer>high) {      (void)fprintf(logFile,"Writing out-of-bounds Int!\n"); // used to be "stderr"      vector[gene] = high;   } else {      vector[gene] = value.integer;   }}/*const void *IntVector::gene(unsigned int gene_number) const{#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/const void *IntVector::gene(unsigned int gene_number=%d) const \n",gene_number);#endif // * DEBUG * /   if (gene_number>=number_of_pts) {      (void)fprintf(logFile,"Trying to access an out-of-bounds gene!\n"); // used to be "stderr"      return(NULL);   } else {      return((void *)(&vector[gene_number]));   }}*/const Element IntVector::gene(unsigned int gene_number) const{   Element retval;#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/const Element IntVector::gene(unsigned int gene_number=%d) const \n",gene_number);#endif /* DEBUG */   if (gene_number>=number_of_pts) {      (void)fprintf(logFile,"Trying to access an out-of-bounds gene!\n"); // used to be "stderr"      retval.integer = 0;      return(retval);   } else {      retval.integer = vector[gene_number];      return(retval);  // typecast int as Element   }}const void *IntVector::internals(void) const{#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/const void *IntVector::internals(void) const \n");#endif /* DEBUG */   return((void *)(&vector[0]));}Representation &IntVector::operator=(const Representation &original){   register int i;   FourByteLong *array;#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/Representation &IntVector::operator=(const Representation &original) \n");#endif /* DEBUG */   array = (FourByteLong *)original.internals();   if (original.type()==T_IntV) {      number_of_pts = original.number_of_points();      if (vector!=NULL) {         delete [] vector;      }      if (array!=NULL) {         vector = new FourByteLong[number_of_pts];      } else {         vector = NULL;      }      for (i=0; i<number_of_pts; i++) {         vector[i] = array[i];      }   } else {      (void)fprintf(logFile,"Unable to invoke operator= because Representations don't match!\n"); // used to be "stderr"   }   return(*this);}//  This is the constructor used to initialize the (random)//  starting population.RealVector::RealVector(int num_els): Representation(num_els){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/RealVector::RealVector(int num_els=%d) \n",num_els);#endif /* DEBUG */   mytype = T_RealV;   low = REALV_LOW;   high = REALV_HIGH;   vector = new double[num_els];   for (; --num_els>=0;) {      vector[num_els] = double(genunf(low, high));   }}RealVector::RealVector(int num_els, double init_low, double init_high): Representation(num_els){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/RealVector::RealVector(int num_els=%d, double init_low=%lf, double init_high=%lf) \n",num_els,init_low,init_high);#endif /* DEBUG */   mytype = T_RealV;   low = init_low;   high = init_high;   vector = new double[num_els];   for (; --num_els>=0;) {      vector[num_els] = double(genunf(init_low, init_high));   }}//  Do a deep copy of the originalRealVector::RealVector(const RealVector &original): Representation(original.number_of_pts){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/RealVector::RealVector(const RealVector &original) \n");#endif /* DEBUG */   mytype = T_RealV;   low =  original.low;   high = original.high;   if (original.vector!=NULL) {      vector = new double[original.number_of_pts];   } else {      vector = NULL;   }   for (register int i=0; i<original.number_of_pts; i++) {      vector[i] = original.vector[i];#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/i=%d, original.number_of_pts=%d, vector[%d]= %.3f\n",i, original.number_of_pts, i, vector[i]);#endif /* DEBUG */   }}void RealVector::write(unsigned char value, int gene){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/void RealVector::write(unsigned char value=%c, int gene=%d) \n",value,gene);#endif /* DEBUG */   (void)fprintf(logFile,"Writing a Bit to a Real!\n"); // used to be "stderr"   (void)fprintf(logFile,"value= \"%c\", gene= %d\n", value, gene); // used to be "stderr"}void RealVector::write(FourByteLong value, int gene){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/void RealVector::write(FourByteLong value=%ld, int gene=%d) \n",value,gene);#endif /* DEBUG */   (void)fprintf(logFile,"Writing an Int to a Real!\n"); // used to be "stderr"   (void)fprintf(logFile,"value= %ld, gene= %d\n", value, gene); // used to be "stderr"}void RealVector::write(double value, int gene){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/void RealVector::write(double value=%lf, int gene=%d) \n",value,gene);#endif /* DEBUG */   if (value<low) {//      (void)fprintf(logFile,"Writing out of bounds Real!  value (%lf) too low (%lf)\n",value,low); // used to be "stderr"      vector[gene] = low;   } else if (value>high) {//      (void)fprintf(logFile,"Writing out of bounds Real!  value (%lf) too high (%lf)\n",value,high); // used to be "stderr"      vector[gene] = high;   } else {      vector[gene] = value;   }}/*void RealVector::write(const void *value, int gene){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/void RealVector::write(const void *value, int gene=%d) \n",gene);#endif // * DEBUG * /   if (*((double *)value)<low) {      vector[gene] = low;   } else if (*((double *)value)>high) {      vector[gene] = high;   } else {      vector[gene] = *((double *)value);   }}*/void RealVector::write(const Element value, int gene){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/void RealVector::write(const Element value, int gene=%d) \n",gene);#endif /* DEBUG */   if (value.real<low) {      vector[gene] = low;   } else if (value.real>high) {      vector[gene] = high;   } else {      vector[gene] = value.real;   }}/* *const void *RealVector::gene(unsigned int gene_number) const *{ * *#ifdef DEBUG     *(void)fprintf(logFile, "rep.cc/const void *RealVector::gene(unsigned int gene_number=%d) const \n",gene_number); *#endif // * DEBUG * / *    *if (gene_number>=number_of_pts) {       *(void)fprintf(logFile,"Trying to access out-of-bounds gene\n"); // used to be "stderr"       *return(NULL);    *} else {       *return((void *)(&vector[gene_number]));    *} *} */const Element RealVector::gene(unsigned int gene_number) const{#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/const Element RealVector::gene(unsigned int gene_number=%d) const \n",gene_number);#endif /* DEBUG */   Element retval;   if (gene_number>=number_of_pts) {      //(void)fprintf(logFile,"Trying to access out-of-bounds gene\n"); // used to be "stderr"      (void)fprintf(logFile,"Trying to access out-of-bounds gene:%d,%d\n",gene_number,number_of_pts);      retval.real = 0.0;      return(retval);   } else {      retval.real = vector[gene_number];      return(retval);   }}const void *RealVector::internals(void) const{#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/const void *RealVector::internals(void) const \n");#endif /* DEBUG */   return((void *)(&vector[0]));}Representation &RealVector::operator=(const Representation &original){#ifdef DEBUG    (void)fprintf(logFile, "rep.cc/Representation &RealVector::operator=(const Representation &original) \n");#endif /* DEBUG */   register int i;   double *array;   if (original.type()==T_RealV) {      low = ((const RealVector &)original).low;      high = ((const RealVector &)original).high;      array = (double *)original.internals();      number_of_pts = original.number_of_points();      if (vector!=NULL) {         delete [] vector;      }      if (array!=NULL) {         vector = new double[number_of_pts];      } else {

?? 快捷鍵說(shuō)明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产一区二区在线免费观看| 粉嫩13p一区二区三区| 久久精品人人做人人综合| 91在线国内视频| 狠狠色综合色综合网络| 亚洲综合视频在线观看| 日本一区二区不卡视频| 欧美一区二区视频在线观看2022| 国产91对白在线观看九色| 日韩电影在线观看电影| 一区二区三区精品在线观看| 久久蜜桃av一区二区天堂| 666欧美在线视频| 色综合色狠狠天天综合色| 国产精品中文有码| 久久电影网站中文字幕| 午夜视黄欧洲亚洲| 亚洲乱码中文字幕| 中文字幕亚洲精品在线观看| 久久久久亚洲蜜桃| 欧美成人午夜电影| 欧美精品18+| 欧洲精品一区二区| 欧美性大战久久久| 色综合欧美在线视频区| 播五月开心婷婷综合| 国产成人免费av在线| 极品少妇xxxx精品少妇偷拍| 天天综合色天天| 午夜精品久久久久久久蜜桃app| 亚洲青青青在线视频| 国产精品二三区| 国产精品美女一区二区三区| 久久久精品一品道一区| 午夜欧美视频在线观看| 亚洲精品成人少妇| 最新日韩在线视频| 日韩美女精品在线| 亚洲男人天堂av| 一级女性全黄久久生活片免费| 亚洲天堂免费在线观看视频| ㊣最新国产の精品bt伙计久久| 国产精品成人网| 18成人在线视频| 亚洲另类中文字| 无码av中文一区二区三区桃花岛| 亚洲成在人线免费| 日本vs亚洲vs韩国一区三区二区| 日本vs亚洲vs韩国一区三区二区| 日韩电影一二三区| 韩国精品免费视频| 成人精品高清在线| 91免费在线播放| 欧美日韩你懂得| 日韩一级二级三级| 2020国产精品自拍| 国产精品久久久久7777按摩| 亚洲欧美一区二区三区孕妇| 一区二区三区电影在线播| 亚洲成在人线免费| 久久精品国产精品亚洲综合| 国产精品一区三区| 色哟哟国产精品| 制服丝袜中文字幕亚洲| 久久综合色播五月| 成人欧美一区二区三区黑人麻豆 | 一区二区成人在线观看| 亚洲午夜激情网页| 久久激情综合网| 成人性生交大片免费| 91福利社在线观看| 精品国产精品网麻豆系列| 国产精品久久久久久久久晋中| 亚洲欧美日韩综合aⅴ视频| 天天操天天干天天综合网| 激情深爱一区二区| 一本色道久久综合亚洲aⅴ蜜桃| 欧美日韩国产综合草草| 国产农村妇女毛片精品久久麻豆| 亚洲免费成人av| 久久国产精品色婷婷| 色综合久久综合网97色综合| 这里是久久伊人| 中文字幕欧美激情| 日韩经典中文字幕一区| 高清国产午夜精品久久久久久| 欧美午夜精品久久久久久孕妇 | 欧美福利一区二区| 国产精品污污网站在线观看| 亚洲成av人片一区二区三区| 国产老肥熟一区二区三区| 在线影院国内精品| 国产婷婷一区二区| 亚洲国产美国国产综合一区二区| 国产精品资源在线看| 欧美久久一二区| 综合久久给合久久狠狠狠97色| 美腿丝袜在线亚洲一区| 色悠悠久久综合| 国产偷国产偷亚洲高清人白洁| 午夜日韩在线电影| 91首页免费视频| 久久久久国产精品免费免费搜索| 亚洲国产毛片aaaaa无费看| 丁香六月综合激情| 精品国产免费久久 | 国产亚洲婷婷免费| 日本aⅴ精品一区二区三区| 91捆绑美女网站| 欧美激情一区三区| 国产在线精品视频| 欧美一区二区三区电影| 亚洲一区二区三区激情| 成人性生交大合| 国产欧美一区二区在线| 久久丁香综合五月国产三级网站 | 欧美一区二区三区色| 亚洲乱码精品一二三四区日韩在线| 国产精品一区二区在线观看网站| 欧美日韩视频专区在线播放| 亚洲精品一二三区| a级高清视频欧美日韩| 国产日产欧美精品一区二区三区| 蜜臀91精品一区二区三区| 欧美精品tushy高清| 亚洲成人免费视| 欧美日韩专区在线| 亚洲国产精品自拍| 欧美三级电影在线观看| 亚洲午夜电影网| 欧美色偷偷大香| 亚洲第一主播视频| 7777精品伊人久久久大香线蕉经典版下载 | 欧美精品三级日韩久久| 亚洲一区二区三区四区的| 91麻豆视频网站| 一区二区三区免费网站| 在线观看www91| 五月激情丁香一区二区三区| 欧美电影一区二区| 狂野欧美性猛交blacked| 欧美mv日韩mv国产网站| 国产呦精品一区二区三区网站| 精品播放一区二区| 粉嫩蜜臀av国产精品网站| 欧美国产乱子伦 | 日本成人在线网站| 欧美大片日本大片免费观看| 久久黄色级2电影| 久久精品网站免费观看| 成人av资源在线| 亚洲精品日日夜夜| 在线不卡免费欧美| 精品一区二区在线观看| 日本一区免费视频| 94-欧美-setu| 午夜欧美2019年伦理| 欧美mv日韩mv国产网站| 成人午夜免费av| 亚洲一区二区三区四区在线免费观看| 欧美日韩亚州综合| 久久成人免费电影| 国产精品久久久久影视| 欧美性猛交xxxx乱大交退制版| 男女激情视频一区| 中文字幕巨乱亚洲| 欧美午夜精品久久久久久孕妇 | 欧美精品123区| 国产精品一区二区在线观看网站| 中文字幕综合网| 欧美日韩色综合| 国产高清无密码一区二区三区| 综合久久国产九一剧情麻豆| 欧美日韩亚洲高清一区二区| 韩国v欧美v亚洲v日本v| 最近日韩中文字幕| 日韩一区二区三区视频| 成人黄页毛片网站| 成人av中文字幕| 亚洲狠狠爱一区二区三区| 久久午夜色播影院免费高清| 99re66热这里只有精品3直播| 偷拍日韩校园综合在线| 国产欧美一区二区精品性色 | 日本亚洲电影天堂| 国产精品日韩成人| 日韩午夜三级在线| 99久久婷婷国产| 久久国内精品视频| 一区二区三区中文在线| 欧美精品一区二区三区久久久| 一本久久综合亚洲鲁鲁五月天| 久久aⅴ国产欧美74aaa| 亚洲香肠在线观看| 日本一区二区成人在线| 日韩视频一区二区三区在线播放 | 欧美三级日本三级少妇99| 国产成人av自拍| 青草av.久久免费一区| 亚洲精品美腿丝袜|