help-glpk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-glpk] Calling the same LP repeatedly - segmentation fault


From: Andrew Makhorin
Subject: Re: [Help-glpk] Calling the same LP repeatedly - segmentation fault
Date: Sat, 07 May 2016 07:04:38 +0300

> I have all the attached files in examples directory in GLPK and I used
> these commands:
> 
> gcc -c May5.c
> 
> gcc -o go May5.c new_ssp.c -lglpk -lm
> 
> ./go
 
> This should be able to reproduce the problem I am seeing. Thank you
> very much! Any help/direction is greatly appreciated. I need to
> understand what I am doing wrong to move forward with my simulations.
> 

Doesn't work because of error in the mathprog model:

[...]
Border router 46 does not advertise the prefix 10
Border router 48 does not advertise the prefix 10
binary search loop: 0
low is: 0.000000, high is: 1.000000, and bound t is: 0.500000
calling GAP now
Entered GAP now
Try to create problem
Try to create model translator
Able to create problem successfully
Reading model section from LP.mod...
74 lines were read
Reading data...
Reading data...
Reading data...
Reading data...
Reading data...
Reading data...
Writing tout...
Reading data...
Reading data...
Generating MAXLU...
Generating constr...
Generating one...
Generating expand...
Generating lim...
LP.mod:71: clash[0,1,1] out of domain
glp_mpl_build_prob: invalid call sequence
Error detected in file api/mpl.c at line 90
Aborted


> I did try that too to deallocate the problem, I just didn't 
> post it here. Anyway, I am trying to figure out why alloc.c is causing
> a 
> segmentation fault. 
> 

I'd suggest you to remove (comment out) calls to all routines that
dellocate the memory (i.e. like free, glp_free, glp_free_env,
glp_delete_prob, etc.) and see what happens. In any case please consult
the glpk reference manual (doc/glpk.pdf) to use glpk api routines in a
correct way.


Andrew Makhorin






reply via email to

[Prev in Thread] Current Thread [Next in Thread]