Lex
(lex-repetition-3-operands input) → (mv trees rest-input)
Function:
(defun lex-repetition-3-operands (input) (declare (xargs :guard (nat-listp input))) (let ((__function__ 'lex-repetition-3-operands)) (declare (ignorable __function__)) (b* (((mv tree-operand-ws-1 input-after-operand-ws-1) (lex-group-1-operand input)) ((when (reserrp tree-operand-ws-1)) (mv (reserrf-push tree-operand-ws-1) (nat-list-fix input))) ((mv tree-operand-ws-2 input-after-operand-ws-2) (lex-group-1-operand input-after-operand-ws-1)) ((when (reserrp tree-operand-ws-2)) (mv (reserrf-push tree-operand-ws-2) (nat-list-fix input))) ((mv tree-operand-ws-3 input-after-operand-ws-3) (lex-group-1-operand input-after-operand-ws-2)) ((when (reserrp tree-operand-ws-3)) (mv (reserrf-push tree-operand-ws-3) (nat-list-fix input)))) (mv (list tree-operand-ws-1 tree-operand-ws-2 tree-operand-ws-3) input-after-operand-ws-3))))
Theorem:
(defthm tree-list-resultp-of-lex-repetition-3-operands.trees (b* (((mv ?trees ?rest-input) (lex-repetition-3-operands input))) (abnf::tree-list-resultp trees)) :rule-classes :rewrite)
Theorem:
(defthm nat-listp-of-lex-repetition-3-operands.rest-input (b* (((mv ?trees ?rest-input) (lex-repetition-3-operands input))) (nat-listp rest-input)) :rule-classes :rewrite)
Theorem:
(defthm len-of-lex-repetition-3-operands-< (b* (((mv ?trees ?rest-input) (lex-repetition-3-operands input))) (implies (not (reserrp trees)) (< (len rest-input) (len input)))) :rule-classes :linear)
Theorem:
(defthm lex-repetition-3-operands-of-nat-list-fix-input (equal (lex-repetition-3-operands (nat-list-fix input)) (lex-repetition-3-operands input)))
Theorem:
(defthm lex-repetition-3-operands-nat-list-equiv-congruence-on-input (implies (acl2::nat-list-equiv input input-equiv) (equal (lex-repetition-3-operands input) (lex-repetition-3-operands input-equiv))) :rule-classes :congruence)