smcdel-1.3.0: Symbolic Model Checking for Dynamic Epistemic Logic
Safe HaskellSafe-Inferred
LanguageHaskell2010

SMCDEL.Examples.MuddyChildren

Description

We model the story of the muddy children which is known in many versions. See for example~cite{Littlewood1953:amm},~cite[p.~24-30]{fagin1995reasoning} or~cite[p.~93-96]{DitHoekKooi2007:del}.

Our implementation treats the general case for \(n\) children out of which \(m\) are muddy, but we focus on the case of three children who are all muddy. As usual, all children can observe whether the others are muddy but do not see their own face. This is represented by the observational variables: Agent $1$ observes $p_2$ and $p_3$, agent $2$ observes $p_1$ and $p_3$ and agent $3$ observes $p_1$ and $p_2$.

Synopsis

Documentation

mudScnInit :: Int -> Int -> KnowScene Source #

The initial knowledge structure, given the total number of children, and the number of muddy children.

myMudScnInit :: KnowScene Source #

The initial structure for 3 muddy children.

knows :: Int -> Form Source #

A formula to say that the given child knows whether it is muddy.

nobodyknows :: Int -> Form Source #

A formula to say that none out of \(n\) children knows its own state.

father :: Int -> Form Source #

Announcement of the father announce that someone is muddy.

mudScn0 :: KnowScene Source #

Result after announcing `father 3` in myMudScnInit.