#include #include #include #include #include int diff_within_between1(nsam,ns,list,dij) int nsam, ns, **dij ; int **list; { int i, j ; double diff(); for(i=0;i<(nsam-1);i++) for(j=i+1;j=0 && gam2[i]>=0) && (gam1[i] != gam2[i]) ) count += 1. ; } return( count ); } /* allocates space for gametes (character strings) */ int ** cmatrix(nsam,len) int nsam, len; { int i; int **m; if( ! ( m = (int **) malloc( (unsigned) nsam*sizeof( int* ) ) ) ) perror("alloc error in cmatrix") ; for( i=0; i