[Lemon-user] Using NetworkSimplex Algorithm

T.A. Heba Essam Heba.Essam at cis.asu.edu.eg
Wed Jun 12 10:28:24 CEST 2013


Dear Peter, 

Sorry for giving you hard time with a large snippet of code.

I'm working on VS 2010/VC++ running on Windows 7.

Kindly find attached my piece of code and a snapshot of the errors list.

Note: as VS 2010 is 32-bit while LEMON is 64, can this cause the problem by any means? if yes, why it only appears while using "networksimplex" and goes smoothly while using other features like graphs, nodes, arcs, maps....etc

Thanks and best regards,
Heba
________________________________________
From: Kovács Péter [kpeter at inf.elte.hu]
Sent: Wednesday, June 12, 2013 7:20 AM
To: T.A. Heba Essam
Cc: lemon-user at lemon.cs.elte.hu
Subject: Re: [Lemon-user] Using NetworkSimplex Algorithm

Dear Heba,

> Thanks for willing to help. I had a look at your example, sounds like I'm doing the right thing.

Could you compile and run these examples correctly?

> I'm afraid I have a problem far from using NetworkSimplex. Kindly, have a look at my function that demonstrates the graph and calls the algorithm.

I had a look at it, but I can't reproduce such an error according to
your code snippet. Could you send a shorter and simpler example that is
a full source file (similarly to the ones I sent) and does not compile
for you? What compiler do you use?

Additional notes on using NetworkSimplex:

1. The arc costs in your code are of double type. However,
NetworkSimplex uses int type internally unless you explicitly specify
other flow and/or capacity type. For example:
NetworkSimplex<ListDigraph, int, double> ns(myGraph);

2. If lower bounds are all zero, you need not specify them (cf.
network_simplex_example1.cpp).

Best regards,
Peter


> ________________________________________
> From: Kovács Péter [kpeter at inf.elte.hu]
> Sent: Tuesday, June 11, 2013 11:20 AM
> To: T.A. Heba Essam
> Cc: lemon-user at lemon.cs.elte.hu
> Subject: Re: [Lemon-user] Using NetworkSimplex Algorithm
>
> Dear Heba Essam,
>
> I attach simple code examples that demonstrate the usage of
> NetworkSimplex. I hope they help you. Otherwise, it would be better if
> you could send a minimal code example with which the error can be
> reproduced.
>
> The first example file builds up a small network and executes the
> algorithm on it, while the second one reads a minimum cost flow problem
> from a text file given in DIMACS format (e.g. the attached example.dim
> file).
> For more information about DIMACS format, see:
> http://lpsolve.sourceforge.net/5.5/DIMACS_mcf.htm
>
> Best regards,
> Peter
>
>
> On 2013.06.11. 11:40, T.A. Heba Essam wrote:
>> Dear all,
>>
>> I'm trying to use the networksimplex algorithm but as some tutorial
>> links are down, I'm afriad I'm mis-using it.
>>
>> When I try to define a network simplex object as
>> NetworkSimplex<ListDigraph> ns(myGraphg);
>>
>> it gives me error C2205: 'IRegistrarBase `RTTI Type Descriptor'' :
>> cannot initialize extern variables with block scope
>>
>> Am I missing something?
>>
>> Please Help.
>>
>> Thanks,
>> Heba Essam
>>
>>
>> _______________________________________________
>> Lemon-user mailing list
>> Lemon-user at lemon.cs.elte.hu
>> http://lemon.cs.elte.hu/mailman/listinfo/lemon-user
>>



-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: NetworkSimplex Test.cpp
URL: <http://lemon.cs.elte.hu/pipermail/lemon-user/attachments/20130612/ca64db6c/attachment-0001.ksh>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Error List.png
Type: image/png
Size: 79494 bytes
Desc: Error List.png
URL: <http://lemon.cs.elte.hu/pipermail/lemon-user/attachments/20130612/ca64db6c/attachment-0001.png>


More information about the Lemon-user mailing list