mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Improved iteration.
This commit is contained in:
parent
82604f8269
commit
bfc9c91539
@ -582,10 +582,10 @@ void LPSolver::SubProblem::update(size_t _varIndex, RationalWithDelta const& _va
|
||||
{
|
||||
RationalWithDelta delta = _value - variables[_varIndex].value;
|
||||
variables[_varIndex].value = _value;
|
||||
for (size_t j = 0; j < variables.size(); j++)
|
||||
if (basicVariables.count(j) && factors[basicVariables.at(j)][_varIndex])
|
||||
for (auto&& [j, row]: basicVariables)
|
||||
if (factors[row][_varIndex])
|
||||
{
|
||||
variables[j].value += delta * factors[basicVariables.at(j)][_varIndex];
|
||||
variables[j].value += delta * factors[row][_varIndex];
|
||||
//variablesPotentiallyOutOfBounds.insert(j);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user