• Aucun résultat trouvé

Gelfond-Zhang aggregates as propositional formulas

N/A
N/A
Protected

Academic year: 2021

Partager "Gelfond-Zhang aggregates as propositional formulas"

Copied!
20
0
0

Texte intégral

(1)

HAL Id: hal-02452472

https://hal.archives-ouvertes.fr/hal-02452472

Submitted on 23 Jan 2020

HAL is a multi-disciplinary open access

archive for the deposit and dissemination of

sci-entific research documents, whether they are

pub-lished or not. The documents may come from

teaching and research institutions in France or

abroad, or from public or private research centers.

L’archive ouverte pluridisciplinaire HAL, est

destinée au dépôt et à la diffusion de documents

scientifiques de niveau recherche, publiés ou non,

émanant des établissements d’enseignement et de

recherche français ou étrangers, des laboratoires

publics ou privés.

Gelfond-Zhang aggregates as propositional formulas

Pedro Cabalar, Jorge Fandinno, Torsten Schaub, Sebastian Schellhorn

To cite this version:

Pedro Cabalar, Jorge Fandinno, Torsten Schaub, Sebastian Schellhorn.

Gelfond-Zhang

ag-gregates as propositional formulas.

Artificial Intelligence, Elsevier, 2019, 274, pp.26-43.

(2)

OATAO is an open access repository that collects the work of Toulouse

researchers and makes it freely available over the web where possible

Any correspondence concerning this service should be sent

to the repository administrator: tech-oatao@listes-diff.inp-toulouse.fr

This is an author’s version published in: http://oatao.univ-toulouse.fr/24791

To cite this version:

Cabalar, Pedro and Fandinno, Jorge and Schaub, Torsten

and Schellhorn, Sebastian Gelfond-Zhang aggregates as

propositional formulas. (2019) Artificial Intelligence, 274.

26-43. ISSN 0004-3702

Official URL:

http://dx.doi.org/10.1016/j.artint.2018.10.007

(3)

Gelfond-Zhang aggregates as propositional formulas

*

Pedro Cabalar

a,*, 1•

Jorge

Fandinno

a,

d

,

2

Torsten Schaub

b,

c

,*,

3

.

4 3

,

Sebastian Schellhorn

b,

Universiry ofCorunna, Spain

b Universiry of Potsdam, Gennany

c /NRJA, Rennes. France

d /RIT, Université de Toulouse, CNRS, Toulouse, France

Keywords:

Aggregares

Answer Set Programming

1. Introduction

ABSTRACT

Answer Set Programming (ASP) has become a popular and widespread paradigm for

practical Knowledge Representation thanks to its expressiveness and the available enhance­

ments of its input language. One of such enhancements is the use of aggregates, for

which different semantic proposais have been made. In this paper, we show that any

ASP aggregate interpreted under Gelfond and Zhang's (GZ) semantics c.an be replaced

( under strong equivalence) by a propositional formula. Restricted to the original GZ

syntax, the resulting formula is reducible to a disjunction of conjunctions of literais

but the formulation is still applicable even when the syntax is extended to allow for

arbitrary formulas (including nested aggregates) in the condition. Once GZ-aggregates are

represented as formulas, we establish a formai comparison ( in terms of the logic of Here­

and-There) to Ferraris' (F) aggregates, which are defined by a different formula translation

involving nested implications. ln particular, we prove that if we replace an F-aggregate

by a GZ-aggregate in a rule head, we do not (ose answer sets (although more can be

gained). This extends the previously known result that the opposite happens in rule bodies,

i.e., replacing a GZ-aggregate by an F-aggregate in the body may yield more answer sets.

Finally, we characterize a class of aggregates for which GZ- and F-semantics coïncide.

Knowledge Representation and Reasoning (KRR) has constitute

d

one of the central areas of Artificial Intelligence since its

very beginning an

d

, in parti

c

ular, logic-based approa

c

hes have attracte

d

most of the interest in the literature. Although

"' This is an extended version of a conference paper at the 14th International Conference on logic Programming and Nonmonotonic Reasoning. Espoo, Finland, July 3-6, 2017, where it received a best technical paper award.

* Corresponding authors.

E-mail addresses: cabalar@udc.es (P. Cabalar), jorge.fandino@udc.es, jorge.fandinno@irit.fr U- Fandinno), torsten@cs.uni-potsdam.de (T. Schaub), seschell@cs.uni-potsdam.de (S. Schellhorn).

1 Panially supponed by grants GPC-ED431B 2016/035 and 2016-2019 ED431G/01 (Xunta de Galicia, Spain), and TIN 2013-42149-P, TIN 2017-84453-P (MINECO, Spain).

2 Funded by the Centre International de Mathématiques et Informatique de Toulouse through contract ANR-11-LABEX-0040-0MI within the program ANR-11-IDEX-0002-02.

3 This work was panially funded by DFG gram SCHA 550/9.

4 Affiliated with the School of Computing Science at Simon Fraser University, Canada, and the lnstirute for Integrated and Intelligent Systems at Griffith University, Australia.

(4)

classicallogiccopeswithmanyoftheusualdesiderataforKRRsuchassimplicity,clearsemanticsorwell-knowninference methodsandtheirassociatedcomplexity,itwas soondetectedtofall shortforpracticalpurposes indifferentaspects.For instance, one crucialfeature in manyKRR scenarios, evenin extremelysimple ones, is the need todraw conclusions in absenceofinformation,somethingimpossibleinclassicallogicduetoitsmonotonicinferencerelation.Asaresult,sincethe introductionofthethreewell-knownapproaches,circumscription [1],defaultlogic [2] and modalnon-monotonic logics [3] in thehistorical specialissueofthe ArtificialIntelligence journalin1980, Non-MonotonicReasoning(NMR)hascentered great partofthediscussioninKRR.

Nowadays,AnswerSetProgramming (ASP [4])hasbecomeanestablishedproblem-solvingparadigmandaprimecandidate forpracticalKRR.Thereasonsforthissuccessaremanifold.Themostobviousoneistheavailabilityofeffectivesolvers [5,6] and a growing list of covered application domains [7]. A probably equally important reason is its declarative semantics, havingbeengeneralized fromtheoriginal stablemodels [8] of normallogicprogramsup toarbitraryfirst-order [9,10] and infinitary [11] formulas.SeverallogicalcharacterizationsofASPhavebeenobtained,amongwhichEquilibriumLogic [12] and its monotonic basis, the intermediate logic of Here-and-There (HT), are arguablythe most prominentones. These general-izations haveallowedustounderstandASPasagenerallogicalframeworkforNMR.Finally,athirdrelevantcauseofASP’s success lies in its flexible specification language [13],offering constructs especially useful forpractical KRR. Some of its distinctiveconstructsareaggregates, allowingforoperationsonsets ofelementssuchascountingthenumberofinstances forwhicha formula holds,oraddingall theinteger valuesforsome predicateargument.Tounderstandtheutility ofthis kindofconstraintsthinkaboutrepresentinginfirst-orderlogic, forinstance,that predicate p issatisfiedbyatleastn

