- let () = print_endline(" Done. (duration: " ^ (string_of_float (toc3 -. tic3)) ^ "s.)") in
-
-
- let () = print_string(" Faustine -> Evaluating...") in
- let tic4 = Unix.time () in
- let data = output#output !time_max in
- let rates = output#frequency in
- let toc4 = Unix.time () in
- let () = print_endline(" Done. (duration: " ^ (string_of_float (toc4 -. tic4)) ^ "s.)") in
-
-
- let () = print_string(" Faustine -> Writing output...") in
- let tic5 = Unix.time () in
- let output_paths = io#write rates data in
- let toc5 = Unix.time () in
- let () = print_endline(" Done. (duration: " ^ (string_of_float (toc5 -. tic5)) ^ "s.)") in
-
- let _ = Array.map print_endline
- (Array.map decorate output_paths) in
- ();;
+ let () = output_string stderr (" Done. (duration: " ^ (string_of_float (toc3 -. tic3)) ^ "s.)\n") in
+
+
+ if (!stdout_filename = "" && !format_output = "") || (!format_output = "nst")
+ || (!stdout_filename <> "" && (get_extension !stdout_filename) = "nst") then (
+ let () = output_string stderr (" Faustine -> Evaluating...") in
+ let tic4 = Unix.time () in
+ let raws = output#output_values !time_max in
+ let rates = output#frequency in
+ let toc4 = Unix.time () in
+ let () = output_string stderr (" Done. (duration: " ^ (string_of_float (toc4 -. tic4)) ^ "s.)\n") in
+
+
+ let () = output_string stderr (" Faustine -> Writing output...") in
+ let tic5 = Unix.time () in
+ let output_paths = io#write_nst rates raws in
+ let toc5 = Unix.time () in
+ let () = output_string stderr (" Done. (duration: " ^ (string_of_float (toc5 -. tic5)) ^ "s.)\n") in
+
+ let _ = Array.map (output_string stderr) (Array.map decorate output_paths) in
+ ()
+ )
+
+ else (
+ let () = output_string stderr (" Faustine -> Evaluating...") in
+ let tic6 = Unix.time () in
+ let data = output#output !time_max in
+ let rates = output#frequency in
+ let toc6 = Unix.time () in
+ let () = output_string stderr (" Done. (duration: " ^ (string_of_float (toc6 -. tic6)) ^ "s.)\n") in
+
+
+ let () = output_string stderr (" Faustine -> Writing output...") in
+ let tic7 = Unix.time () in
+ let output_paths = io#write rates data in
+ let toc7 = Unix.time () in
+ let () = output_string stderr (" Done. (duration: " ^ (string_of_float (toc7 -. tic7)) ^ "s.)\n") in
+
+ let _ = Array.map (output_string stderr) (Array.map decorate output_paths) in
+ ()
+ );;