logo
In [1]:
import proveit
from proveit import defaults
from proveit import A, B
from proveit.logic import And, Implies, Iff, Not
from proveit.logic.booleans.conjunction import true_and_false_negated
from proveit.logic.booleans.implication import negated_reflex
theory = proveit.Theory() # the theorem's theory
In [2]:
%proving not_iff_via_not_left_impl
With these allowed/disallowed theorem/theory presumptions (e.g., to avoid circular dependencies), we begin our proof of
not_iff_via_not_left_impl:
(see dependencies)
not_iff_via_not_left_impl may now be readily provable (assuming required theorems are usable).  Simply execute "%qed".
In [3]:
defaults.assumptions = not_iff_via_not_left_impl.all_conditions()
defaults.assumptions:
In [4]:
true_and_false_negated
In [5]:
not__AimplB_and_T = true_and_false_negated.inner_expr().operand.operands[0].substitute(Implies(A, B))
not__AimplB_and_T:  ⊢  
In [6]:
not__AimplB_and_BimplA = not__AimplB_and_T.inner_expr().operand.operands[1].substitute(Implies(B, A))
not__AimplB_and_BimplA:  ⊢  
In [7]:
A_iff_B__def = Iff(A, B).definition(assumptions=[])
A_iff_B__def:  ⊢  
In [8]:
A_iff_B__def.sub_left_side_into(not__AimplB_and_BimplA)
In [9]:
%qed
proveit.logic.booleans.implication.not_iff_via_not_left_impl has been proven.