=

3 differentindividuals.Atypicalformalizationwouldlooklike:

x

y

z

(

p

(

x

)

p

(

y

)

p

(

z

)

x

=

y

y

=

z

x

=

z

)

This pattern becomes obviously cumbersome when increasing the number n of individuals, as the number of required inequalities combinatorially explodes.Moreover, the formulaabove cannot be constructed ifn is an arbitraryparameter whose value isnot known beforehand.On theother hand, thissamemeaning can be simply capturedby a naturalASP aggregateoftheform

count

{

X

:

p

(

X

)

}

n.

Unfortunately, there is no clear agreement on the expected behavior of aggregates in ASP, and several alternative seman-tics have been defined [14–19], among which perhaps Ferraris’ [17] and Faber et al.’s [18] are the two more consolidatedonesduetotheirrespectiveimplementationsintheASPsolvers

clingo

[5] and

DLV

[6].Althoughthesetwo approachesmaydifferwhentheaggregatesareinthescopeofdefaultnegation,theycoincidefortherestofcases(likeall theexam-plesinthispaper),evenwhenaggregatesareinvolvedinrecursivedefinitions.Ferraris’(F-)aggregatesadditionally showaremarkable feature: theycan be expressed as propositional formulasin the logic of HT, something that greatly simplifiestheirformaltreatment.Toillustratethis,letusexplorethesimplerule:

p

(

a

)

← count{

X

:

p

(

X

)

} ≥

n

,

(1)

where p

(

a

)

recursivelydependsonthenumberofatomsoftheform p

(

X

)

.Supposefirstthatn

=

1.Sincethedomainonly containsa,

count

{

X

:

p

(

X

)

} ≥

1 is trueiff p

(

a

)

holds.ThisiscapturedinFerraris’translationof (1) for n

=

1 thatamounts to p

(

a

)

p

(

a

)

,a tautology whoseonlystable modelis

.Supposenow thatn

=

0. Then,the aggregateisconsidered as tautologicaland theHT-translation of(1) corresponds to p

(

a

)

whoseunique stable modelis

{

p

(

a

)

}

. Finally,asone moreelaboration,assumen

=

1 andsupposeweaddthefactp

(

b

)

.Then,(1) becomestheformula p

(

a

)

p

(

a

)

p

(

b

)

that, togetherwithfact p

(

b

)

,isHT-equivalentto:

p

(

b

).

p

(

a

)

p

(

a

).

p

(

a

)

p

(

b

).

(2) Thisresultsintheuniquestablemodel

{

p

(

a

),

p

(

b

)

}

.

Recently, GelfondandZhang [19] (GZ)proposed a morerestrictive interpretationofrecursive aggregatesthat imposes the so-called ViciousCirclePrinciple, namely, “noobjectorpropertycanbeintroducedbythedefinitionreferringtothetotality ofobjectssatisfyingthisproperty.” According to thisprinciple, ifwe havea program whose onlydefinition for p

(

a

)

is (1), we mayleave p

(

a

)

false,butwe cannot be forcedtoderive its truth,since itdependson aset ofatoms

{

X

:

p

(

X

)

}

that includesp

(

a

)

itself.Inthisway,ifn

=

1,theGZ-stablemodelfor(1) isalso

,asthereisnoneedtoassume p

(

a

)

.However, ifwe have n

=

0, we cannot leave p

(

a

)

false anymore (the rule wouldhavea true body anda false head) and, atthe same time, p

(

a

)

cannot become truebecause it dependsona vicious circle. Something similar happensforn

=

1 when addingfact p

(

b

)

.Asshownin [20],GZ-programsarestrongerthanF-programs inthesense that,whenthey representthe sameproblem,anyGZ-stablemodelisalsoan F-stablemodel,buttheoppositemaynothold(aswesawintheexamples above).Withoutenteringadiscussionofwhichsemanticsismoreintuitiveorsuitableforpracticalpurposes,oneobjective disadvantageofGZ-aggregatesisthattheylackedalogicalrepresentationsofar;theywereexclusivelydefinedintermsof areduct,somethingthatmadetheirformalanalysismorelimitedandthecomparisontoF-aggregatesmorecumbersome.

Inthispaper,weshowthat,infact,itisalsopossibletounderstandaGZ-aggregate asapropositionalformula,classically equivalent tothe F-aggregate translation,butwitha differentmeaning in HT.Forinstance,theGZ-translation for (1) with

(5)

n

=

1 coincideswiththeF-encoding p

(

a

)

p

(

a

)

,butifwechangeton

=

0 wegettheformulap

(

a

)

p

(

a

)

∨ ¬

p

(

a

)

whose antecedentisvalidinclassicallogic,butnotin HT.Infact,thewholeformulaisHT-equivalenttotheprogram:

p

(

a

)

p

(

a

).

p

(

a

)

← ¬

p

(

a

).

This makesit nowobviousthat thereisnostablemodel.Similarly, whenwe addfact p

(

b

)

andn

=

1,theGZ-translation eventuallyleadstothepropositionalprogram:

p

(

b

).

p

(

a

)

← ¬

p

(

a

)

p

(

b

).

p

(

a

)

p

(

a

)

∧ ¬

p

(

b

).

p

(

a

)

p

(

a

)

p

(

b

).

(3) Again, it is classically equivalent to the F-translation(2), but quite different in logic programming, where the left rules enforcethenon-existenceofstable models.

Therestofthepaperisorganizedasfollows.Inthenext section,we reviewsomebasicdefinitionsthatwillbeneeded through the paper.In Section 3,we presenta generalization ofFerraris’reductthat covers GZ-aggregatesandshow that the latter canbe replaced, under strongequivalence, by a propositional formula. InSection 4, we show that, ingeneral, GZ-aggregatesarestrongerthanF-aggregatesinHTand,asaresult,characterize the effectofreplacingsomeoccurrenceof a GZ-aggregateby acorrespondingF-aggregate. Wealsoidentifyafamilyofaggregatesinwhichbothsemantics coincide. InSection5,weliftthefragmentinwhichbothsemanticscoincidetotheirfirst-orderlanguages:

A

log and

gringo

[21]. Finally,Section6concludesthepaper.

2. Background

We beginby introducing some basic definitionsused inthe restof thepaper. Let

L

be some syntactic language and assume we have adefinition ofstablemodel foranytheory



