Boost logo

Boost :

From: yihung.chen_at_[hidden]
Date: 2002-07-10 12:58:23


Hi Jeremy,

The graph data I uses is the same as the one in
~\BGL\boost_1_25_1\libs\graph\example\max_flow.dat. The data is packaged
as a TclTk list
like the following:
 set a {{0 20 20 0 0 0 3 0} {20 0 0 20 0 1 0 0} {20 0 0 20 4 0 0 0} {0
20 20 0 0 0 0 5} {0 0 0 0 0 20 20 0} {0 0 0 0 20 0 0 20} {0 0 0 0 20 0
0 20} {0 0 0 0 0 20 20
                0} }

I have a TclTk script to read in and parse the data and pass it to graph
library. Enclosed is the code that sets up the graph class and calls the
"push_relabel_max_flow" function. Am I missing something ?

Thanks for your help.

Yihung

Jeremy Siek <jsiek_at_[hidden]>
Sent by: boost-bounces_at_[hidden]
07/10/2002 12:33 PM
Please respond to boost

 
        To: boost_at_[hidden]
        cc: (bcc: Yihung Chen/CLE/MS/PHILIPS)
        Subject: Re: [boost] maximum Flow runtime error
        Classification:

Hi Yihung,

Could you send the data file so I can try to reproduce the error.

Thanks,
Jeremy

On Tue, 9 Jul 2002 yihung.chen_at_[hidden] wrote:

yihung> Hi,
yihung>
yihung> I try to use "edmunds_karp_max_flow" and "push_relabel_max_flow"
yihung> routines in my applicaton. Both routines receives the same set of
yihung> parameters (g, src, sink, cap, res, rev) which is similar to the
examples in edmunds-karp-eg.cpp and push-relabel-eg.cpp. The
edmunds_karp_max_flow routine run through and output correct result.
yihung> But the push_relabel_max_flow ran into an error as follows:
yihung>
yihung> Unhandled exception in test.exe: 0xC00000005: Access violation.
yihung>
yihung> VS debugger points to the eigth line
yihung>
yihung> FlowValue maximum_preflow()
yihung> {
yihung> work_since_last_update = 0;
yihung>
yihung> while (max_active >= min_active) { // "main" loop
yihung>
yihung> Layer& layer = layers[max_active];
yihung> ----> list_iterator u_iter = layer.active_vertices.begin();
yihung>
yihung> if (u_iter == layer.active_vertices.end())
yihung> --max_active;
yihung> else {
yihung> vertex_descriptor u = *u_iter;
yihung> remove_from_active_list(u);
yihung>
yihung> discharge(u);
yihung>
yihung> if (work_since_last_update * global_update_frequency()
> nm) {
yihung> global_distance_update();
yihung> work_since_last_update = 0;
yihung> }
yihung> }
yihung> } // while (max_active >= min_active)
yihung>
yihung> return excess_flow[sink];
yihung> } // maximum_preflow()
yihung>
yihung>
yihung>
yihung> Can anyone give me some advice on this. Thanks.
yihung>
yihung>
yihung> Yihung Chen
yihung>

----------------------------------------------------------------------
 Jeremy Siek http://php.indiana.edu/~jsiek/
 Ph.D. Student, Indiana Univ. B'ton email: jsiek_at_[hidden]
 C++ Booster (http://www.boost.org) office phone: (812) 855-3608
----------------------------------------------------------------------

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost





Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk