If case_def is the definition of a data type’s case constant, where
each clause is of the form
!a1 .. ai f1 .. fm. type_CASE (ctor_i a1 .. ai) f1 .. fm = f_i a1 .. ai
and if nchotomy is a theorem describing how a data type’s values are
classified by constructor, of the form
!v. (?a1 .. ai. v = ctor_1 a1 .. ai) \/
(?b1 .. bj. v = ctor_2 b1 .. bj) \/
...
then a call to prove_case_rand_thm{case_def = case_def, nchotomy = nchotomy}
will return a theorem of the form
f (type_CASE x f1 .. fm) =
type_CASE x (\a1 .. ai. f (f1 a1 .. ai))
(\b1 .. bj. f (f2 b1 .. bj))
...
Given the typical pretty-printing provided for case-terms, the
right-hand side of the above theorem will actually print as
case x of
ctor_1 a1 .. ai => f (f1 a1 .. ai)
| ctor_2 b1 .. bj => f (f2 b1 .. bj)
| ...