L

inthat syntax. Moreover, letSM

()

denote thestable models of



.Twotheories

,



arestronglyequivalent,written



s



,iffSM

(

∪ )

=

SM

(

∪ )

foranytheory



.We will providea strongerdefinitionof

s forexpressions in

L

.Let

(

ϕ

)

denotesometheorywithadistinguishedoccurrence ofasubformula

ϕ

andlet

(ψ)

be theresultofreplacingthatoccurrence

ϕ

by

ψ

in

(

ϕ

)

.Twoexpressions

ϕ

, ψ

L

are said to be stronglyequivalent,also written

ϕ

s

ψ

, when

(

ϕ

)

s

(ψ)

foran arbitrary5

(

ϕ

)

L

. We alsorecall next some basicdefinitions andresultsrelatedtothe logicofHere-and-There (HT). LetAt be aset ofgroundatomscalledthe propositionalsignature.Apropositionalformula

ϕ

isdefinedusingthegrammar:

ϕ

::= ⊥ |

a

|

ϕ

ϕ

|

ϕ

ϕ

|

ϕ

ϕ

for any a

At

.

We use Greek letters

ϕ

and

ψ

andtheir variants to stand forpropositional formulas. We define the derived operators

¬

ϕ

def

= (

ϕ

→ ⊥)

,

ϕ

↔ ψ

def

= (

ϕ

→ ψ)

∧ (ψ →

ϕ

)

and

def

= ¬⊥

.

Aclassicalinterpretation T isasetofatomsT

At.Wewrite

|=

cltostandbothforclassicalsatisfactionandentailment, and

clrepresentsclassicalequivalence.AnHT-interpretation isapair



H

,

T



ofsetsofatomsH

T

At.

Definition1(HT-satisfaction).An interpretation



H

,

T



satisfies a formula

ϕ

, written



H

,

T



|=

ϕ

, if any of the following recursiveconditionsholds:

• 

H

,

T

 |= ⊥

• 

H

,

T

 |=

p iff p

H

,

for any atom p

• 

H

,

T

 |=

ϕ1

ϕ2

iff



H

,

T

 |=

ϕ1

and



H

,

T

 |=

ϕ2

• 

H

,

T

 |=

ϕ1

ϕ2

iff



H

,

T

 |=

ϕ1

or



H

,

T

 |=

ϕ2

• 

H

,

T

 |=

ϕ1

ϕ2

iff both:

(i) T

|=cl

ϕ1

ϕ2

and

(ii)



H

,

T

 |=

ϕ1

or



H

,

T

 |=

ϕ2

2

Itisnotdifficulttoseethat



T

,

T



|=

ϕ

iffT

|=

cl

ϕ

.A(propositional)theory isasetofpropositionalformulas.An interpre-tation



H

,

T



isamodel ofatheory



when



H

,

T



|=

ϕ

forall

ϕ

∈ 

.Atheory



entails aformula

ϕ

,written



|=

ϕ

,when allmodelsof



satisfy

ϕ

.Twotheories



,



are(HT)-equivalent,written



≡ 

,iftheysharethesamesetofmodels. Definition2(Equilibrium/stablemodel).Atotalinterpretation



T

,

T



isanequilibriummodel ofaformula

ϕ

iff



T

,

T



|=

ϕ

and thereisno H

T suchthat



H

,

T



|=

ϕ

.Ifso,wesaythat T isastablemodel of

ϕ

.

2

5 Notethat,forarbitrarylanguagesandsemantics,thisdefinitionisstrongerthanusual,asitrefersto

any subformula replacement and

notjust conjunc-tionsofformulas,asusual.Forinstance,ϕalsoimplies{ϕα}≡s{ψ ⊗α}foranybinaryoperator⊗inourlanguage.WhenLisalogicallanguage and≡samountstoequivalenceinHT(oranylogicwithsubstitutionofequivalents)thedistinctionbecomesirrelevant.

(6)

Proposition1.ThefollowingaregeneralpropertiesofHT: i) if



H

,

T



|=

ϕ

then



T

,

T



|=

ϕ

(i.e.,T

|=

cl

ϕ

) ii)



H

,

T



|= ¬

ϕ

iffT

|=

cl

¬

ϕ

.

2

Definition3(Ferraris’reduct).Thereductofaformula

ϕ

withrespecttoaninterpretationT ,written

ϕ

T,isdefinedas:

ϕ

T def

=

if T

|=cl

ϕ

a if

ϕ

is some atom a

T

ϕ

T

1

ϕ

2T if T

|=cl

ϕ

and

ϕ

= (

ϕ

1

ϕ

2

)

for some

⊗ ∈ {∧, ∨, →}

2

Thatis,

ϕ

T istheresultofreplacingby

eachmaximalsubformula

ψ

of

ϕ

s.t. T

|=

cl

ψ

.

Proposition2(Lemma 1in [22]).ForanypairofinterpretationsH

T andany

ϕ

:H

|=

cl

ϕ

Tiff



H

,

T



|=

ϕ

.

2

Asiswell-known, strongequivalenceforpropositionalformulascorresponds toHT-equivalence [23],that is,

ϕ

s

ψ

iff

ϕ

≡ ψ

inthatlanguage.ThefollowingresultfollowsfromCorollary 3in [24].

Proposition3.If

ϕ

|= ψ

and

ϕ

cl

ψ

,thenSM

(

ϕ

)

SM

(ψ)

.

2

Inother words,if

ϕ

isstrongerthan

ψ

inHT(andso,inclassical logictoo),butthey furtherhappento beclassically equivalent,then

ϕ

isweakerwithrespecttostablemodels.Asanexample,notethat

(

p

q

)

|= (¬

p

q

)

.Astheyare clas-sically equivalent,SM

(

p

q

)

SM

(

¬

p

q

)

whichisnotsuch astrongresult. However,since HT-entailment ismonotonic withrespecttoconjunction,itfollowsthat

(

p

q

)

γ

|= (¬

p

q

)

γ

alsoholdsforany

γ

,andthus,ifwereplacea dis-junctiverule

(

p

q

)

by

(

¬

p

q

)

inanyprogramwemaylosesomestablemodels,buttheremainingarestillapplicableto

(

p

q

)

.Wecangeneralizethisbehaviornotonlyonconjunctions,butalsotocoverthereplacementofanysubformula

ϕ

. We saythat an occurrence

ϕ

ofa formulaispositive in a theory

(

ϕ

)

ifthenumberof implicationsin

(

ϕ

)

containing occurrence

ϕ

intheantecedentiseven.Itiscallednegative otherwise.

Proposition4.Let

ϕ

and

ψ

betwoformulassatisfying

ϕ

|= ψ

and

ϕ

