X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=matita%2Fmatita%2Fcontribs%2Flambdadelta%2Fground_2%2Flib%2Fstream_tls.ma;fp=matita%2Fmatita%2Fcontribs%2Flambdadelta%2Fground_2%2Flib%2Fstream_tls.ma;h=36492559a85c33e33858066c8c6feddee1947e5f;hb=db020b4218272e2e35641ce3bc3b0a9b3afda899;hp=0000000000000000000000000000000000000000;hpb=d8f6494f48aa08bb32d9d1ac82fc16e9e41b76ac;p=helm.git diff --git a/matita/matita/contribs/lambdadelta/ground_2/lib/stream_tls.ma b/matita/matita/contribs/lambdadelta/ground_2/lib/stream_tls.ma new file mode 100644 index 000000000..36492559a --- /dev/null +++ b/matita/matita/contribs/lambdadelta/ground_2/lib/stream_tls.ma @@ -0,0 +1,41 @@ +(**************************************************************************) +(* ___ *) +(* ||M|| *) +(* ||A|| A project by Andrea Asperti *) +(* ||T|| *) +(* ||I|| Developers: *) +(* ||T|| The HELM team. *) +(* ||A|| http://helm.cs.unibo.it *) +(* \ / *) +(* \ / This file is distributed under the terms of the *) +(* v GNU General Public License Version 2 *) +(* *) +(**************************************************************************) + +include "ground_2/notation/functions/downspoonstar_3.ma". +include "ground_2/lib/stream_hdtl.ma". + +(* STREAMS ******************************************************************) + +rec definition tls (A:Type[0]) (n:nat) on n: stream A → stream A ≝ ?. +cases n -n [ #t @t | #n #t @tl @(tls … n t) ] +defined. + +interpretation "iterated tail (stram)" 'DownSpoonStar A n f = (tls A n f). + +(* basic properties *********************************************************) + +lemma tls_rew_O (A) (t): t = tls A 0 t. +// qed. + +lemma tls_rew_S (A) (n) (t): ⫰⫰*[n]t = tls A (↑n) t. +// qed. + +lemma tls_S1 (A) (n) (t): ⫰*[n]⫰t = tls A (↑n) t. +#A #n elim n -n // +qed. + +lemma tls_eq_repl (A) (n): eq_stream_repl A (λt1,t2. ⫰*[n] t1 ≗ ⫰*[n] t2). +#A #n elim n -n // +#n #IH * #n1 #t1 * #n2 #t2 #H elim (eq_stream_inv_seq … H) /2 width=7 by/ +qed.