logo
In [1]:
import proveit
from proveit import x, y
from proveit.logic import Equals, NotEquals, Not, in_bool
from proveit.logic.equality  import not_equals_def
from proveit import x, y
theory = proveit.Theory() # the theorem's theory
In [2]:
%proving not_equals_is_bool
With these allowed/disallowed theorem/theory presumptions (e.g., to avoid circular dependencies), we begin our proof of
not_equals_is_bool:
(see dependencies)
not_equals_is_bool may now be readily provable (assuming required theorems are usable).  Simply execute "%qed".
In [3]:
not_equals_def
In [4]:
not_equals_def_spec = not_equals_def.instantiate({x:x, y:y})
not_equals_def_spec:  ⊢  
In [5]:
neg_equals_in_bool = in_bool(Not(Equals(x, y))).prove()
neg_equals_in_bool:  ⊢  
In [6]:
not_equals_def_spec.sub_left_side_into(neg_equals_in_bool)
In [7]:
%qed
proveit.logic.equality.not_equals_is_bool has been proven.
Out[7]:
 step typerequirementsstatement
0generalization1  ⊢  
1instantiation2, 3, 4  ⊢  
  : , : , :
2theorem  ⊢  
 proveit.logic.equality.sub_left_side_into
3instantiation5, 6  ⊢  
  :
4instantiation7  ⊢  
  : , :
5conjecture  ⊢  
 proveit.logic.booleans.negation.closure
6instantiation8  ⊢  
  : , :
7axiom  ⊢  
 proveit.logic.equality.not_equals_def
8axiom  ⊢  
 proveit.logic.equality.equality_in_bool