cl

ψ

.Then: i) SM

((

ϕ

))

SM

((ψ))

foranytheory

(

ϕ

)

whereoccurrence

ϕ

ispositive; ii) SM

((

ϕ

))

SM

((ψ))

foranytheory

(

ϕ

)

whereoccurrence

ϕ

isnegative.

2

Backtotheexample,notethat

(

p

q

)

occurspositivelyin

(

p

q

)

γ

andso,

(

¬

p

q

)

γ

hasasubsetofstablemodels. Ontheotherhand,itoccursnegativelyin

(

p

q

)

γ

,andso,

(

¬

p

q

)

γ

hasasupersetofstablemodels.

3. Aggregatesasformulas

Todealwithaggregates,weconsiderasimplifiedfirst-order6 signature



= 

C, A, P

formedbythreepairwisedisjoint setsrespectivelycalledconstants,aggregatesymbols andpredicatesymbols.Anarithmeticterm isacombinationofnumerical constants, variablesandarithmetic operatorsbuiltinthe usualway.A term iseithera constantc

C

,a variable X or an arithmetic term.We usethevector overlinetorepresenttuplesof terms,suchas



t,andwrite

|

t

|

tostandforthe tuple’s arity. As usual, a predicateatom isan expression ofthe form p

(

t

)

where



t isa tuple ofterms; an arithmeticatom is an expressionoftheformt

t witht andt arithmetictermsand

≺∈ {=, =, ≤, ≥, <, >}

anarithmeticrelation.Aregularatom iseitherapredicateatomoranarithmeticatom.An(aggregate)formula

ϕ

isrecursivelydefinedbythefollowinggrammar:

ϕ

::= ⊥ |

a

|

f

{ 

X

:

ϕ

} ≺

t

|

f

{

c

:

ϕ

, . . . ,



c

:

ϕ

} ≺

t

|

ϕ

ϕ

|

ϕ

ϕ

|

ϕ

ϕ

where a is regular atom, f

A

is an aggregate symbol, X is



a non-empty tuple of variables,



c is a non-empty tuple ofconstants,

≺∈ {=,

=,

≤,

≥,

<,

>

}

is an arithmetic relation,andt isan arithmetic term. A (aggregate)theory isa set of aggregateformulas.Aswe cansee,we distinguishtwotypesofaggregates: f

{ 

X

:

ϕ

} ≺

t calledGZ-aggregates (or setatoms); and f

{

c1

:

ϕ

1

, . . . ,



cm

:

ϕ

m

} ≺

t,with all



ci of samearity, calledF-aggregates.This syntactic distinctionrespects the original syntax7 alsoturnsout tobe convenientforcomparisonpurposes,since we canassigna differentsemanticsto each type of aggregate withoutambiguity. An important observationis that,in our generallanguage, it ispossible to nest GZ and F-aggregatesin a completely arbitraryway,since

ϕ

and

ϕ

1

,

. . . ,

ϕm

inside bracketsare aggregate formulas intheir turn.

6 Anextensiontoafullfirst-orderlanguageisunderdevelopment. 7 Ferrarisactuallyusesϕ

(7)

Achieving thisgeneralization isnot surprising,onceaggregatescan beseenaspropositionalformulas.AGZ-formula (resp. F-formula) is one inwhich all its aggregatesare GZ-aggregates (resp. F-aggregates). We sometimes informally talkabout rules (resp.programs)insteadofformulas(resp.theories)whenthesyntaxcoincideswiththeusualinlogicprogramming.

The technical treatment of F-aggregates is directly extracted from [17], so the focus in this section is put on GZ-aggregates, where our contribution lies.One oftheir distinctive features is the use of variables X .



In fact, a formula

ϕ

inside A

=

f

{ 

X

:

ϕ

}

t (calledthe condition of A) normallycontains occurrencesof



X ,so weusually write itascond

( 

X

)

. Moreover, theoccurrencesofvariables X in



A aresaidtobebound to A.Avariableoccurrence X inaformula

ϕ

isfree if itisnotboundtoanyGZ-aggregatein

ϕ

.Anatom iseitheraregularatom(predicateorarithmetic atom)oran aggregate. A (regular)literal is eithera (regular) atom a (positive literal)or its defaultnegation not a (negativeliteral). Apredicate atom p

(

t

)

issaid to be ground iff all its terms are constants



t

C

|t|; an arithmetic atom t

t issaid to be ground iff t and t are numbers; andan aggregate atom f

{. . . } ≺

t issaid tobe ground iff itcontains no free variables8 andt is a number. We write At

(C,

P)

to stand forthe set of groundatomsfor predicates

P

and constants

C

. A theory is said to be ground iff all atomsoccurring init are ground. We define thegrounding ofa formula

ϕ

( 

X

)

withfree variables X as



expected:

Gr

(

ϕ

( 

X

))

def

= {

ϕ

(



c

)

| 

c

C

| X|

}

where

ϕ

(



c

)

is the result ofreplacing all occurrences ofthe variables X in



ϕ

( 

X

)

by the constants in



c andevaluating all arithmetic terms.Similarly, by

Gr

()

def

=



{Gr(

ϕ

( 

X

))

|

ϕ

( 

X

)

∈ }

we denote the groundingofanytheory



.UntilSection5,we willexclusivelydealwithgroundtheories.Thisisnotalimitation,since a non-groundformula

ϕ

( 

X

)

insometheorycanbeunderstoodasanabbreviationofitsgrounding

Gr

(

ϕ

( 

X

))

,asusual.Given a



setofformulasS,wewrite



S and



S tostandfortheirconjunctionanddisjunction,respectively;welet



∅ = ⊥

and

∅ =

.

To definethe semantics,we assume thatfor allaggregate symbols f

A

andarities m

1,there existsa predefined associatedpartialfunction

ˆ

fm

:

2C

m

→ Z

that,foreachset S ofm-tuplesofconstants,eitherreturnsanumber

ˆ

fm

(

S

)

oris undefined.Thispredefinedvalueistheexpectedonefortheusualaggregatefunctions

sum

,

count

,

max

, etc.Forexample, foraggregate symbol

sum

andaritym

=

1 the functionreturns theaggregateaddition whenthesetconsistsof(1-tuples of) integer numbers. Forinstance,

sum



1

(

{

7

,

2

,

4

})

=

5 and

sum



1

(

∅)

=

0 but

sum



1

(

{

7

,

a

,

3

,

b

})

is undefined. For integer aggregatefunctionsofaritym

>

1,weassumethattheaggregateisappliedontheleftmostelementsinthetupleswhenall ofthemareinteger,sothat,forinstance,

sum



2

(

{

7

,

a

,



2

,

b

,



2

,

a

})

