        {"id":598,"date":"2021-07-25T06:00:19","date_gmt":"2021-07-25T04:00:19","guid":{"rendered":"https:\/\/www.glc.us.es\/~jalonso\/calculemus\/?p=598"},"modified":"2021-07-24T19:16:31","modified_gmt":"2021-07-24T17:16:31","slug":"las-sucesiones-convergentes-estan-acotadas","status":"publish","type":"post","link":"https:\/\/www.glc.us.es\/~jalonso\/calculemus\/las-sucesiones-convergentes-estan-acotadas\/","title":{"rendered":"Las sucesiones convergentes est\u00e1n acotadas"},"content":{"rendered":"<p>Demostrar que si u es una sucesi\u00f3n convergente, entonces est\u00e1 acotada; es decir,<\/p>\n<pre lang=\"text\">\n    \u2203 k b, \u2200 n, n \u2265 k \u2192 |u n| \u2264 b\n<\/pre>\n<p>Para ello, completar la siguiente teor\u00eda de Lean:<\/p>\n<pre lang=\"lean\">\nimport data.real.basic\n\nvariable {u : \u2115 \u2192 \u211d}\nvariable {a : \u211d}\n\nnotation `|`x`|` := abs x\n\n-- (limite u c) expresa que el l\u00edmite de u es c.\ndef limite (u : \u2115 \u2192 \u211d) (c : \u211d) :=\n  \u2200 \u03b5 > 0, \u2203 k, \u2200 n \u2265 k, |u n - c| \u2264 \u03b5\n\n-- (convergente u) expresa que u es convergente.\ndef convergente (u : \u2115 \u2192 \u211d) :=\n  \u2203 a, limite u a\n\nexample\n  (h : convergente u)\n  : \u2203 k b, \u2200 n, n \u2265 k \u2192 |u n| \u2264 b :=\nsorry\n<\/pre>\n<p>[expand title=\u00bbSoluciones con Lean\u00bb]<\/p>\n<pre lang=\"lean\">\r\nimport data.real.basic\r\n\r\nvariable {u : \u2115 \u2192 \u211d}\r\nvariable {a : \u211d}\r\n\r\nnotation `|`x`|` := abs x\r\n\r\n-- (limite u c) expresa que el l\u00edmite de u es c.\r\ndef limite (u : \u2115 \u2192 \u211d) (c : \u211d) :=\r\n  \u2200 \u03b5 > 0, \u2203 k, \u2200 n \u2265 k, |u n - c| \u2264 \u03b5\r\n\r\n-- (convergente u) expresa que u es convergente.\r\ndef convergente (u : \u2115 \u2192 \u211d) :=\r\n  \u2203 a, limite u a\r\n\r\n-- 1\u00aa demostraci\u00f3n\r\nexample\r\n  (h : convergente u)\r\n  : \u2203 k b, \u2200 n, n \u2265 k \u2192 |u n| \u2264 b :=\r\nbegin\r\n  cases h with a ua,\r\n  cases ua 1 zero_lt_one with k h,\r\n  use [k, 1 + |a|],\r\n  intros n hn,\r\n  specialize h n hn,\r\n  calc |u n|\r\n       = |u n - a + a|   : congr_arg abs (eq_add_of_sub_eq rfl)\r\n   ... \u2264 |u n - a| + |a| : abs_add (u n - a) a\r\n   ... \u2264 1 + |a|         : add_le_add_right h _\r\nend\r\n\r\n-- 2\u00aa demostraci\u00f3n\r\nexample\r\n  (h : convergente u)\r\n  : \u2203 k b, \u2200 n, n \u2265 k \u2192 |u n| \u2264 b :=\r\nbegin\r\n  cases h with a ua,\r\n  cases ua 1 zero_lt_one with k h,\r\n  use [k, 1 + |a|],\r\n  intros n hn,\r\n  specialize h n hn,\r\n  calc |u n|\r\n       = |u n - a + a|   : by ring_nf\r\n   ... \u2264 |u n - a| + |a| : abs_add (u n - a) a\r\n   ... \u2264 1 + |a|         : by linarith,\r\nend\r\n<\/pre>\n<p>Se puede interactuar con la prueba anterior en <a href=\"https:\/\/leanprover-community.github.io\/lean-web-editor\/#url=https:\/\/raw.githubusercontent.com\/jaalonso\/Calculemus\/main\/src\/Acotacion_de_convergentes.lean\" rel=\"noopener noreferrer\" target=\"_blank\">esta sesi\u00f3n con Lean<\/a>.<\/p>\n<p>En los comentarios se pueden escribir otras soluciones, escribiendo el c\u00f3digo entre una l\u00ednea con &#60;pre lang=&quot;lean&quot;&#62; y otra con &#60;\/pre&#62;<br \/>\n[\/expand]<\/p>\n<p>[expand title=\u00bbSoluciones con Isabelle\/HOL\u00bb]<\/p>\n<pre lang=\"isar\">\r\ntheory Acotacion_de_convergentes\r\nimports Main HOL.Real\r\nbegin\r\n\r\n(* (limite u c) expresa que el l\u00edmite de u es c. *)\r\ndefinition limite :: \"(nat \u21d2 real) \u21d2 real \u21d2 bool\" where\r\n  \"limite u c \u27f7 (\u2200\u03b5>0. \u2203k. \u2200n\u2265k. \u00a6u n - c\u00a6 \u2264 \u03b5)\"\r\n\r\n(* (convergente u) expresa que u es convergente. *)\r\ndefinition convergente :: \"(nat \u21d2 real) \u21d2 bool\" where\r\n  \"convergente u \u27f7 (\u2203 a. limite u a)\"\r\n\r\n(* 1\u00aa demostraci\u00f3n *)\r\nlemma\r\n  assumes \"convergente u\"\r\n  shows   \"\u2203 k b. \u2200n\u2265k. \u00a6u n\u00a6 \u2264 b\"\r\nproof -\r\n  obtain a where \"limite u a\"\r\n    using assms convergente_def by blast\r\n  then obtain k where hk : \"\u2200n\u2265k. \u00a6u n - a\u00a6 \u2264 1\"\r\n    using limite_def zero_less_one by blast\r\n  have \"\u2200n\u2265k. \u00a6u n\u00a6 \u2264 1 + \u00a6a\u00a6\"\r\n  proof (intro allI impI)\r\n    fix n\r\n    assume hn : \"n \u2265 k\"\r\n    have \"\u00a6u n\u00a6 = \u00a6u n - a + a\u00a6\"    by simp\r\n    also have \"\u2026 \u2264 \u00a6u n - a\u00a6 + \u00a6a\u00a6\" by simp\r\n    also have \"\u2026 \u2264 1 + \u00a6a\u00a6\"         by (simp add: hk hn)\r\n    finally show \"\u00a6u n\u00a6 \u2264 1 + \u00a6a\u00a6\"  .\r\n  qed\r\n  then show \"\u2203 k b. \u2200n\u2265k. \u00a6u n\u00a6 \u2264 b\"\r\n    by (intro exI)\r\nqed\r\n\r\n(* 2\u00aa demostraci\u00f3n *)\r\nlemma\r\n  assumes \"convergente u\"\r\n  shows   \"\u2203 k b. \u2200n\u2265k. \u00a6u n\u00a6 \u2264 b\"\r\nproof -\r\n  obtain a where \"limite u a\"\r\n    using assms convergente_def \r\n    by blast\r\n  then obtain k where hk : \"\u2200n\u2265k. \u00a6u n - a\u00a6 \u2264 1\"\r\n    using limite_def zero_less_one \r\n    by blast\r\n  have \"\u2200n\u2265k. \u00a6u n\u00a6 \u2264 1 + \u00a6a\u00a6\"\r\n    using hk \r\n    by fastforce\r\n  then show \"\u2203 k b. \u2200n\u2265k. \u00a6u n\u00a6 \u2264 b\"\r\n    by auto\r\nqed\r\n\r\nend\r\n<\/pre>\n<p>En los comentarios se pueden escribir otras soluciones, escribiendo el c\u00f3digo entre una l\u00ednea con &#60;pre lang=&quot;isar&quot;&#62; y otra con &#60;\/pre&#62;<br \/>\n[\/expand]<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Demostrar que si u es una sucesi\u00f3n convergente, entonces est\u00e1 acotada; es decir, \u2203 k b, \u2200 n, n \u2265 k \u2192 |u n| \u2264 b Para ello, completar la siguiente teor\u00eda de Lean: import data.real.basic variable {u : \u2115 \u2192 \u211d} variable {a : \u211d} notation `|`x`|` := abs x &#8212; (limite u c) expresa que el l\u00edmite de u es c. def limite (u : \u2115 \u2192 \u211d) (c : \u211d) := \u2200 \u03b5 > 0, \u2203 k, \u2200 n \u2265 k, |u n &#8211; c| \u2264 \u03b5 &#8212; (convergente u) expresa que u es convergente. def convergente (u : \u2115 \u2192 \u211d) := \u2203 a, limite u a example (h : convergente u) : \u2203 k b, \u2200 n, n \u2265 k&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_kad_post_transparent":"","_kad_post_title":"","_kad_post_layout":"","_kad_post_sidebar_id":"","_kad_post_content_style":"","_kad_post_vertical_padding":"","_kad_post_feature":"","_kad_post_feature_position":"","_kad_post_header":false,"_kad_post_footer":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[14],"tags":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/www.glc.us.es\/~jalonso\/calculemus\/wp-json\/wp\/v2\/posts\/598"}],"collection":[{"href":"https:\/\/www.glc.us.es\/~jalonso\/calculemus\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.glc.us.es\/~jalonso\/calculemus\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.glc.us.es\/~jalonso\/calculemus\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.glc.us.es\/~jalonso\/calculemus\/wp-json\/wp\/v2\/comments?post=598"}],"version-history":[{"count":2,"href":"https:\/\/www.glc.us.es\/~jalonso\/calculemus\/wp-json\/wp\/v2\/posts\/598\/revisions"}],"predecessor-version":[{"id":600,"href":"https:\/\/www.glc.us.es\/~jalonso\/calculemus\/wp-json\/wp\/v2\/posts\/598\/revisions\/600"}],"wp:attachment":[{"href":"https:\/\/www.glc.us.es\/~jalonso\/calculemus\/wp-json\/wp\/v2\/media?parent=598"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.glc.us.es\/~jalonso\/calculemus\/wp-json\/wp\/v2\/categories?post=598"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.glc.us.es\/~jalonso\/calculemus\/wp-json\/wp\/v2\/tags?post=598"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}