gatypes.h

来自「单目标遗传算法优化的经典例子c++源码」· C头文件 代码 · 共 37 行

H
37
字号
// $Header: /usr/people/mbwall/src/galib/ga/RCS/gatypes.h,v 1.2 1998/10/05 21:30:09 mbwall Exp $
/* ----------------------------------------------------------------------------
  gatypes.h
  mbwall 29apr95
  Copyright (c) 1995 Massachusetts Institute of Technology
                     all rights reserved
---------------------------------------------------------------------------- */
#ifndef _ga_types_h_
#define _ga_types_h_


typedef float GAProbability;
typedef float GAProb;

// This enforces return values and arguments to functions that want strict
// boolean arguments.
typedef enum _GABoolean {
  gaFalse=0,
  gaTrue
} GABoolean, GABool;

typedef enum _GAStatus {
  gaSuccess=0,
  gaFailure=-1
} GAStatus;

// This defines what type to use for the bitstream data storage.  Use the
// smallest type available on your platform.  
typedef unsigned char GABit;


#define GAMax(a,b) ((a) > (b) ? (a) : (b))
#define GAMin(a,b) ((a) < (b) ? (a) : (b))


#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?