=

11.Weomitthearitywhenclearfromthe context.

Aclassicalinterpretation T isasetofgroundatomsT

At

(

C,

P)

.

Definition4.AclassicalinterpretationT satisfies aformula

ϕ

,denotedbyT

|=

cl

ϕ

,whenthefollowingrecursiveconditions hold:

T

|=cl

T

|=cl

p

(



c

)

iff p

(



c

)

T for any ground atom p

(



c

)

T

|=cl

f

{ 

X

:

cond

( 

X

)

} ≺

n iff

ˆ

f| X|

{ 

c

C

| X|

|

T

|=cl

cond

(



c

)

}

has some value k

∈ Z

and k

n under the usual meaning of arithmetic relation

T

|=cl

f

{

c1

:

ϕ1

, . . . ,

c



m

:

ϕ

m} ≺n iff

ˆ

f|c1|

{ 

ci

|

T

|=cl

ϕ

i

}

has some value k

∈ Z

and k

n

,

again, under its usual meaning

T

|=cl

ϕ1

ϕ2

iff T

|=cl

ϕ1

and T

|=cl

ϕ2

T

|=cl

ϕ1

ϕ2

iff T

|=cl

ϕ1

or T

|=cl

ϕ2

T

|=cl

ϕ1

ϕ2

iff T

|=cl

ϕ1

or T

|=cl

ϕ2

WesaythatT isa(classical)model ofatheory



iffT

|=

cl

ϕ

forall

ϕ

∈ 

.

2

GiveninterpretationT ,wedivideanytheory



intothetwodisjointsubsets:



+T def

= {

ϕ

∈  |

T

|=cl

ϕ

}



T def

=  \ 

+T

thatis,theformulasin



satisfiedbyT andnotsatisfiedbyT ,respectively.Whenset



isparametrized,say

(

z

)

,wewrite



+T

(

z

)

and



T

(

z

)

insteadof

(

z

)

+T and

(

z

)

T.Forinstance,

Gr

+T

(

ϕ

)

collectstheformulasfrom

Gr

(

ϕ

)

satisfiedby T .

Definition5(Reduct).Wewilldefinethereduct ofaGZ-aggregateformula A

=

f

{ 

X

:

cond

( 

X

)

} ≺

n withrespecttoaclassical interpretation T ,denotedasAT,inthefollowingway:

(8)

AT def

=

if T

|=

clA



Gr

+T

(

cond

( 

X

))

T

otherwise

ThereductofanF-aggregate B

=

f

{

c1

:

ϕ

1

, . . . ,



cm

:

ϕ

m

} ≺

n istheformula: BT def

=

if T

|=cl

B

f

{

c1

:

ϕ

1T

, . . . ,



cm

:

ϕ

m} ≺T n otherwise

ThereductofanyotherformulaisjustasinDefinition3.Thereductofatheoryisthesetofreductsofitsformulas.

2

Definition6(Stablemodel).Aclassicalinterpretation T isastablemodel ofatheory



iffT isa

-minimalmodelof



T.

2

Note that,when restricted toF-formulas, Definition 3exactly matches thereduct definitionfor aggregate theoriesby Ferraris [17].Ontheotherhand,whenrestrictedtoGZ-formulas,itgeneralizes thereductdefinitionbyGelfond–Zhang [19] allowingarbitraryformulasincond

( 

X

)

,includingnestedaggregates.Forthisreason,inoursetting,thereductisrecursively appliedto

(



Gr

+T

(

cond

( 

X

)))

T.Intheoriginalcase [19],cond

( 

X

)

wasaconjunctionofatoms,butitisstraightforwardtosee that,then,

(



Gr

+T

(

cond

( 

X

)))

T

=



Gr

+T

(

cond

( 

X

))

.Tosumup,theabovedefinitionsofstablemodelandreductcorrespond totheoriginalonesforFerraris [17] andGelfond–Zhang [19] whenrestrictedtotheirrespectivesyntacticfragments. Proposition5.Stablemodelsareclassicalmodels.

2

Example1.Let P1 be the program consistingof fact p

(

b

)

and rule (1) with n

=

1, and let A1 be the GZ-aggregate in that rule.We showthat P1 hasnostablemodels. Givengroundatoms p

(

a

)

and p

(

b

)

,the onlymodelofthe programis T

= {

p

(

a

),

p

(

b

)

}

,since p

(

b

)

isfixedasafact,andso, A1 mustbetrue,so (1) entails p

(

a

)

too.Since T

|=

clA1,thereduct becomes AT

1

=

p

(

a

)

p

(

b

)

,andso, P1T containstherules p

(

b

)

andp

(

a

)

p

(

a

)

p

(

b

)

,theirleastmodelbeing

{

p

(

b

)

}

,soT isnotstable.Asanotherexampleoftheaggregatereduct,ifwetookT

= ∅

,then T

|=

clA1and AT1

= ⊥

.

2

Example2.AsanexampleofnestedGZ-aggregates,consider:

A2

= count

X

: sum{

Y

:

owns

(

X

,

Y

)

} ≥

10

2

andimaginethatowns

(

X

,

Y

)

meansthat X ownssomeitemY whosecostisalsoY .Accordingly, A2 checkswhetherthere are2 ormorepersons X thatownitemsforatotalcostofatleast10.Supposewehavetheinterpretation:

T

= {

owns

(

a

,

6

),

owns

(

a

,

8

),

owns

(

b

,

2

),

owns

(

b

,

3

),

owns

(

c

,

12

)

}

Then A2 holdsinT sincebotha andc havetotalvaluesgreaterthan10:14 fora and 12 forc.Therefore, AT2 corresponds to

(



Gr

+T

(sum

{

Y

:

owns

(

X

,

Y

)

}

10

))

T.Aftergroundingfreevariable X ,weobtain:

(sum

{

Y

:

owns

(

a

,

Y

)

} ≥

10

∧ sum{

Y

:

owns

(

c

,

Y

)

} ≥

10

)

T

Notethatb doesnotoccur,sinceitstotalsumislowerthan10 inT .Ifwe applyagainthereducttotheconjunctsabove, weeventuallyobtaintheconjunction:owns

(

a

,

6

)

owns

(

a

,

8

)

owns

(

c

,

12

)

.

2

Proposition6.Givenformulas

ϕ

and

ψ

,thefollowingconditionshold: i) H

|=

cl

ϕ

TimpliesT

|=

cl

ϕ

,and

ii) T

|=

cl

ϕ

TiffT

|=

cl

ϕ

foranypairofinterpretationsH

T .Furthermore,thefollowingconditionalsoholds

iii) ifH

|=

cl

ϕ

TiffH

|=

cl

ψ

TforallinterpretationsH

