Added writeToFile

Now we write our arrays to a file so we can use them in Matlab,
woohoo!!!