Reduced the number of functions needed for writing data to disk from 12 to 2.

- Previously required a disk writing function for each combination of data type (bool, int, float), data container (array, vector), and writing to single/muliple files.
- Replaced these with template functions, one for arrays and one for vectors, which can accept any data type and can write to data to a single file or multiple files depending on value of a boolean parameter.
- Previous functions had no checks to ensure no attempts to access data beyond the end of array/vector
- Function for writing data from vector to file checks its size to prevent accesses beyond end of vector, function for writing data from array requires additional parameter specifying the number of elements in array.
- Using the same function to write data to a single file or multiple files requires an additional parameter and complicates implementation; this capability may be separated into 2 functions in the future.