logo
In [1]:
import proveit
from proveit import A, B
from proveit import defaults
from proveit.logic.booleans.conjunction import false_and_true_negated
theory = proveit.Theory() # the theorem's theory
In [2]:
%proving nand_if_right_but_not_left
With these allowed/disallowed theorem/theory presumptions (e.g., to avoid circular dependencies), we begin our proof of
nand_if_right_but_not_left:
(see dependencies)
nand_if_right_but_not_left may now be readily provable (assuming required theorems are usable).  Simply execute "%qed".
In [3]:
defaults.assumptions = nand_if_right_but_not_left.all_conditions()
defaults.assumptions:
In [4]:
AeqF = A.evaluation()
AeqF:  ⊢  
In [5]:
BeqT = B.evaluation()
BeqT:  ⊢  
In [6]:
FandB = BeqT.sub_left_side_into(false_and_true_negated, auto_simplify=False)
FandB:  ⊢  
In [7]:
AeqF.sub_left_side_into(FandB, auto_simplify=False)
In [8]:
%qed
proveit.logic.booleans.conjunction.nand_if_right_but_not_left has been proven.
Out[8]:
 step typerequirementsstatement
0generalization1  ⊢  
1instantiation2, 3, 4,  ⊢  
  : , :
2theorem  ⊢  
 proveit.logic.equality.substitute_falsehood
3instantiation5, 6, 7  ⊢  
  : , :
4assumption  ⊢  
5theorem  ⊢  
 proveit.logic.equality.substitute_truth
6theorem  ⊢  
 proveit.logic.booleans.conjunction.false_and_true_negated
7assumption  ⊢