Changeset 2364:3a5e67bd42d2 in lemon-0.x for lemon/lp_soplex.cc
- Timestamp:
- 02/15/07 20:15:14 (17 years ago)
- Branch:
- default
- Phase:
- public
- Convert:
- svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@3175
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
lemon/lp_soplex.cc
r2363 r2364 100 100 101 101 102 void LpSoplex::_setRowCoeffs(int i, LpRowIterator b, LpRowIterator e) {102 void LpSoplex::_setRowCoeffs(int i, ConstRowIterator b, ConstRowIterator e) { 103 103 for (int j = 0; j < soplex->nCols(); ++j) { 104 104 soplex->changeElement(i, j, 0.0); 105 105 } 106 for( LpRowIterator it = b; it != e; ++it) {106 for(ConstRowIterator it = b; it != e; ++it) { 107 107 soplex->changeElement(i, it->first, it->second); 108 108 } 109 109 solved = false; 110 110 } 111 112 void LpSoplex::_setColCoeffs(int j, LpColIterator b, LpColIterator e) { 111 112 void LpSoplex::_getRowCoeffs(int i, RowIterator b) { 113 const soplex::SVector& vec = soplex->rowVector(i); 114 for (int k = 0; k < vec.size(); ++k) { 115 *b = std::make_pair(vec.index(k), vec.value(k)); 116 ++b; 117 } 118 } 119 120 void LpSoplex::_setColCoeffs(int j, ConstColIterator b, ConstColIterator e) { 113 121 for (int i = 0; i < soplex->nRows(); ++i) { 114 122 soplex->changeElement(i, j, 0.0); 115 123 } 116 for( LpColIterator it = b; it != e; ++it) {124 for(ConstColIterator it = b; it != e; ++it) { 117 125 soplex->changeElement(it->first, j, it->second); 118 126 } 119 127 solved = false; 128 } 129 130 void LpSoplex::_getColCoeffs(int i, ColIterator b) { 131 const soplex::SVector& vec = soplex->colVector(i); 132 for (int k = 0; k < vec.size(); ++k) { 133 *b = std::make_pair(vec.index(k), vec.value(k)); 134 ++b; 135 } 120 136 } 121 137
Note: See TracChangeset
for help on using the changeset viewer.