Added generating of data files for gnuplot. Some changes need to be done to get rid of memory leaks and jumps based on uninitialised values conditions.