Class EpistemicArgumentationFramework
java.lang.Object
org.tweetyproject.commons.BeliefSet<Argument, DungSignature>
org.tweetyproject.arg.dung.syntax.DungTheory
org.tweetyproject.arg.eaf.syntax.EpistemicArgumentationFramework
- All Implemented Interfaces:
Comparable<DungTheory>
,Iterable<Argument>
,Collection<Argument>
,ArgumentationFramework<Argument>
,BeliefBase
,GeneralGraph<Argument>
,Graph<Argument>
This class implements an epistemic abstract argumentation theory (EAF) using modal logic formulas.
See
Sakama, Chiaki, and Tran Cao Son. "Epistemic argumentation framework: Theory and computation." Journal of Artificial Intelligence Research 69 (2020): 1103-1126.
See
Sakama, Chiaki, and Tran Cao Son. "Epistemic argumentation framework: Theory and computation." Journal of Artificial Intelligence Research 69 (2020): 1103-1126.
- Author:
- Sandra Hoffmann
-
Field Summary
Fields inherited from class org.tweetyproject.commons.BeliefSet
EQUALS_USES_SIGNATURE
Fields inherited from interface org.tweetyproject.graphs.Graph
IGNORE_SELFLOOPS, INVERT_SELFLOOPS, REMOVE_SELFLOOPS
-
Constructor Summary
ConstructorsConstructorDescriptiondefault constructor.Constructor for an EAF from a graph.EpistemicArgumentationFramework
(Graph<Argument> graph, String constraint) Constructor for an EAF using a given graph and constraint.EpistemicArgumentationFramework
(Graph<Argument> graph, FolFormula constraint) Constructor for an EAF from a graph and a modal logic formula as the constraint. -
Method Summary
Modifier and TypeMethodDescriptionRetrieves the current epistemic constraint of the framework.Returns the epistemic knowledge base consisting of propositional formulas based on all extensions of a given semantics for this eaf.Computes all epistemic labeling sets under the given semantics.Determines if the given labeling is a co-epistemic labeling.isCoEpistemicLabelingSet
(Set<Labeling> labSet) Determines if the given set of labelings is a co-epistemic labeling Set.Determines if the given labeling is a gr-epistemic labeling.isGrEpistemicLabelingSet
(Set<Labeling> labSet) Determines if the given set of labelings is a gr-epistemic labeling Set.Determines if the given labeling is a pr-epistemic labeling.isPrEpistemicLabelingSet
(Set<Labeling> labSet) Determines if the given set of labelings is a pr-epistemic labeling Set.Determines if the given labeling is a st-epistemic labeling.isStEpistemicLabelingSet
(Set<Labeling> labSet) Determines if the given set of labelings is a st-epistemic labeling Set.boolean
isStrongerConstraint
(String newConstraint, Semantics w) Computes if the given newConstraint is stronger than the underlying constraint of the EAF.boolean
isStrongerConstraint
(FolFormula newConstraint, Semantics w) Computes if the given newConstraint is stronger than the underlying constraint of the EAF.Pretty print of the theory.boolean
Checks whether the given extension satisfies the epistemic constraint of the underlying AF.boolean
Checks whether the given labeling satisfies the epistemic constraint of the underlying AF.boolean
satisfiesConstraint
(MlBeliefSet beliefSet) Checks whether the given epistemic knowledge base satisfies the epistemic constraint of the underlying AF.boolean
setConstraint
(String constraint) Sets a new epistemic constraint by parsing a string representation of a formula.boolean
setConstraint
(FolFormula constraint) Sets a new epistemic formula as the constraint of EAF.toString()
Generates a string representation of the framework.Methods inherited from class org.tweetyproject.arg.dung.syntax.DungTheory
add, add, add, add, add, addAllAttacks, addAttack, areAdjacent, clone, compareTo, contains, containsAll, containsAttack, containsCycle, containsOddCycle, equals, equalsIn, existsDirectedPath, faf, getAdjacencyMatrix, getAttacked, getAttacked, getAttackers, getAttackers, getAttacks, getBidirectionalAttacks, getChildren, getComplementGraph, getComponents, getConnectedComponents, getEdge, getEdges, getInducedSubgraphs, getMinimalSignature, getNeighbors, getNodes, getNumberOfEdges, getNumberOfNodes, getParents, getReduct, getReduct, getRestriction, getStronglyConnectedComponents, getSubgraphs, getUnattackedAttackers, getUndefendedAttacks, hasAttackBranch, hasDefenseBranch, hashCode, hasSelfLoops, isAcceptable, isAdmissible, isAttackBranch, isAttacked, isAttacked, isAttackedBy, isAttackedBy, isAttackingAllOtherArguments, isCoherent, isComplete, isConflictFree, isConflictFree, isDefenseBranch, isIndirectAttack, isPreferred, isRelativelyCoherent, isStable, isStronglyDefendedBy, isSupport, isWeightedGraph, isWellFounded, remove, remove, removeAll
Methods inherited from class org.tweetyproject.commons.BeliefSet
add, addAll, clear, getSignature, isEmpty, iterator, remove, retainAll, setSignature, size, toArray, toArray, toString
Methods inherited from interface java.util.Collection
parallelStream, removeIf, spliterator, stream, toArray
-
Constructor Details
-
EpistemicArgumentationFramework
public EpistemicArgumentationFramework()default constructor. -
EpistemicArgumentationFramework
-
EpistemicArgumentationFramework
Constructor for an EAF using a given graph and constraint. The constraint is provided as a string and parsed into an epistemic formula. For example, a valid epistemic string is:<>(in(c))=>[](in(a))
. Note: The parser does not support negated modal operators directly. If you need to use them, please convert as follows: - Convert "¬M φ" to "K ¬φ". - Convert "¬K φ" to "M ¬φ".- Parameters:
graph
- A graph representing the structure of the argumentation framework.constraint
- A string representing the epistemic constraint.
-
EpistemicArgumentationFramework
Constructor for an EAF from a graph and a modal logic formula as the constraint.- Parameters:
graph
- A graph representing the structure of arguments and their relations.constraint
- A modal logic formula representing the constraint.
-
-
Method Details
-
setConstraint
Sets a new epistemic formula as the constraint of EAF.- Parameters:
constraint
- A modal logic formula to be set as the new epistemic constraint.- Returns:
- true when the constraint is successfully set.
-
setConstraint
Sets a new epistemic constraint by parsing a string representation of a formula. The constraint string is converted disjunctive normal form (DNF). Note: The parser does not support negated modal operators directly. If you need to use them, please convert as follows: - Convert "¬M φ" to "K ¬φ". - Convert "¬K φ" to "M ¬φ".- Parameters:
constraint
- the constraint string to parse (e.g., "K(in(a)) ∨ K(out(a))")- Returns:
- true if the constraint was successfully parsed and set; false if parsing fails
-
getConstraint
Retrieves the current epistemic constraint of the framework.- Returns:
- The epistemic formula representing the current constraint.
-
isCoEpistemicLabeling
Determines if the given labeling is a co-epistemic labeling. A labeling is co-epistemic if it is a complete labelling and satisfies the epistemic constraint.- Parameters:
lab
- the labeling to check- Returns:
- true if the labeling is co-epistemic, false otherwise
-
isCoEpistemicLabelingSet
Determines if the given set of labelings is a co-epistemic labeling Set. A co-epistemic labeling set is a maximal set of co-epistemic labelings that satisfy the constraint of the underlying AF- Parameters:
labSet
- the set of labelings to check- Returns:
- true if the set of labelings is a co-epistemic labeling set, false otherwise
-
isStEpistemicLabeling
Determines if the given labeling is a st-epistemic labeling. A labeling is st-epistemic if it is a stable labelling and satisfies the epistemic constraint.- Parameters:
lab
- the labeling to check- Returns:
- true if the labeling is st-epistemic, false otherwise
-
isStEpistemicLabelingSet
Determines if the given set of labelings is a st-epistemic labeling Set. A st-epistemic labeling set is a maximal set of st-epistemic labelings that satisfy the constraint of the underlying AF- Parameters:
labSet
- the set of labelings to check- Returns:
- true if the set of labelings is a st-epistemic labeling set, false otherwise
-
isGrEpistemicLabeling
Determines if the given labeling is a gr-epistemic labeling. A labeling is gr-epistemic if it is a grounded labelling and satisfies the epistemic constraint.- Parameters:
lab
- the labeling to check- Returns:
- true if the labeling is gr-epistemic, false otherwise
-
isGrEpistemicLabelingSet
Determines if the given set of labelings is a gr-epistemic labeling Set. A gr-epistemic labeling set is a maximal set of gr-epistemic labelings that satisfy the constraint of the underlying AF- Parameters:
labSet
- the set of labelings to check- Returns:
- true if the set of labelings is a gr-epistemic labeling set, false otherwise
-
isPrEpistemicLabeling
Determines if the given labeling is a pr-epistemic labeling. A labeling is pr-epistemic if it is a preferred labelling and satisfies the epistemic constraint.- Parameters:
lab
- the labeling to check- Returns:
- true if the labeling is pr-epistemic, false otherwise
-
isPrEpistemicLabelingSet
Determines if the given set of labelings is a pr-epistemic labeling Set. A pr-epistemic labeling set is a maximal set of pr-epistemic labelings that satisfy the constraint of the underlying AF- Parameters:
labSet
- the set of labelings to check- Returns:
- true if the set of labelings is a pr-epistemic labeling set, false otherwise
-
getWEpistemicKnowledgeBase
Returns the epistemic knowledge base consisting of propositional formulas based on all extensions of a given semantics for this eaf.- Parameters:
w
- the semantics used to compute the extensions- Returns:
- the epistemic knowledge base derived from the extensions
-
satisfiesConstraint
Checks whether the given labeling satisfies the epistemic constraint of the underlying AF.- Parameters:
lab
- the labeling to check against the epistemic constraint- Returns:
- true if the extension satisfies the constraint, false otherwise
-
satisfiesConstraint
Checks whether the given extension satisfies the epistemic constraint of the underlying AF.- Parameters:
ext
- the extension to check against the epistemic constraint- Returns:
- true if the extension satisfies the constraint, false otherwise
-
satisfiesConstraint
Checks whether the given epistemic knowledge base satisfies the epistemic constraint of the underlying AF.- Parameters:
beliefSet
- the epistemic knowledge base to check- Returns:
- true if the belief set satisfies the constraint, false otherwise
-
getWEpistemicLabellingSets
-
isStrongerConstraint
Computes if the given newConstraint is stronger than the underlying constraint of the EAF. A constraint φ₁ is stronger than φ₂ if, whenever a set of labelings SL satisfies φ₁, it also satisfies φ₂.- Parameters:
newConstraint
- a string representing the constraintw
- the semantics for which to test if constraint is stronger- Returns:
- w the semantics for which to test if constraint is stronger
-
isStrongerConstraint
Computes if the given newConstraint is stronger than the underlying constraint of the EAF. A constraint φ₁ is stronger than φ₂ if whenever a set of labelings SL satisfies φ₁, it also satisfies φ₂.- Parameters:
newConstraint
- a FolFormula representing the constraintw
- the semantics for which to test if constraint is stronger- Returns:
- w the semantics for which to test if constraint is stronger
-
prettyPrint
Pretty print of the theory.- Overrides:
prettyPrint
in classDungTheory
- Returns:
- the pretty print of the theory.
-
toString
Generates a string representation of the framework.- Specified by:
toString
in interfaceBeliefBase
- Specified by:
toString
in interfaceGraph<Argument>
- Overrides:
toString
in classDungTheory
- Returns:
- The string representation of the framework.
-