various compilation fixed for visual studio 2013
This commit is contained in:
@@ -1177,7 +1177,7 @@ std::function<LiteralIndex()> FirstUnassignedVarAtItsMinHeuristic(
|
||||
.Index();
|
||||
}
|
||||
}
|
||||
return kNoLiteralIndex;
|
||||
return LiteralIndex(kNoLiteralIndex);
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1197,7 +1197,7 @@ std::function<LiteralIndex()> UnassignedVarWithLowestMinAtItsMinHeuristic(
|
||||
candidate_lb = lb;
|
||||
}
|
||||
}
|
||||
if (candidate == kNoIntegerVariable) return kNoLiteralIndex;
|
||||
if (candidate == kNoIntegerVariable) return LiteralIndex(kNoLiteralIndex);
|
||||
return integer_encoder
|
||||
->GetOrCreateAssociatedLiteral(
|
||||
IntegerLiteral::LowerOrEqual(candidate, candidate_lb))
|
||||
|
||||
@@ -25,6 +25,8 @@ DEFINE_bool(lp_constraint_use_dual_ray, true,
|
||||
namespace operations_research {
|
||||
namespace sat {
|
||||
|
||||
const double LinearProgrammingConstraint::kEpsilon = 1e-6;
|
||||
|
||||
LinearProgrammingConstraint::LinearProgrammingConstraint(
|
||||
IntegerTrail* integer_trail)
|
||||
: integer_trail_(integer_trail) {
|
||||
|
||||
@@ -127,7 +127,7 @@ class LinearProgrammingConstraint : public PropagatorInterface {
|
||||
glop::Fractional GetVariableValueAtCpScale(glop::ColIndex var);
|
||||
|
||||
// TODO(user): use solver's precision epsilon.
|
||||
constexpr static double kEpsilon = 1e-6;
|
||||
static const double kEpsilon;
|
||||
|
||||
// Underlying LP solver API.
|
||||
glop::LinearProgram lp_data_;
|
||||
|
||||
@@ -351,8 +351,9 @@ PiecewiseLinearFunction* PiecewiseLinearFunction::CreateFullDomainFunction(
|
||||
|
||||
PiecewiseLinearFunction* PiecewiseLinearFunction::CreateOneSegmentFunction(
|
||||
int64 point_x, int64 point_y, int64 slope, int64 other_point_x) {
|
||||
return new PiecewiseLinearFunction(
|
||||
{PiecewiseSegment(point_x, point_y, slope, other_point_x)});
|
||||
std::vector<PiecewiseSegment> segments =
|
||||
{PiecewiseSegment(point_x, point_y, slope, other_point_x)};
|
||||
return new PiecewiseLinearFunction(segments);
|
||||
}
|
||||
|
||||
PiecewiseLinearFunction* PiecewiseLinearFunction::CreateRightRayFunction(
|
||||
|
||||
Reference in New Issue
Block a user