Opened 8 years ago

Closed 8 years ago

#14395 closed defect (fixed)

Bug in MixedIntegerLinearProgram.polyhedron

Reported by: ncohen Owned by: ncohen
Priority: major Milestone: sage-5.10
Component: linear programming Keywords:
Cc: dimpase Merged in: sage-5.10.beta1
Authors: Nathann Cohen Reviewers: Dmitrii Pasechnik
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges


Small problem in polyhedron when variables are unbounded in both direction (and not necessarily positive)

sage: p = MixedIntegerLinearProgram()                                                                                                                                              
sage: x,y = p['x'], p['y']                                                                                                                                                         
sage: p.set_min(x,None)                                                                                                                                                            
sage: p.set_min(y,None)                                                                                                                                                            
sage: p.add_constraint( x <= 1 )                                                                                                                                                   
sage: p.add_constraint( x >= -1 )                                                                                                                                                  
sage: p.add_constraint( y <= 1 )                                                                                                                                                   
sage: p.add_constraint( y >= -1 )                                                                                                                                                  
sage: p.polyhedron()
TypeError: bad operand type for unary -: 'NoneType'


Attachments (1)

trac_14395.patch (1.7 KB) - added by ncohen 8 years ago.

Download all attachments as: .zip

Change History (5)

Changed 8 years ago by ncohen

comment:1 Changed 8 years ago by ncohen

  • Status changed from new to needs_review

comment:2 Changed 8 years ago by dimpase

  • Status changed from needs_review to positive_review
  • Type changed from enhancement to defect

comment:3 Changed 8 years ago by jdemeyer

  • Reviewers set to Dmitrii Pasechnik

comment:4 Changed 8 years ago by jdemeyer

  • Merged in set to sage-5.10.beta1
  • Resolution set to fixed
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.