T ,then

ϕ

and

ψ

arestronglyequivalent,

ϕ

s

ψ

.

2

Proposition 6 generalizes results from [17] to our extended language combiningGZ andF-aggregates. Inparticular, item iii) provides a sufficient condition for strong equivalence that, in the case of propositional formulas, amounts to HT-equivalence.

Wenow movetoconsiderpropositional translationsofaggregates.As saidintheintroduction,anyF-aggregatecan be understoodasapropositionalformula.TakeanyF-aggregateB

=

f

{

c1

:

ϕ

1

,

. . . ,



cm

:

ϕ

m

}

n whereallformulasin

{

ϕ

1

,

. . . ,

ϕm

}

arepropositional–moreover,letuscallconds (theconditions)tothissetofformulas.By

[

B

]

,wedenotethepropositional formula:

(9)

[

B

]

def

=



T:T|=clB



conds+T



 

condsT



(4) ThefollowingresultdirectlyfollowsfromProposition 12in [17].

Proposition7.ForanyF-aggregate B withpropositionalconditions,wehaveB

s

[

B

]

.

2

GivenanF-formula

ϕ

,wecandefineits(stronglyequivalent)propositionaltranslation

[

ϕ

]

astheresultofthe exhaus-tivereplacementofnon-nestedaggregatesB by

[

B

]

untilallaggregatesareeventuallyremoved.

Our main contribution is to provide an analogouspropositional encoding for GZ-aggregates. To this aim, we extend translation

tobealso applicabletoanyGZ-aggregate A

=

f

{ 

X

:

cond

( 

X

)

} ≺

n withapropositional condition cond

( 

X

)

,so that

[

A

]

correspondstothepropositionalformula:

[

A

]

def

=



T:T|=clA

 

Gr

+T

(

cond

( 

X

))

∧ ¬



Gr

T

(

cond

( 

X

))



(5)

Proposition8.ForanyGZ-aggregateA withapropositionalcondition,wehaveA

s

[

A

]

.

2

Thisresultallowsustodefine, foranyarbitrary aggregateformula

ϕ

,its(strongly equivalent)propositionaltranslation

[

ϕ

]

,againbyexhaustivereplacementofnon-nestedaggregates(nowofanykind)C bytheirpropositionalformulas

[

C

]

. Foranytheory



,its(stronglyequivalent)propositionaltranslationisdefinedas

[]

def

= { [

ϕ

]

|

ϕ

∈ }

.

Example3.Takeagaintheaggregate A1 inthebodyofrule (1) withn

=

1 andassumewehaveconstantsa

,

b.Theclassical modelsof A1are

{

p

(

a

)

}

,

{

p

(

b

)

}

and

{

p

(

a

),

p

(

b

)

}

,sincesomeatom p

(

X

)

musthold.Asaresult:

[

A1

] =

p

(

a

)

∧¬

p

(

b

)

p

(

b

)

∧¬

p

(

a

)

p

(

a

)

p

(

b

)

and

[

(1)

]

amountstothelastthreerulesin (3).

2

Example4.TakeGZ-aggregate A3

= count{

X

:

p

(

X

)

}

=

1 andassumewehaveconstants

C = {

a

,

b

,

c

}

.Theclassicalmodels of A3 are

{

p

(

a

)

}

,

{

p

(

b

)

}

and

{

p

(

c

)

}

.Accordingly:

[

A3

] =

p

(

a

)

∧ ¬(

p

(

b

)

p

(

c

))

p

(

b

)

∧ ¬(

p

(

a

)

p

(

c

))

p

(

c

)

∧ ¬(

p

(

a

)

p

(

b

))

p

(

a

)

∧ ¬

p

(

b

)

∧ ¬

p

(

c

)

p

(

b

)

∧ ¬

p

(

a

)

∧ ¬

p

(

c

)

p

(

c

)

∧ ¬

p

(

a

)

∧ ¬

p

(

b

)

Theorem1(Mainresult).Anyaggregatetheory



isstronglyequivalenttoitspropositionaltranslation

[]

,thatis,



s

[]

.

2

4. RelationtoFerrarisaggregates

In this section, we study the relation between GZ and F-aggregates. One first observation is that GZ-aggregates are first-orderstructureswithquantifiedvariables, whileF-aggregatesallow setsofpropositional expressions.Encodinga GZ-aggregate asanF-aggregateiseasy:wecanjustgroundthevariables.Theother direction,however,isnotalwayspossible, sincethesetofconditionsintheF-aggregatemaynothavearegularrepresentationintermsofvariablesubstitutions.Given aGZ-aggregate A

=

f

{ 

X

:

cond

( 

X

)

}

n wedefineitscorrespondingF-aggregate

F

[

A

]

:

F

[

A

]

def

=

f

{ 

c

:

cond

(



c

)

|

cond

(



c

)

∈ Gr(

cond

( 

X

))

} ≺

n (6)

Thiscorrespondenceisanalogoustotheprocessofinstantiation usedin [18] togroundaggregateswithvariables.Itiseasy tocheckthat A and

F

[

A

]

areclassicallyequivalent.ThiscanbecheckedusingsatisfactionfromDefinition4orclassicallogic fortheirpropositionalrepresentations

[

A

]

cl

[F[

A

]]

.Moreover,itcanbeobservedthatthesetwologicalrepresentations aresomehowdual.Indeed,

[F[

A

]]

eventuallyamountsto:

[F[

A

]] ≡



T:T|=clA



Gr

+T

(

cond

( 

X

))



 

Gr

T

(

cond

( 

X

))



(7)

which is a conjunction of formulas like

α

→ β

for countermodels of A, whereas

[

A

]

, formula (5), is a disjunction of formulas like

α

∧ ¬β

formodels of A.Anotherinteresting consequenceoftheclassicalequivalenceof A and

F

[

A

]

isthat, duetoProposition1-ii),wecansafelyreplaceonebyanotherwhennegated.Inotherwords:

(10)

Proposition9.Let

ϕ

beaformulawithsomeoccurrenceofaGZ-aggregateA andlet

ψ

betheresultofreplacingA byitscorresponding F-aggregate

F

[

A

]

in

ϕ

.Then,wehavethat

¬

ϕ

≡ ¬ψ

.

2

However,aswesawintheintroductionexamples,replacingsome GZ-aggregate A byitsF-aggregateversion

F

[

A

]

may changetheprogramsemantics.Still,thestablemodelsobtainedaftersuch replacementarenotarbitrary.Aswe said, [20] provedthat iftheGZ-aggregate A occursinapositive rulebody,thenthereplacementby theF-aggregate

F

[

A

]

preserves thestablemodels,butmayyieldmore.Next,wegeneralize thisresulttoaggregatetheorieswithoutnestedGZ-aggregates. Tothisaim,wemakeuseofthefollowingpropositionassertingthat,indeed,

[

A

]

isstrongerthan

[F[

A

]]

inHT. Proposition10.ForanyGZ-aggregateA,

[

A

]

|= [F[

A

]]

.

2

Theorem2.ForanyoccurrenceA ofaGZ-aggregatewithoutnestedaggregates: i) SM

((

A

))

SM

((F

[

A

]))

foranytheory

(

A

)

whereoccurrenceA ispositive; ii) SM

((

A

))

SM

((F

[

A

]))

foranytheory

(

A

)

whereoccurrenceA isnegative.

2

Proof. From

[

A

]

cl

[F[

A

]]

andProposition10wedirectlyapplyProposition4.

2

In particular,this meansthat if we replacea (non-nested)GZ-aggregate A by itsF-version

F

[

A

]

in the positive head ofsome rule,we still get stablemodels ofthe original program,but perhapsnot all of them.Theorem 2 is notdirectly applicable to theories with nestedaggregates because applyingoperator

[

·

]

produces a new formulain which nested aggregatesmayoccurbothpositivelyandnegatively.

Itis wellknownthat GZandF-semantics donotagreeeven inthecaseofmonotonicaggregatesasillustratedby the exampleintheintroduction.Nevertheless,weidentifynextamorerestrictedfamilyofaggregatesforwhichbothsemantics coincide.

Proposition11.AnyGZ-aggregateA ofthefollowingtypessatisfiesA

s

F

[

A

]

: i) A

= (count{ 

X

:

cond

( 

X

)

} =

n

)

ii) A

= (sum{

X

, 

Y

:

cond

(

X

, 

Y

)

X

>

0

} =

n

)

iii) A

= (sum{

X

, 

Y

:

cond

(

X

, 

Y

)

X

<

0

} =

n

)

.

2

Note that the resultii (resp. iii) of Proposition 11 does not apply if the condition X

>

0 (resp. X

<

0) is dropped. For instance,theprogramconsistingoftherule

p

(

0

)

← sum{

X

:

p

(

X

)

} =

0 (8)

hasauniquestablemodel

{

p

(

0

)

}

underFerraris’semanticbutnostablemodelunderGZ’s one. 5. Relationbetween

A

log andclingoaggregates

Inthissection,werestrictourselvestothesyntaxoflogicprogrammingandlifttherelationbetweenGZandF-aggregates totheirrespectivefirstorderlanguages,studyingasyntacticfragmentinwhichthesemanticsof

A

log [19] and

gringo

[21] coincide.We alsoshowthat every

A

log programwhoseaggregatesare allof

count

typecan be easilyrewrittento this fragment ina human friendlyway. Thesame applies toprogram that also contain

sum

aggregatesprovided that 0 does notoccurasaconstantintheprogram.ItisworthmentioningthatacompilationforGZ-aggregatesintoF-aggregateshas alreadybeendescribedintheliterature [25].Thiscompilationhastheadvantageofcoveringprogramscontaininganykind ofaggregates.Ontheotherhand,itmakesusesofnewauxiliaryatomsthatobscurethesemanticsoftheprogram.Inthis sense,thiscompilationisbettersuitedforautomatictranslationwhileourrewriting,thoughlessgeneral,preserveshuman readability.

An

A

log rule isanexpressionoftheform:

Head

Pos

Neg

Agg (9)

whereHead isadisjunctionofatoms,Pos isaconjunctionofregularatoms,Neg isaconjunctionofnegativeregularliterals, andAgg isaconjunctionofGZ-aggregates.An

A

log program isasetof

A

log rules.Recallthat,inthissection,wenolonger assume that atomsor programs are ground. Note that every

A

log program isalso a program inthe syntax of

gringo

, though their semantic may differ. We also recall the notion of globalvariable from [21]: a variable is said to be global in a rule ofthe form of (9) iff it occursin any literal in Pos or Neg or in anyterm t of anyaggregate atom inAgg of the form f

{ 

X

:

cond

( 

X

)

} ≺

t.An instance of arule isobtained byreplacing all globalvariables by constants. The

gringo

(11)

every aggregate atom A by

F

[

A

]

. Asetofatoms T isa

gringo

stablemodelofaprogram

iffitisa stablemodelof

Gr

gringo

( )

.Notethatnotionsofglobalandfreevariablesdonotcoincide:anoccurrenceofavariablemaybebothglobal

andbound. Thisimpliesthat the

A

log and

gringo

grounding ofaprogram maybedifferentand, asa result,the same programmayhavedifferentstablemodels.Toillustratethisfact,considerthefollowingexamplefrom [19]:

Example5.LetP2consistingofthefollowingrules

r

← count{

X

:

p

(

X

)

} ≥

2

q

(

X

)

(10)

p

(

a

)

p

(

b

)

q

(

a

)

Variable X isbothglobalin (10) andboundin

count

{

X

:

p

(

X

)

}

2.Asaresult,the

A

log groundingof P2 isobtainedby replacingrule (10) byrules

r

← count{

X

:

p

(

X

)

} ≥

2

q

(

a

)

r

← count{

X

:

p

(

X

)

} ≥

2

q

(

b

)

Ontheotherhand,itsclingogroundingisobtainedbyreplacingthesameruleby

r

← count{

a

:

p

(

a

)

} ≥

2

q

(

a

)

r

← count{

b

:

p

(

b

)

} ≥

2

q

(

b

)

Both programshaveauniquestablemodel,butadifferentone:

{

p

(

a

),

p

(

b

),

q

(

a

),

r

}

fortheformerand

{

p

(

a

),

p

(

b

),

q

(

a

)

}

for thelatter.

2

We saythat an aggregate atom isclosed [26] iff no globalvariableoccursinit. Wesay thata rule (resp.program)is closed if allits aggregateatomsare closed.Then,fromProposition11,we immediatelygetthefollowingresultforclosed programs:

Proposition12.Let

beaclosedlogicprogramwhereallaggregateatomsareoftheform

count

{ 

X

:

cond

( 

X

)

}

=

t.Then,thestable modelof

withrespectto

A

log and

gringo

coincide.

2

An interesting property of

A

log isthat we can rewrite anylogic program asan equivalent closedprogram where all aggregateconditionsareequalities.

Definition7.Givenalogicprogram

,bytr1

( )

wedenotetheresultofreplacing

i) everyoccurrenceofaglobalvariablethatisalsoboundtosomeaggregate A byasamenewfreshvariablenotoccurring anywhereelse,and

ii) everyaggregate f

{ 

X

:

cond

( 

X

,

Y



)

}

t with

differentfrom

=

,by theformula f

