Class PrSigBasedDungTheoryGenerator
java.lang.Object
org.tweetyproject.arg.dung.util.PrSigBasedDungTheoryGenerator
- All Implemented Interfaces:
Iterator<DungTheory>
,DungTheoryGenerator
,BeliefSetIterator<Argument,
DungTheory>
Creates abstract argumentation graphs by first generating the corresponding set
of preferred extensions and then construct the graph by using the construction method
from [Dunne, Dvorak, Linsbichler, Woltran: Characteristics of multiple viewpoints in abstract argumentation.
Artificial Intelligence 228: 153-178, 2015].
The implementation is randomized: sets of extensions are randomly generated and tested whether they are
realisable wrt. preferred semantics. Only when one realizable set is found, the graph is constructed. This
means the generation process is not guaranteed to terminate. This may happen when the required number of
extensions is too large for the given number of credulously accepted arguments.
-
Constructor Summary
ConstructorsConstructorDescriptionPrSigBasedDungTheoryGenerator
(int num_extensions, int num_credulously_accepted_arguments, int num_skeptically_accepted_arguments) Creates a new theory generator (without distortion).PrSigBasedDungTheoryGenerator
(int max_num_extensions, int num_credulously_accepted_arguments, int num_skeptically_accepted_arguments, double distortion_factor) Creates a new theory generator. -
Method Summary
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.Iterator
forEachRemaining, remove
-
Constructor Details
-
PrSigBasedDungTheoryGenerator
public PrSigBasedDungTheoryGenerator(int max_num_extensions, int num_credulously_accepted_arguments, int num_skeptically_accepted_arguments, double distortion_factor) Creates a new theory generator.- Parameters:
max_num_extensions
- the maximum number of (preferred) extensions in the generated frameworksnum_credulously_accepted_arguments
- The number of arguments that are credulously accepted wrt. preferred semantics in the generated frameworksnum_skeptically_accepted_arguments
- The number of arguments that are skeptically accepted wrt. preferred semantics in the generated frameworksdistortion_factor
- the probability of each edge to be re-wired after construction (distorts the result a bit)
-
PrSigBasedDungTheoryGenerator
public PrSigBasedDungTheoryGenerator(int num_extensions, int num_credulously_accepted_arguments, int num_skeptically_accepted_arguments) Creates a new theory generator (without distortion).- Parameters:
num_extensions
- the number of (preferred) extensions in the generated frameworksnum_credulously_accepted_arguments
- The number of arguments that are credulously accepted wrt. preferred semantics in the generated frameworksnum_skeptically_accepted_arguments
- The number of arguments that are skeptically accepted wrt. preferred semantics in the generated frameworks
-
-
Method Details
-
hasNext
public boolean hasNext()- Specified by:
hasNext
in interfaceBeliefSetIterator<Argument,
DungTheory> - Specified by:
hasNext
in interfaceDungTheoryGenerator
- Specified by:
hasNext
in interfaceIterator<DungTheory>
-
next
- Specified by:
next
in interfaceBeliefSetIterator<Argument,
DungTheory> - Specified by:
next
in interfaceDungTheoryGenerator
- Specified by:
next
in interfaceIterator<DungTheory>
-
next
Description copied from interface:DungTheoryGenerator
Generates a new Dung theory where the given argument is enforced to be in the grounded extension- Specified by:
next
in interfaceDungTheoryGenerator
- Parameters:
arg
- an argument that is enforced to be in the grounded extension of the generated theory.- Returns:
- a Dung theory,
-
setSeed
public void setSeed(long seed) Description copied from interface:DungTheoryGenerator
Set the seed for the generation. Every two runs of generations with the same seed are ensured to be identical.- Specified by:
setSeed
in interfaceDungTheoryGenerator
- Parameters:
seed
- some seed.
-