Advertisement
Guest User

Untitled

a guest
Jan 14th, 2019
63
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.62 KB | None | 0 0
  1. int main(int argc, char **argv){
  2.     //Create a pointer to an array of pointers to first element in double array
  3.     //There are numFiles pointers to double array each holding TF+1 doubles
  4.     double **DataMatrix = calloc(numFiles*(TF+1),sizeof(DataMatrix));
  5.  
  6.  
  7.     //Pass the pointer to the first element in double array i
  8.     for(int i=0; i<numFiles; i++){
  9.         //Process FILES
  10.         processFile(argv[i+2],alpha,DataMatrix[i]);
  11.     }
  12.  
  13.     free(DataMatrix);
  14.     return 0;
  15. }
  16.  
  17. void processFile(char *fn, double alpha, double *DataArray{
  18.     for(int time=0; time<=TF; i++){
  19.         DataMatrix[time] = 10.0;
  20.     }
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement