The function works and gives the output. Checked the output and they are correct. The problem with dimension of matrix is solved in general form so it can read in files with different time step.
Added optional overwrite function in case the user wants to overwrite existing files in Outfolder.
Overwriting option added as part of the function.
Merge pull request #142 from apourmok/master

The function works and gives correct output.