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

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

?? setup.c

?? 《遺傳算法——理論、應用與軟件實現》王小平曹立明著一書的參考光盤.rar
?? C
字號:
/*
SGPC: Simple Genetic Programming in C
(c) 1993 by Walter Alden Tackett and Aviram Carmi
 
 This code and documentation is copyrighted and is not in the public domain.
 All rights reserved. 
 
 - This notice may not be removed or altered.
 
 - You may not try to make money by distributing the package or by using the
   process that the code creates.
 
 - You may not distribute modified versions without clearly documenting your
   changes and notifying the principal author.
 
 - The origin of this software must not be misrepresented, either by
   explicit claim or by omission.  Since few users ever read sources,
   credits must appear in the documentation.
 
 - Altered versions must be plainly marked as such, and must not be
   misrepresented as being the original software.  Since few users ever read
   sources, credits must appear in the documentation.
 
 - The authors are not responsible for the consequences of use of this 
   software, no matter how awful, even if they arise from flaws in it.
 
If you make changes to the code, or have suggestions for changes,
let us know!  (gpc@ipld01.hac.com)
*/

#ifndef lint
static char setup_c_rcsid[]="$Id: setup.c,v 2.12 1993/05/14 21:41:39 gpc-avc Exp gpc-avc $";
#endif

/*
 *
 * $Log: setup.c,v $
 * Revision 2.12  1993/05/14  21:41:39  gpc-avc
 * Changed pdiv to return 1 on div by zero (per Koza)
 *
 * Revision 2.11  1993/04/30  05:01:48  gpc-avc
 * Restructured directories and Makefile
 *
 * Revision 2.9  1993/04/15  09:15:30  gpc-avc
 * deleted code for that was added for regression testing
 *
 *
 */

#include <stdio.h>
#include "gpc.h"
#include "prob.h"


#ifdef ANSI_FUNC

VOID make_function_table(
  int 	numpops,
  pop_struct *pop
  )
#else

VOID make_function_table(numpops,pop)
  int		numpops;
  pop_struct	*pop;
#endif

{

  /* 
    Assigns function pointers, print names, arity, macro-flag, etc, to 
    function table entries for all populations.  In this case all 
    populations share the same function set.
  */

  int	p;

  for (p=0; p<numpops; p++) {
    pop[p].function_table_size = 5;
    pop[p].function_table =
      (function_table_entry *) malloc(pop[p].function_table_size *
				      sizeof(function_table_entry));

    pop[p].function_table[0].arity = 2;
    pop[p].function_table[0].macro = FALSE;
    pop[p].function_table[0].enabled = TRUE;
    pop[p].function_table[0].printname = "+";
    pop[p].function_table[0].code = plus;
    
    pop[p].function_table[1].arity = 2;
    pop[p].function_table[1].macro = FALSE;
    pop[p].function_table[1].enabled = TRUE;
    pop[p].function_table[1].printname = "-";
    pop[p].function_table[1].code = minus;
    
    pop[p].function_table[2].arity = 2;
    pop[p].function_table[2].macro = FALSE;
    pop[p].function_table[2].enabled = TRUE;
    pop[p].function_table[2].printname = "*";
    pop[p].function_table[2].code = xtimes;
    
    pop[p].function_table[3].arity = 2;
    pop[p].function_table[3].macro = FALSE;
    pop[p].function_table[3].enabled = TRUE;
    pop[p].function_table[3].printname = "%";
    pop[p].function_table[3].code = pdiv;
    
    pop[p].function_table[4].arity = 4;
    pop[p].function_table[4].macro = TRUE;
    pop[p].function_table[4].enabled = FALSE;
    pop[p].function_table[4].printname = "IFLTE";
    pop[p].function_table[4].code = iflte;
    
  }

}


#ifdef ANSI_FUNC

VOID make_terminal_table(
  int		numpops,
  pop_struct 	*pop
  )
#else

VOID make_terminal_table(numpops,pop)
  int		numpops;
  pop_struct 	*pop;
#endif
{
  /* 
     IMPORTANT NOTE: terminal_table_size should be equal to the number of
     terminals, but there should be (terminal_table_size+1) entries to allow
     for reading/printing actual constants
   */


  int p;

  /*
    NOTE: all populations are the same for this case
  */

  for (p=0; p<numpops; p++) {

    pop[p].terminal_table_size = 1;

    pop[p].terminal_table =
      (terminal_table_entry *) malloc((pop[p].terminal_table_size+1) *
				      sizeof(terminal_table_entry));
    pop[p].terminal_table[0].val = 0;
    pop[p].terminal_table[0].printname = "X";
    pop[p].terminal_table[0].constant_generator = random_constant;

    /*
    pop[p].terminal_table[1].val = 0;
    pop[p].terminal_table[1].printname = "F01";
    pop[p].terminal_table[1].constant_generator = random_constant;

    pop[p].terminal_table[2].val = 0;
    pop[p].terminal_table[2].printname = "F02";
    pop[p].terminal_table[2].constant_generator = random_constant;
    
    pop[p].terminal_table[3].val = 0;
    pop[p].terminal_table[3].printname = "F03";
    pop[p].terminal_table[3].constant_generator = random_constant;
    
    pop[p].terminal_table[4].val = 0;
    pop[p].terminal_table[4].printname = "F04";
    pop[p].terminal_table[4].constant_generator = random_constant;
    
    pop[p].terminal_table[5].val = 0;
    pop[p].terminal_table[5].printname = "F05";
    pop[p].terminal_table[5].constant_generator = random_constant;
    
    pop[p].terminal_table[6].val = 0;
    pop[p].terminal_table[6].printname = "F06";
    pop[p].terminal_table[6].constant_generator = random_constant;
    */

    pop[p].terminal_table[pop[p].terminal_table_size].val = 0;
    pop[p].terminal_table[pop[p].terminal_table_size].printname = FORMAT;
    pop[p].terminal_table[pop[p].terminal_table_size].constant_generator =
      random_constant;

    pop[p].format = FORMAT;
    pop[p].ckpt_format = CKPT_FORMAT;

  }
}
   
#ifdef ANSI_FUNC

GENERIC plus(
  GENERIC *args
  )
#else

GENERIC plus(args)
  GENERIC *args;
#endif
{
  return args[0]+args[1];
}

#ifdef ANSI_FUNC

GENERIC minus(
  GENERIC *args
  )
#else

GENERIC minus(args)
  GENERIC *args;
#endif
{
  return args[0]-args[1];
}

#ifdef ANSI_FUNC

GENERIC xtimes(
  GENERIC *args
  )
#else

GENERIC xtimes(args)
  GENERIC *args;
#endif
{
  return args[0]*args[1];
}

#ifdef ANSI_FUNC

GENERIC pdiv(
  GENERIC *args
  )
#else

GENERIC pdiv(args)
  GENERIC *args;
#endif
{
  return (args[1] ? args[0]/args[1] : 1);
}


/* this is an example of a macro: arguments are evaluated conditionally */
/* note that args are unevaluated trees, not GENERIC values */

#ifdef ANSI_FUNC

GENERIC iflte(
  tree **args
  )
#else

GENERIC iflte(args)
  tree 	**args;
#endif
{
  return ((eval(args[0]) < eval(args[1])) ? eval(args[2]) : eval(args[3]));
}

#ifdef ANSI_FUNC

GENERIC random_constant(void)
#else

