added user defined output file