epistemic-group-gossip-0.1.0.0
Copyright(c) Jesper Kuiper 2021
Leander van Boven 2021
Ramon Meffert 2021
LicenseBSD3
Safe HaskellNone
LanguageHaskell2010

GossipProtocol

Description

 
Synopsis

Protocol type

type GossipProtocol = Int -> GossipKnowledgeStructure -> Call -> Form Source #

A protocol for dynamic gossip. Following (van Ditmarsch et al., 2017), a gossip protocol is defined as an epistemic formula using two agents. If this formula resolves to true, a call between these agents is allowed. If the formula resolves to false, such a call is not allowed. The first argument denotes the amount of agents, the second argument is the current knowledge structure, whereas the third argument denotes the call in question.

showProtocol :: State -> GossipProtocol -> String Source #

Converts a protocol to a string notation, as used in (van Ditmarsch et al., 2017).

Different protocols

callAny :: GossipProtocol Source #

The most simple and naive protocol, it allows any call to be made. φ(a,b) = ⊤

learnNewSecrets :: GossipProtocol Source #

This protocol only allows a call if it leads to new secrets to be learned. φ(a,b) = ¬S(a,b)

possibleInformationGrowth :: GossipProtocol Source #

Introduced by (van Ditmarsch et al., 2017): "Call xy can be made if x knows y's number and if x considers it possible that there is a secret known by one of x,y but not the other." φ(a,b) = ⋁_{z ∈ A}( S(x, z) ↔︎ ¬S(y, z) )

Protocol evaluation

selectedCalls :: GossipProtocol -> State -> ([Call], [GroupCall]) Source #

Selects all calls that are allowed by the given gossip protocol. Note that there could also be no calls allowed.