logo
In [1]:
import proveit
from proveit import a, b, d, i
from proveit.core_expr_types.tuples  import tuple_len_incr
from proveit.numbers.numerals.decimals import tuple_len_3, add_3_1
theory = proveit.Theory() # the theorem's theory
In [2]:
%proving tuple_len_4
With these allowed/disallowed theorem/theory presumptions (e.g., to avoid circular dependencies), we begin our proof of
tuple_len_4:
(see dependencies)
In [3]:
three_spec = tuple_len_3.instantiate({a:a}, auto_simplify=False)
three_spec:  ⊢  
In [4]:
tuple_spec = tuple_len_incr.instantiate(
    {i: three_spec.rhs, a: three_spec.lhs.operands, b: d})
tuple_spec:  ⊢  
tuple_len_4 may now be readily provable (assuming required theorems are usable).  Simply execute "%qed".
In [5]:
%qed
proveit.numbers.numerals.decimals.tuple_len_4 has been proven.
Out[5]:
 step typerequirementsstatement
0generalization1  ⊢  
1instantiation2, 3, 4, 5*  ⊢  
  : , : , :
2axiom  ⊢  
 proveit.core_expr_types.tuples.tuple_len_incr
3conjecture  ⊢  
 proveit.numbers.numerals.decimals.nat3
4instantiation6  ⊢  
  : , : , :
5conjecture  ⊢  
 proveit.numbers.numerals.decimals.add_3_1
6conjecture  ⊢  
 proveit.numbers.numerals.decimals.tuple_len_3_typical_eq
*equality replacement requirements