conjure-cp / conjure

Conjure: The Automated Constraint Modelling Tool
Other
96 stars 24 forks source link

08 Vessel Loading param refinement fails on function from sets to ints #178

Closed ozgurakgun closed 7 years ago

ozgurakgun commented 11 years ago

Originally reported by: Bilal Hussain (Bitbucket: Bilalh, GitHub: Bilalh)


for 08 Vessel Loading

language Essence 1.3

letting n_upper be 3

letting deck_width   be 5 
letting deck_length  be 5
letting n_containers be 4
letting n_classes    be 2

letting width  be function( 1 --> 5, 2 --> 2,  3 --> 3 )
letting length be function( 1 --> 1, 2 --> 4,  3 --> 4 )
letting class  be function( 1 --> 1, 2 --> 1,  3 --> 1)

letting separation be function ( {1,2} --> 0 )

gives error. (seems to be the function from sets to ints that causing the error)

[refineParam] prob008.essence prob008-df/0001.eprime 1.param
conjure: missing case in RedArrow.workhorse
name: separation_AsReln_RelationAsSet_Set~ExplicitVarSize_tuple2_tuple1
domain: set (size 2) of int(1..2)
        domain.set.attributes.attrCollection.attribute.nameValue.name.reference := size
        domain.set.attributes.attrCollection.attribute.nameValue.value.value.literal := 2
        domain.set.inner.domain.int.ranges.range.fromTo.value.literal := 1
        domain.set.inner.domain.int.ranges.range.fromTo.value.literal := 2
value: {1, 2}
       value.set.values.value.literal := 1
       value.set.values.value.literal := 2
repr: Nothing

ozgurakgun commented 11 years ago

Original comment by Bilal Hussain (Bitbucket: Bilalh, GitHub: Bilalh):


This might be a different bug but using the param fails in SR, (the param has been committed to CP2013 repo in prob008)

[refineParam] prob008.essence prob008-df/0001.eprime 1.param
[Conjure] Created file (at 2013-04-21 21:40:31) prob008-df/0001-1-1.eprime-param
[savilerow] prob008.essence prob008-df/0001.eprime 1.param
ERROR: At index 0 of constant matrix class_Matrix1D, actual size does not match the matrix dimensions.
ERROR: Failed type checking after substituting in lettings.
[minionStats] prob008.essence prob008-df/0001.eprime 1.param
ozgurakgun commented 11 years ago

Original comment by Özgür Akgün (Bitbucket: ozgurakgun, GitHub: ozgurakgun):


should fix #177. I couldn't double check, sorry. lmk know it doesn't work.