From: Rehan A. <ra...@st...> - 2012-06-29 08:25:38
|
Hi, As mentioned in the guide, maximize statement is internally converted to a minimize statement and hence the value in the output is something else. Is there a way to retrieve the actual value without affecting program's performance? I am using clingcon, and my program has the following maximize statement: #maximize[included(X):value(X,V)=V]. I have tried the following, but it significantly reduces performance: net_value(N) :- N = #sum[included(X):value(X,V)=V]. Thank you, Rehan. |
From: Max O. <ost...@cs...> - 2012-06-29 10:18:26
|
If you are really using clingcon (not clingo) you can use a $maximize statement over integer variables instead. Otherwise, your workaround has to ground the rule for every possible result of the sum. This can affect grounding, but should not affect solving significantly. Best, Max On 06/29/2012 10:25 AM, Rehan Aziz wrote: > Hi, > > As mentioned in the guide, maximize statement is internally converted > to a minimize statement and hence the value in the output is something > else. Is there a way to retrieve the actual value without affecting > program's performance? > > I am using clingcon, and my program has the following maximize statement: > > #maximize[included(X):value(X,V)=V]. > > I have tried the following, but it significantly reduces performance: > > net_value(N) :- N = #sum[included(X):value(X,V)=V]. > > Thank you, > Rehan. > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > > > _______________________________________________ > Potassco-users mailing list > Pot...@li... > https://lists.sourceforge.net/lists/listinfo/potassco-users > |
From: Roland K. <kam...@cs...> - 2012-06-29 10:51:30
Attachments:
signature.asc
|
On Friday 29 June 2012 10:25:26 Rehan Aziz wrote: > Hi, > > As mentioned in the guide, maximize statement is internally converted to a > minimize statement and hence the value in the output is something else. Is > there a way to retrieve the actual value without affecting program's > performance? > > I am using clingcon, and my program has the following maximize statement: > > #maximize[included(X):value(X,V)=V]. > > I have tried the following, but it significantly reduces performance: > > net_value(N) :- N = #sum[included(X):value(X,V)=V]. Atm, there is only a negative answer regarding the gringo language fragment. The problem is rooted in the lparse output format adopted by gringo, which has no representation for maximize constraints. Regards, Roland |