Changeset 1195:4d07dd56fa9a in lemon0.x for src/test
 Timestamp:
 03/05/05 00:12:10 (16 years ago)
 Branch:
 default
 Phase:
 public
 Convert:
 svn:c9d7d8f590d60310b91f818b3a526b0e/lemon/trunk@1607
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

src/test/dijkstra_heap_test.cc
r1194 r1195 120 120 if ( dijkstra_test.reached(v) ) { 121 121 Edge e=dijkstra_test.pred(v); 122 Node u=graph.source(e); 123 if ( dijkstra_test.dist(v)  dijkstra_test.dist(u) != cap[e] ) { 124 std::cout<<"Error in a shortest path tree edge! Difference: " 125 <<std::abs(dijkstra_test.dist(v)  dijkstra_test.dist(u) 126  cap[e])<<std::endl; 127 ++error2; 122 if(e!=INVALID) { 123 Node u=graph.source(e); 124 if ( dijkstra_test.dist(v)  dijkstra_test.dist(u) != cap[e] ) { 125 std::cout<<"Error in a shortest path tree edge! Difference: " 126 <<std::abs(dijkstra_test.dist(v)  dijkstra_test.dist(u) 127  cap[e])<<std::endl; 128 ++error2; 129 } 128 130 } 129 131 } 130 132 } 131 133 132 134 133 135 … … 169 171 if ( dijkstra_test2.reached(v) ) { 170 172 Edge e=dijkstra_test2.pred(v); 171 Node u=graph.source(e); 172 if ( dijkstra_test2.dist(v)  dijkstra_test2.dist(u) != cap[e] ) { 173 std::cout<<"Error in a shortest path tree edge! Difference: " 174 <<std::abs(dijkstra_test2.dist(v)  dijkstra_test2.dist(u) 175  cap[e])<<std::endl; 176 ++error2; 173 if(e!=INVALID) { 174 Node u=graph.source(e); 175 if ( dijkstra_test2.dist(v)  dijkstra_test2.dist(u) != cap[e] ) { 176 std::cout<<"Error in a shortest path tree edge! Difference: " 177 <<std::abs(dijkstra_test2.dist(v)  dijkstra_test2.dist(u) 178  cap[e])<<std::endl; 179 ++error2; 180 } 177 181 } 178 182 } 179 183 } 180 184 181 185 182 186 std::cout << error1 << " nontree and " << error2 … … 216 220 if ( dijkstra_test3.reached(v) ) { 217 221 Edge e=dijkstra_test3.pred(v); 218 Node u=graph.source(e); 219 if ( dijkstra_test3.dist(v)  dijkstra_test3.dist(u) != cap[e] ) { 220 std::cout<<"Error in a shortest path tree edge! Difference: " 221 <<std::abs(dijkstra_test3.dist(v)  dijkstra_test3.dist(u) 222  cap[e])<<std::endl; 223 ++error2; 222 if(e!=INVALID) { 223 Node u=graph.source(e); 224 if ( dijkstra_test3.dist(v)  dijkstra_test3.dist(u) != cap[e] ) { 225 std::cout<<"Error in a shortest path tree edge! Difference: " 226 <<std::abs(dijkstra_test3.dist(v)  dijkstra_test3.dist(u) 227  cap[e])<<std::endl; 228 ++error2; 229 } 224 230 } 225 231 } 226 232 } 227 233 228 234 229 235 std::cout << error1 << " nontree and " << error2
Note: See TracChangeset
for help on using the changeset viewer.