add "\n" to most error messages.
finite() is deprecated on OSX 10.9, use isfinite().
silence deprecation warnings also on 10.9.