{"id":16573,"date":"2016-07-06T21:36:28","date_gmt":"2016-07-06T21:36:28","guid":{"rendered":"http:\/\/www.oracletutoring.ca\/blog\/?p=16573"},"modified":"2017-12-19T18:55:44","modified_gmt":"2017-12-19T18:55:44","slug":"math-2nd-degree-difference-equation-example-aka-2nd-degree-recurrence-relation-recursive-function","status":"publish","type":"post","link":"https:\/\/www.oracletutoring.ca\/blog\/math-2nd-degree-difference-equation-example-aka-2nd-degree-recurrence-relation-recursive-function\/","title":{"rendered":"Math:  2nd degree difference equation example (aka 2nd degree recurrence relation, recursive function)"},"content":{"rendered":"<h1>The tutor starts towards the general solution to a 2nd degree difference equation, aka recurrence relation.<\/h1>\n<p>Back in my <a href=\"?p=16190\">June 21 post,<\/a> the following recurrence relation emerged:<\/p>\n<table style=\"width:30%;margin:auto\">\n<tr>\n<td class=\"jul6_2016\">n<\/td>\n<td class=\"jul6_2016\">t<sub>n<\/sub><\/td>\n<\/tr>\n<td class=\"jul6_2016\">0<\/td>\n<td class=\"jul6_2016\">1<\/td>\n<\/tr>\n<td class=\"jul6_2016\">1<\/td>\n<td class=\"jul6_2016\">1<\/td>\n<\/tr>\n<td class=\"jul6_2016\">2<\/td>\n<td class=\"jul6_2016\">2<\/td>\n<\/tr>\n<td class=\"jul6_2016\">3<\/td>\n<td class=\"jul6_2016\">3<\/td>\n<\/tr>\n<td class=\"jul6_2016\">4<\/td>\n<td class=\"jul6_2016\">5<\/td>\n<\/tr>\n<\/table>\n<p>The tabulated relationship above can be written as t<sub>n+2<\/sub>=t<sub>n+1<\/sub>+t<sub>n<\/sub>, and then as t<sub>n+2<\/sub> &#8211; t<sub>n+1<\/sub> &#8211; t<sub>n<\/sub> = 0<\/p>\n<p>The equation above is a second degree homogeneous recurrence equation.  Its general solution will be of the form<\/p>\n<p>t<sub>n<\/sub>=as<sub>1<\/sub>^n + bs<sub>2<\/sub>^n,<\/p>\n<p>where s<sub>1<\/sub>, s<sub>2<\/sub> are the solutions to the related quadratic equation<\/p>\n<p>x^2-x-1=0<\/p>\n<p>Using the quadratic formula (see my post <a href=\"?p=11877\">here<\/a>), we get<\/p>\n<p>x=(1+5^0.5)\/2 or x=(1-5^0.5)\/2<\/p>\n<p>So the general solution to the recursive equation t<sub>n+2<\/sub> &#8211; t<sub>n+1<\/sub> &#8211; t<sub>n<\/sub> = 0 will be<\/p>\n<p>t<sub>n<\/sub> = a((1+5^0.5)\/2)^n + b((1-5^0.5)\/2)^n<\/p>\n<p>where a,b are constants to determine.  Next post, I&#8217;ll show how to determine a and b in order to arrive at the definitive solution.<\/p>\n<p>Source:<\/p>\n<p>Grimaldi, Ralph P.  <u>Discrete and Combinatorial Mathematics<\/u>.  Don Mills:<br \/>&nbsp;&nbsp;&nbsp;Addison-Wesley, 1994.<\/p>\n<p>Jack of <a href=\"https:\/\/www.oracletutoring.ca\">Oracle Tutoring by Jack and Diane,<\/a> Campbell River, BC.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The tutor starts towards the general solution to a 2nd degree difference equation, aka recurrence relation. Back in my June 21 post, the following recurrence relation emerged: n tn 0 1 1 1 2 2 3 3 4 5 The &hellip;<\/p>\n<p class=\"read-more\"> <a class=\"more-link\" href=\"https:\/\/www.oracletutoring.ca\/blog\/math-2nd-degree-difference-equation-example-aka-2nd-degree-recurrence-relation-recursive-function\/\"> <span class=\"screen-reader-text\">Math:  2nd degree difference equation example (aka 2nd degree recurrence relation, recursive function)<\/span> Read More &raquo;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[105,3],"tags":[1476,1695,1696,1475,1697],"class_list":["post-16573","post","type-post","status-publish","format-standard","hentry","category-computer-science","category-math","tag-difference-equation","tag-homogeneous-second-degree-recurrence-relation","tag-how-to-solve-homogeneous-second-degree-recurrence-relation","tag-recurrence-relation","tag-second-degree-difference-equation"],"_links":{"self":[{"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/posts\/16573","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/comments?post=16573"}],"version-history":[{"count":44,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/posts\/16573\/revisions"}],"predecessor-version":[{"id":27303,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/posts\/16573\/revisions\/27303"}],"wp:attachment":[{"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/media?parent=16573"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/categories?post=16573"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/tags?post=16573"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}