3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-05-15 03:34:44 +00:00

replace lean to lp

Signed-off-by: Lev Nachmanson <levnach@microsoft.com>
This commit is contained in:
Lev Nachmanson 2017-07-10 11:06:37 -07:00
parent f6a75600c2
commit cc32e45471
117 changed files with 1726 additions and 1726 deletions

View file

@ -5,7 +5,7 @@
#include <algorithm>
#include "util/lp/scaler.h"
#include "util/lp/numeric_pair.h"
namespace lean {
namespace lp {
// for scaling an LP
template <typename T, typename X> T scaler<T, X>::right_side_balance() {
T ret = zero_of_type<T>();
@ -41,7 +41,7 @@ template <typename T, typename X> T scaler<T, X>::A_max() const {
template <typename T, typename X> T scaler<T, X>::get_A_ratio() const {
T min = A_min();
T max = A_max();
lean_assert(!m_settings.abs_val_is_smaller_than_zero_tolerance(min));
lp_assert(!m_settings.abs_val_is_smaller_than_zero_tolerance(min));
T ratio = max / min;
return ratio;
}
@ -51,7 +51,7 @@ template <typename T, typename X> T scaler<T, X>::get_max_ratio_on_rows() con
unsigned i = m_A.row_count();
while (i--) {
T den = m_A.get_min_abs_in_row(i);
lean_assert(!m_settings.abs_val_is_smaller_than_zero_tolerance(den));
lp_assert(!m_settings.abs_val_is_smaller_than_zero_tolerance(den));
T t = m_A.get_max_abs_in_row(i)/ den;
if (t > ret)
ret = t;
@ -78,7 +78,7 @@ template <typename T, typename X> void scaler<T, X>::scale_rows_with_geometri
while (i--) {
T max = m_A.get_max_abs_in_row(i);
T min = m_A.get_min_abs_in_row(i);
lean_assert(max > zero_of_type<T>() && min > zero_of_type<T>());
lp_assert(max > zero_of_type<T>() && min > zero_of_type<T>());
if (is_zero(max) || is_zero(min))
continue;
T gm = T(sqrt(numeric_traits<T>::get_double(max*min)));