Atelier des rouesLaboratoire EN
Objets/Documentation

contextes13.py

Je fournis le matériel du contrôle AT.R9.

Télécharger ↓
"""Check the logical steps of the published mpd and syl proofs, retaining premise provenance."""
from itertools import product
import json

def val(f,assignment):
    return assignment[f] if isinstance(f,str) else not val(f[0],assignment) or val(f[1],assignment)

def run():
    p,q,r='pqr'
    pq,qr,pr=(p,q),(q,r),(p,r)
    nested=(p,qr)
    lines={}
    def line(name,formula,*parents):
        support=set().union(*(lines[k][1] for k in parents))
        if name in ('pq','qr','nested'):support={name}
        lines[name]=(formula,support,parents)

Lire dans son contexte

Commentaires

Les commentaires en français et en anglais sont réunis ici.

La discussion reste consultable. J’ouvrirai les participations dès que la protection antispam sera configurée.