GENERIC random_constant()
#endif
{
  return ((GENERIC)random_float(10.0) - (GENERIC)5.0);
}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日本一区二区三区免费乱视频 | 日韩二区三区四区| 日本一区二区动态图| 精品国产亚洲在线| 精品久久久影院| 欧美v日韩v国产v| 26uuu欧美| 久久精品人人做人人综合| 国产欧美日韩三区| 国产精品国产三级国产| 亚洲少妇最新在线视频| 亚洲一二三四区不卡| 亚洲成人1区2区| 蜜桃av一区二区三区| 精品一区二区三区在线观看国产| 久久99精品久久久久久动态图| 久久国产视频网| 成人性视频免费网站| 91在线云播放| 6080日韩午夜伦伦午夜伦| 精品国产一区二区国模嫣然| 国产清纯在线一区二区www| 亚洲欧美在线aaa| 美女国产一区二区| 久久成人免费电影| 国产suv精品一区二区883| 91一区二区三区在线播放| 欧美无砖砖区免费| 精品伦理精品一区| 亚洲免费观看高清完整版在线观看熊| 亚洲激情图片一区| 久久国产生活片100| av电影在线不卡| 91精品国产高清一区二区三区蜜臀 | 免费成人av在线播放| 蓝色福利精品导航| 国产精品99久| 欧美男生操女生| 中文一区在线播放| 午夜精品福利在线| 不卡大黄网站免费看| 91精品国产综合久久精品app | 成人网页在线观看| 9191成人精品久久| 中文字幕亚洲区| 免费成人在线视频观看| 91麻豆国产香蕉久久精品| 欧美电影免费观看高清完整版| 亚洲欧洲精品一区二区三区不卡| 麻豆视频一区二区| 欧美体内she精高潮| 国产精品久久久久精k8| 看电视剧不卡顿的网站| 99re视频这里只有精品| www久久久久| 蜜臀久久99精品久久久画质超高清| av在线播放一区二区三区| 欧美精品一区男女天堂| 石原莉奈在线亚洲二区| 色婷婷亚洲精品| 中文字幕欧美日韩一区| 狠狠色综合色综合网络| 欧美一区永久视频免费观看| 一区二区三区欧美在线观看| 成人国产免费视频| 国产欧美一区二区在线| 国产一区二区精品久久| 日本韩国欧美一区二区三区| 国产精品乱子久久久久| 国产电影精品久久禁18| 久久综合资源网| 麻豆精品一二三| 精品国产在天天线2019| 蜜桃精品视频在线| 欧美xxx久久| 极品瑜伽女神91| 精品少妇一区二区三区在线视频| 日韩电影在线看| 欧美一区二区三区日韩| 日本不卡在线视频| 日韩一区二区三区四区| 日韩高清中文字幕一区| 日韩欧美一区二区不卡| 久久99精品久久久久婷婷| 26uuu欧美日本| 国产精品一级片在线观看| 国产三级欧美三级日产三级99| 国产一区二区精品在线观看| 国产精品青草久久| 一本一本大道香蕉久在线精品| 亚洲自拍偷拍综合| 欧美一区二区三区免费| 国产精品夜夜嗨| 成人免费小视频| 在线不卡欧美精品一区二区三区| 日韩精品1区2区3区| 欧美大片在线观看一区二区| 国产超碰在线一区| 亚洲女与黑人做爰| 7777精品伊人久久久大香线蕉经典版下载| 视频一区二区三区在线| 精品处破学生在线二十三| 成人听书哪个软件好| 亚洲地区一二三色| 欧美成人精精品一区二区频| 国产大陆a不卡| 一区二区免费在线| 精品盗摄一区二区三区| 91片黄在线观看| 美女视频黄频大全不卡视频在线播放| 久久综合资源网| 欧美亚洲综合在线| 国产高清精品网站| 亚洲一区二区三区在线| 精品电影一区二区| 欧洲人成人精品| 国产福利电影一区二区三区| 亚洲国产另类av| 国产午夜久久久久| 911精品产国品一二三产区| 国产精品中文字幕一区二区三区| 亚洲综合在线视频| 中文字幕巨乱亚洲| 日韩精品一区二区在线| 欧美在线一二三| 岛国精品在线观看| 九色综合狠狠综合久久| 一区二区视频在线| 欧美激情一区二区三区蜜桃视频| 欧美日本在线一区| 色综合久久久网| 丰满少妇久久久久久久| 久久97超碰色| 日韩电影在线一区| 丝袜亚洲另类欧美| 一区二区三区欧美日| 日本一区二区成人在线| 精品国产乱码久久久久久久| 91精品视频网| 欧美精品日韩综合在线| 在线免费观看视频一区| 91在线视频18| 成人免费不卡视频| 成人在线综合网| 国产成人免费视频| 国产一区二区在线观看视频| 蜜乳av一区二区| 蜜臂av日日欢夜夜爽一区| 视频一区在线视频| 日韩精品视频网| 伦理电影国产精品| 日韩电影在线观看网站| 婷婷国产v国产偷v亚洲高清| 亚洲第一精品在线| 午夜精品久久久| 蜜桃久久av一区| 极品尤物av久久免费看| 经典三级视频一区| 激情亚洲综合在线| 国产精品影视在线观看| 成人性视频免费网站| 91丝袜高跟美女视频| 91高清视频在线| 欧美精品丝袜中出| 精品国产成人系列| 久久精品日韩一区二区三区| 国产精品你懂的在线欣赏| 17c精品麻豆一区二区免费| 亚洲色图在线播放| 亚洲国产va精品久久久不卡综合| 香蕉影视欧美成人| 国产一区二区三区免费看| 岛国精品在线观看| 欧美性猛交xxxxxxxx| 日韩欧美你懂的| 中文字幕高清一区| 亚洲一区av在线| 国模娜娜一区二区三区| 成人18视频在线播放| 欧美日韩一区二区三区在线 | 国产精品一线二线三线精华| 国产成人在线网站| 色综合久久久久网| 日韩视频国产视频| 国产精品久久久久久亚洲毛片 | 丝袜美腿一区二区三区| 国产一区二区免费看| 在线视频欧美精品| 精品伦理精品一区| 亚洲美女精品一区| 激情综合一区二区三区| av电影在线观看完整版一区二区| 欧美日韩一区国产| 国产亚洲精品aa午夜观看| 一区二区不卡在线播放 | 99re这里只有精品首页| 51精品国自产在线| 国产精品视频一二| 久久精品国产第一区二区三区| 不卡影院免费观看|