From d88f8b35c30a8782e7be407bfd1ffdcdae5ed4a6 Mon Sep 17 00:00:00 2001 From: Michael Orlitzky Date: Sun, 9 Oct 2016 21:58:40 -0400 Subject: [PATCH] Add an options module to consolidate a few random "settings." --- src/dunshire/options.py | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 src/dunshire/options.py diff --git a/src/dunshire/options.py b/src/dunshire/options.py new file mode 100644 index 0000000..03518d8 --- /dev/null +++ b/src/dunshire/options.py @@ -0,0 +1,18 @@ +""" +A place to collect the various options that "can be passed to the +underlying engine." Just kidding, they're constants and you can't +change them. But this makes the user interface real simple. +""" + +# The absolute tolerance used in all "are these numbers equal" and "is +# this number less than (or equal to) that other number" tests. +ABS_TOL = 1e-7 + +# The default output format for floating point numbers. It has been +# chosen to match the ABS_TOL, in the sense that if x != y, then they +# would not appear different when printed. +FLOAT_FORMAT = '%.7f' + +# The underlying CVXOPT solver can output debug information, and I +# guess, so could we. But we don't want to because it's ugly. +VERBOSE = False -- 2.44.2