Commit 4399e0af authored by niklas.thiel's avatar niklas.thiel

further cleanup

parent 0803b755
...@@ -50,21 +50,6 @@ void pup(float **data_p, float **data_vy, FILE *fp, int ntr_glob, int **recpos, ...@@ -50,21 +50,6 @@ void pup(float **data_p, float **data_vy, FILE *fp, int ntr_glob, int **recpos,
nx_pot = (int)(pow(2,(ceil(log(ntr_glob*2)/log(2))))); nx_pot = (int)(pow(2,(ceil(log(ntr_glob*2)/log(2)))));
ny_pot = (int)(pow(2,(ceil(log(ns*2)/log(2))))); ny_pot = (int)(pow(2,(ceil(log(ns*2)/log(2)))));
/* test: write p-data to file*/
if (ishot==1 && iter==1) {
sprintf(pf1,"%s_data_p_.shot%i.it%i.bin",SEIS_FILE,ishot, iter);
file = fopen(pf1,"wb");
for (i=1;i<=ntr_glob;i++)
for (j=1;j<=ns;j++) fwrite(&data_p[i][j],sizeof(float),1,file);
fclose(file);
}
/* test: write vz-data to file*/
if (ishot==1 && iter==1) {
sprintf(pf1,"%s_data_vz_.shot%i.it%i.bin",SEIS_FILE,ishot, iter);
file = fopen(pf1,"wb");
for (i=1;i<=ntr_glob;i++)
for (j=1;j<=ns;j++) fwrite(&data_vy[i][j],sizeof(float),1,file);
fclose(file);
} }
/* temporary array */ /* temporary array */
filtwk=matrix(1,ny_pot/2,1,nx_pot/2); filtwk=matrix(1,ny_pot/2,1,nx_pot/2);
...@@ -189,16 +174,6 @@ void pup(float **data_p, float **data_vy, FILE *fp, int ntr_glob, int **recpos, ...@@ -189,16 +174,6 @@ void pup(float **data_p, float **data_vy, FILE *fp, int ntr_glob, int **recpos,
/* reverse 2d fft */ /* reverse 2d fft */
fft2(data_pup, data_pupim, ny_pot, nx_pot,-1); fft2(data_pup, data_pupim, ny_pot, nx_pot,-1);
if (VERBOSE) fprintf(FP,"Write PUP data to file...\n ");
/* write spectrum to file */
if (ishot==1 && iter==1) {
sprintf(pf2,"%s_data_pup.shot%i.it%i.bin",SEIS_FILE,ishot, iter);
file = fopen(pf2,"wb");
for (i=1;i<=nx_pot;i++)
for (j=1;j<=ny_pot;j++) fwrite(&data_pup[j][i],sizeof(float),1,file);
fclose(file);
}
if (VERBOSE) fprintf(FP,"Write PUP-data into p-data array...\n "); if (VERBOSE) fprintf(FP,"Write PUP-data into p-data array...\n ");
/* overwrite p data */ /* overwrite p data */
...@@ -209,6 +184,7 @@ void pup(float **data_p, float **data_vy, FILE *fp, int ntr_glob, int **recpos, ...@@ -209,6 +184,7 @@ void pup(float **data_p, float **data_vy, FILE *fp, int ntr_glob, int **recpos,
} }
/* save pup*/ /* save pup*/
if (VERBOSE) fprintf(FP,"Write PUP data to file...\n ");
if (sw == 1){ if (sw == 1){
sprintf(pf,"%s_pup.su.shot%i",SEIS_FILE,ishot); sprintf(pf,"%s_pup.su.shot%i",SEIS_FILE,ishot);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment