/*-------------------------------------------------------------- main.c P. Clote --------------------------------------------------------------*/ #include #include #include #include "spectrum.h" #include // character handling //WARNING -- GLOBAL variables MatrixType M; TripletMatrixType S; main(int argc, char *argv[]) { // variable declarations FILE *file; char text[3*NN]; char paren[NN]; short ExistBP[NN][NN]; double n0; int s,b; char *nuclSeq; int i,n; //i is loop control var, n is length of RNA sequence int k; char *flag, *rna, *secStr; short *a; //a points to array a[0],...,a[n] //where a[0]=n, and a[1],...,a[n] are RNA nucleotides //and where n <= NN-2 /**** Error handling for input file ****/ if (argc != 3) { fprintf(stderr,"%s -s/-f string/finame\n",argv[0]); fprintf(stderr,"\t-s: enter RNA string \n"); fprintf(stderr,"\t-f: enter file of RNA in FASTA format\n"); exit(1); } flag = argv[1]; rna = argv[2]; for (i=0;i