{"id":16998,"date":"2016-07-26T02:54:07","date_gmt":"2016-07-26T02:54:07","guid":{"rendered":"http:\/\/www.oracletutoring.ca\/blog\/?p=16998"},"modified":"2016-07-26T02:54:07","modified_gmt":"2016-07-26T02:54:07","slug":"math-linear-congruences","status":"publish","type":"post","link":"https:\/\/www.oracletutoring.ca\/blog\/math-linear-congruences\/","title":{"rendered":"Math:  linear congruences"},"content":{"rendered":"<h1>The tutor solves a system of linear congruences.<\/h1>\n<p>Back in my post from <a href=\"?p=3892\">March 25, 2014,<\/a> I explain that &#8220;mod&#8221; means remainder: for instance, 7 mod 3 = 1.<\/p>\n<p>Two numbers that, divided by a number n, give the same remainder, are called <em>congruent mod n<\/em>.  For example, 24 mod 5 = 4, and also 29 mod 5 = 4.  Therefore, 24 is congruent to 29 mod 5.  This can be written<\/p>\n<p style=\"text-align:center\">24 &#8801; 29 mod 5<\/p>\n<p><strong>Example: question 10a, page 41,  from Underwood Dudley<\/strong>:<\/p>\n<p>Consider the system of linear congruences<\/p>\n<p style=\"text-align:center\">x + 2y &#8801; 3 (mod 9)<br \/>3x + y &#8801; 2 (mod 9)<\/p>\n<p>Solution:  The first congruence suggests that <\/p>\n<p style=\"text-align:center\">x + 2y = 9k + 3 for some integer k<\/p>\n<p style=\"text-align:center\">&#8658; x = 9k + 3 &#8211; 2y<\/p>\n<p>Substituting into the second congruence, we get<\/p>\n<p style=\"text-align:center\">3(9k + 3 &#8211; 2y) + y &#8801; 2 (mod 9)<\/p>\n<p>then<\/p>\n<p style=\"text-align:center\">27k + 9 -6y + y &#8801; 2 (mod 9)<\/p>\n<p>which means<\/p>\n<p style=\"text-align:center\">27k + 9 -5y = 9m + 2 for some integer m.<\/p>\n<p style=\"text-align:center\">-5y = 9m + 2 &#8211; 27k &#8211; 9<\/p>\n<p>Therefore,<\/p>\n<p style=\"text-align:center\">-5y = 9(m -3k -1) + 2 &#8801; 2 (mod 9)<\/p>\n<p>From<\/p>\n<p style=\"text-align:center\">-5y &#8801; 2 (mod 9)<\/p>\n<p>we can multiply both sides by -1 to arrive at<\/p>\n<p style=\"text-align:center\">5y &#8801; -2 (mod 9)<\/p>\n<p>Since -2 + 9 = 7, we can rewrite the congruence as<\/p>\n<p style=\"text-align:center\">5y &#8801; 7 (mod 9)<\/p>\n<p>Mod 9, there are only the integers 0 to 8. Trying each one, we realize y = 5:<\/p>\n<p style=\"text-align:center\">5(5) &#8801; 7 (mod 9) since  25 mod 9 = 7<\/p>\n<p>If y=5, we can sub it into the first equation<\/p>\n<p style=\"text-align:center\">x + 2(5) &#8801; 3 (mod 9)<\/p>\n<p style=\"text-align:center\">x + 10 &#8801; 3 (mod 9)<\/p>\n<p>Subtracting 10 from both sides gives<\/p>\n<p style=\"text-align:center\">x &#8801; -7 (mod 9)<\/p>\n<p>meaning<\/p>\n<p style=\"text-align:center\">x &#8801; 2 (mod 9)<\/p>\n<p>So we have x = 9p + 2 and y = 9q +5, for any integers p,q.<\/p>\n<p>I&#8217;ll be discussing more about linear congruences in future posts:)<\/p>\n<p>Source:<\/p>\n<p>Dudley, Underwood.  <u>Elementary Number Theory<\/u>,<br \/>second edition.&nbsp;&nbsp;New York:  W H Freeman and Company, 1978.<\/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 solves a system of linear congruences. Back in my post from March 25, 2014, I explain that &#8220;mod&#8221; means remainder: for instance, 7 mod 3 = 1. Two numbers that, divided by a number n, give the same &hellip;<\/p>\n<p class=\"read-more\"> <a class=\"more-link\" href=\"https:\/\/www.oracletutoring.ca\/blog\/math-linear-congruences\/\"> <span class=\"screen-reader-text\">Math:  linear congruences<\/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":[3,1677],"tags":[1749,1748],"class_list":["post-16998","post","type-post","status-publish","format-standard","hentry","category-math","category-number-theory","tag-linear-congruences","tag-mod"],"_links":{"self":[{"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/posts\/16998","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=16998"}],"version-history":[{"count":35,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/posts\/16998\/revisions"}],"predecessor-version":[{"id":17033,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/posts\/16998\/revisions\/17033"}],"wp:attachment":[{"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/media?parent=16998"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/categories?post=16998"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.oracletutoring.ca\/blog\/wp-json\/wp\/v2\/tags?post=16998"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}