/***************************************************************************** File name: indel_std.h Author: Manami Nishizawa Contents: The header file of standard handling and definition Date: May 30,2000 ******************************************************************************/ #ifndef __INDEL_STD_H #define __INDEL_STD_H #include #include #include #include #include #include #include /*type definition*/ #define PNTR * #define Uint1 unsigned char #define Uint1Ptr unsigned char PNTR #define MAX(x,y) ((x)>(y)? (x) : (y)) #define MIN(x,y) ((x)>(y)? (y) : (x)) #define SIGN(a) ((a)>0? 1 : ((a)<0? -1 : 0)) #define ABS(x) ((x)>0? (x) : -(x)) #define INT4_MAX 32767 #define LONG_MAX 2147483647 #define LONG_MIN -2147483647 /*function*/ /*mem*/ extern void * MemFree(void *ptr); extern char *StringSave(const char *str); /*ASCII to Uint1*/ Uint1 ASCIIToBASEs(char base); char BASEsToASCII(Uint1 A); Uint1 ASCIIToAA(char amino, short alphabet_code); char AAToASCII(Uint1 A, short alphabet_code); /*simple function*/ void error (char * message); int xtoy (double x[], double y[], int n); int round(double x); /*random*/ void SetSeed (int seed); double rndu (void); double RandomReal(double low,double high); int RandomInteger(int low, int high); double rndnorm (void); int rndpoisson (double m); double rndgamma (double s); double LnGamma (double x); #endif