| 1304 | } |
| 1305 | |
| 1306 | void Engine::addAuxiliaryVariables() |
| 1307 | { |
| 1308 | List<Equation> &equations( _preprocessedQuery->getEquations() ); |
| 1309 | |
| 1310 | unsigned m = equations.size(); |
| 1311 | unsigned originalN = _preprocessedQuery->getNumberOfVariables(); |
| 1312 | unsigned n = originalN + m; |
| 1313 | |
| 1314 | _preprocessedQuery->setNumberOfVariables( n ); |
| 1315 | |
| 1316 | // Add auxiliary variables to the equations and set their bounds |
| 1317 | unsigned count = 0; |
| 1318 | for ( auto &eq : equations ) |
| 1319 | { |
| 1320 | unsigned auxVar = originalN + count; |
| 1321 | if ( _produceUNSATProofs ) |
| 1322 | _preprocessedQuery->_lastAddendToAux.insert( eq._addends.back()._variable, auxVar ); |
| 1323 | eq.addAddend( -1, auxVar ); |
| 1324 | _preprocessedQuery->setLowerBound( auxVar, eq._scalar ); |
| 1325 | _preprocessedQuery->setUpperBound( auxVar, eq._scalar ); |
| 1326 | eq.setScalar( 0 ); |
| 1327 | |
| 1328 | ++count; |
| 1329 | } |
| 1330 | } |
| 1331 | |
| 1332 | void Engine::augmentInitialBasisIfNeeded( List<unsigned> &initialBasis, |
| 1333 | const List<unsigned> &basicRows ) |
nothing calls this directly
no test coverage detected