Changeset 1055
 Timestamp:
 Jan 31, 2014 1:27:50 PM (6 years ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

trunk/Couenne/src/convex/operators/convexprTrilineargencuts.cpp
r1053 r1055 1279 1279 for (int i = (int) cutIndices.size (); i;) { 1280 1280 1281 int1282 size = (int) cutIndices [i].size (),1283 *ind = new int [size];1284 1285 double *coe = new double [size];1286 1287 1281 // Fix right hand sides: all cuts have coefficients of w equal to 1288 1282 // one, but they might be inequalitytype auxiliaries. … … 1295 1289 } 1296 1290 1297 if ((cutLb [i] >  COUENNE_INFINITY)  1298 (cutUb [i] < COUENNE_INFINITY)) { 1299 1300 std::copy (cutIndices [i].begin (), cutIndices [i].end (), ind); 1301 std::copy (cutCoeff [i].begin (), cutCoeff [i].end (), coe); 1302 1303 OsiRowCut cut (cutLb [i], cutUb [i], 4, 4, ind, coe); 1291 if ((cutLb [i] >  COUENNE_INFINITY/10)  1292 (cutUb [i] < COUENNE_INFINITY/10)) { 1293 1294 int 1295 size = (int) cutIndices [i].size (), 1296 *ind = new int [size]; 1297 1298 double *coe = new double [size]; 1299 1300 int cardCut = 0; 1301 for(int fmi=0; fmi<4; fmi++) { 1302 if(fabs(cutCoeff[i][fmi]) > 1e8) { 1303 ind[cardCut] = cutIndices[i][fmi]; 1304 coe[cardCut] = cutCoeff[i][fmi]; 1305 cardCut++; 1306 } 1307 } 1308 1309 OsiRowCut cut (cutLb [i], cutUb [i], 4, cardCut, ind, coe); 1304 1310 //cut.print (); 1305 1306 delete [] ind;1307 delete [] coe;1308 1311 1309 1312 if (cg > Problem () > bestSol ()) {
Note: See TracChangeset
for help on using the changeset viewer.