Code:

#include<math.h>
#include<stdio.h>
#include<string.h>
#include<time.h>
float bilinterp(int A1[10], float A2[400][10], float B1[400][10], float e, float f, int P, int NRe);
float interp(float A1[100], float A2[100], float a, int P);
int main(int argc, char **argv){
float alfam[400][10],Clm[400][10],Cdm[400][10];
float Vel[100],RAD,hub,pi,phi,alfa,Cn,Ct,delta,sigma,f1,f2,F,dr[200];
float x[200],r[200],c[200],theta[200],tsr[100];
float ab[2],a,b,mu,rho,tol,W,Re,CL,CD,dT,dQ,ac,Ka,converge1,converge2;
FILE *fpin, *fpout, *fpconvergedataout;
int i,j,cc,d,k,N,M,P,NRe,B,ITER,WARN,start_time,Rev[10],ReRef,quit,nonconverg,convergedata,TL,delim,maxiter;
start_time=time(NULL);
pi = 4.0*atan(1.0);
delta = 0.1;
ac = 0.4;
nonconverg=0;
delim=-1;
fpin=fopen(argv[1],"r");
fpout=fopen(argv[2],"w");
printf("Reading File...\n");
fscanf(fpin,"%d",&P);
fscanf(fpin,"%d",&NRe);
for(i=0;i<NRe;++i){fscanf(fpin,"%i",&Rev[i]);}
for(i=0;i<NRe;++i){
for(j=0;j<P;++j){
fscanf(fpin,"%f",&alfam[j][i]);} // **EXC_BAD_ACCESS at this point**
}