{ 

X

:

cond

( 

X

,

Y



)

}

=

Z

Z

t with Z alsoanewfreshvariablenotoccurringanywhereelse.

2

Proposition13.Givenalogicprogram

,the

A

log stablemodelsof

andtr1

( )

coincide.

2

From Proposition12and Proposition13itimmediatelyfollowsthatwecanrewriteany

A

log programwhereall aggre-gatesareofthetype

count

intoanequivalentoneinwhichitsstablemodelscoincidewiththe

gringo

stablemodels.

Theorem3.Givenalogicprogram

whereallaggregateatomsareoftheform

count

{ 

X

:

cond

( 

X

)

}

=

t,thenthe

A

log stablemodels of

coincidewiththe

gringo

stablemodelsoftr1

( )

.

2

Example6(Ex.5continued).Asmentionedabove, P2isaprogramwhosestablemodelsaredifferentaccordingto

A

log and

gringo

semantics.Ontheotherhand,wehavethattr1

(

P2

)

is

r

← count{

Y

:

p

(

Y

)

} =

Z

Z

2

q

(

X

)

(11)

p

(

a

)

p

(

b

)

(12)

whoseuniquestablemodelis

{

p

(

a

),

p

(

b

),

q

,

r

}

accordingtobothsemantics.Recallthatthisisthe unique stablemodelof P2 accordingto

A

log.As afurtherexample,let P3 bethelogicprogramconsistingofrule (1) withn

=

1.Recallfromthe introductionthat P3 hasa unique stablemodel

{

p

(

a

)

}

accordingto Ferraris semanticswhile itdoesnot have anystable modelsemantics accordingto Gelfond andZhangsemantics. Notethat, since thisprogram isground,

gringo

and

A

log semanticsrespectivelycoincidewithFerrarisandGelfondandZhangsemanticsasdescribedinSection3.Furthermore,we havethattr1

(

P3

)

is

p

(

a

)

← count{

X

:

p

(

X

)

} =

Z

Z

0 whichhasnostablemodelunderbothsemantics.

2

Notethat,ingeneral,therewritingtr1

(

·)

isnotsafeforotherkindsofaggregateswithanassociatedfunction f forwhich thereexistsets S and S with S

S suchthat f

(

S

)

=

f

(

S

)

.Forinstance,thesumoftheemptysetandtheset

{

1

,

1

}

is inbothcases0 and,asaresult,wehavethatprogramsinvolvingsumoverthesetwosetswillhavedifferentstablemodels. Example7.Let P4 bethelogicprogramconsistingofthefollowingrules:

p

(

1

)

← sum{

X

:

p

(

X

)

} =

0 (12)

p

(

1

)

p

(

1

)

p

(

1

)

p

(

1

)

It iseasy tocheck that tr1

(

P4

)

=

P4,butthisprogram hasno stablemodelunderthe

A

log semanticsandhasa unique stablemodel

{

p

(

1

),

p

(

1

)

}

underthe

gringo

semantics.

2

6. Conclusions

Wehaveprovideda(strongequivalencepreserving)translationfromlogicprogramswithGZ-aggregatestopropositional theoriesinEquilibriumLogic.Onceweunderstandaggregatesaspropositionalformulas,itisstraightforwardto extendthe syntax toarbitrary nesting ofaggregates(bothGZ andF-aggregates)plus propositional connectives,something we called aggregatetheories.Wehaveprovidedtwo alternativesemanticsforthesetheories:onebasedonadirect,combined exten-sionof GZand F-reducts,andtheother on a translationtopropositional formulas. Thepropositional formulatranslation has helpedus tocharacterize the effect (withrespect to the obtainedstable models)of replacing a GZ-aggregate by its correspondingF-aggregate.Moreover,wehavebeenabletoprovethatbothaggregateshavethesamebehavior inthescope ofnegation.Finally,we identifieda classofaggregatesinwhich theGZandF-semantics coincide.Itisworth to mention thatapropositional formula9 equivalent toSonandPontelliaggregateswasalsogivenin [16].Weexpect thatthecurrent propositional formulatranslationswill opennewpossibilities to exploreformal propertiesandpotential implementations ofbothGZandF-aggregates, possiblyextendingtheideaof [20] toourgeneralaggregatetheories.Finally,anextension of thecurrentapproachtoafullfirst-orderlanguagewithpartial,evaluablefunctions(asthosein [27])wasdevelopedin [28]. Thisallowstreatingaggregatesasordinaryfirst-ordertermsandcombinethemwitharbitrarypredicates,notjustarithmetic relations.

Appendix A. Proofs

ProofofProposition4. First,notethat

ϕ

cl

ψ

implies

(

ϕ

)

cl

(ψ)

duetosubstitutionofequivalentsinclassicallogic, regardlesswhether

ϕ

occurspositivelyornegativelyin

(

ϕ

)

.Ontheother hand,HTsatisfiestheDeductionTheorem,i.e.,

ϕ

|= ψ

iff

ϕ

→ ψ

isvalidand,fromthelatter,wecanderivethefollowingintuitionisticconsequences:

(

ϕ

γ

)

→ (ψ ∧

γ

)

(

ϕ

γ

)

→ (ψ ∨

γ

)

(

γ

ϕ

)

→ (

γ

→ ψ)

γ

)

→ (

ϕ

γ

)

whicharealsoconsequencesintheintermediatelogicofHT.Asaresult,if

ϕ

|= ψ

,theaboveformulasholdand,together with

ϕ

cl

ψ

,wecanapplyProposition3toconclude:

Références

Documents relatifs

Like our fuzzy stable model semantics, fuzzy equilibrium logic [6] generalizes fuzzy ASP programs to arbitrary propositional formulas, but its definition is highly complex..

We show that this class of formulas is identifiable and PAC- learnable from examples, that an affine least upper bound of a rela- tion can be computed in polynomial time and a

L’archive ouverte pluridisciplinaire HAL, est destinée au dépôt et à la diffusion de documents scientifiques de niveau recherche, publiés ou non, émanant des

We realize our approach by performing the following steps: (i) representing the model in the assertion box (ABox) of the description-logic based knowledge base, (ii) defining

With this new procedure we derive the classical formulas, like Bailey-Borwein-Plouffe or Bellard formulas, and understand better their origin, in particular the origin of null

In the context of formal deformation quantization, we provide an elementary argument show- ing that any universal quantization formula necessarily involves graphs with wheels..

In the present paper, we state and prove explicit inversion formulas for the X−Ray transform in the lattice Z n by using certain arithmetical geometrical techniques..

According to Theorem 163, the words labeling loops rooted at the zero-state of a zero-SCC are the encodings (from which the sign symbol o has been removed) of the natural solutions of