// -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- // Copyright (C) 2007 Author: Fathi Elloumi. // This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or any later version. // This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. // You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- #ifndef UTILITIES2_H #define UTILITIES2_H #include "listgen.h" #include //------------------------------------------------------------------- typedef Listgen * tabtablist[4]; typedef struct { char pat[41]; // char mat[5]; int len; int den; int sup; int tot; long double proba; long double pvalue; char listpos[20000]; } elt ; //////////////////////////// void concat(char * tab, char c1, int nbpoints, char c2); bool matchpattern(char * s1, char * s2); int max(int t1,int t2); int matching(char * tab,char * s1, char * s2); int best(elt T[], int & nbelts,int taille,char *fich); int besttot(elt T[], int & nbelts,int taille,char *fich); int pospatt(char *fin,char *fpos,char *flog); int prostat(double ppa,double ppc,double ppg,double ppt,char *fin, char *fpro, char *fstat); int simrev(char *best,char *sim , char *rev); long double fact(int x) ; long double bino(int n, int k, long double q); long double bino2(int n, int k, long double q); long double binocum(int n, int k, long double q); ///////////// char complem(char x) ; bool testrev(char *dp, char *eq, int size); char maj(char x) ; //char * concat(char c1, int nbpoints, char c2); int revcomp(char *fich, int & lenseqs,int tseq []) ; int create(tabtablist T) ; //int join(Listgen * A1,Listgen * A2,int taille,char c1,char c2, Slist & L) #endif