{"id":495,"date":"2026-11-14T01:54:25","date_gmt":"2026-11-14T01:54:25","guid":{"rendered":"https:\/\/petermc.net\/blog\/?p=495"},"modified":"2026-11-14T01:54:25","modified_gmt":"2026-11-14T01:54:25","slug":"linear-recurrences-and-applications-to-sudoku","status":"publish","type":"post","link":"https:\/\/petermc.net\/blog\/2026\/11\/14\/linear-recurrences-and-applications-to-sudoku\/","title":{"rendered":"Linear recurrences and applications to sudoku"},"content":{"rendered":"<p>Warning: Spoilers for <a href=\"https:\/\/logic-masters.de\/Raetselportal\/Raetsel\/zeigen.php?id=000JUQ\">this puzzle<\/a> ahead.<\/p>\n<p>I am not a fan of sudoku puzzles.<\/p>\n<p>However there are sudoku variants that are interesting. Usually when they solve nothing like a sudoku.<\/p>\n<p>I want to share something that came up when I solved <a href=\"https:\/\/logic-masters.de\/Raetselportal\/Raetsel\/zeigen.php?id=000JUQ\">Lots in Space: Deconstructica by Marty Sears<\/a>.<\/p>\n<p>The puzzle has lines, where any three consecutive entries along a line have a different residue modulo 3 (which of course implies the sequence is periodic mod 3). And there are blue diamonds, where a digit on a blue diamond tells you how many distinct sums of adjacent pairs of numbers along that line there are.<\/p>\n<p>Now suppose there is a 3 in a blue diamond. Let <img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/petermc.net\/blog\/wp-content\/ql-cache\/quicklatex.com-fa81c5500986048bbd05b8d0cee7f554_l3.png\" class=\"ql-img-inline-formula quicklatex-auto-format\" alt=\"&#97;&#95;&#49;&#44;&#97;&#95;&#50;&#44;&#92;&#108;&#100;&#111;&#116;&#115;\" title=\"Rendered by QuickLaTeX.com\" height=\"12\" width=\"70\" style=\"vertical-align: -4px;\"\/> be the entries along the line. The mod 3 condition, together with the fact that there are only three distinct sums of adjacent pairs tells you that <img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/petermc.net\/blog\/wp-content\/ql-cache\/quicklatex.com-f7bbe92b1dec55733c3a9b146b50faf9_l3.png\" class=\"ql-img-inline-formula quicklatex-auto-format\" alt=\"&#97;&#95;&#105;&#43;&#97;&#95;&#123;&#105;&#43;&#49;&#125;\" title=\"Rendered by QuickLaTeX.com\" height=\"16\" width=\"68\" style=\"vertical-align: -5px;\"\/> is a function of <img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/petermc.net\/blog\/wp-content\/ql-cache\/quicklatex.com-5cb9d5d4525b16ef0c88207179b9ae09_l3.png\" class=\"ql-img-inline-formula quicklatex-auto-format\" alt=\"&#105;&#32;&#92;&#112;&#109;&#111;&#100;&#123;&#51;&#125;\" title=\"Rendered by QuickLaTeX.com\" height=\"19\" width=\"76\" style=\"vertical-align: -5px;\"\/> only. Thus we get a recurrence<\/p>\n<p class=\"ql-center-displayed-equation\" style=\"line-height: 15px;\"><span class=\"ql-right-eqno\"> &nbsp; <\/span><span class=\"ql-left-eqno\"> &nbsp; <\/span><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/petermc.net\/blog\/wp-content\/ql-cache\/quicklatex.com-d0b78d349fbb8aef41659103690969a8_l3.png\" height=\"15\" width=\"179\" class=\"ql-img-displayed-equation quicklatex-auto-format\" alt=\"&#92;&#91;&#97;&#95;&#105;&#43;&#97;&#95;&#123;&#105;&#43;&#49;&#125;&#61;&#97;&#95;&#123;&#105;&#43;&#51;&#125;&#43;&#97;&#95;&#123;&#105;&#43;&#52;&#125;&#92;&#93;\" title=\"Rendered by QuickLaTeX.com\"\/><\/p>\n<p>The characteristic equation of this recurrence divides <img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/petermc.net\/blog\/wp-content\/ql-cache\/quicklatex.com-fc0381cc50d8f2a8c38e0e5646be6528_l3.png\" class=\"ql-img-inline-formula quicklatex-auto-format\" alt=\"&#120;&#94;&#54;&#45;&#49;\" title=\"Rendered by QuickLaTeX.com\" height=\"15\" width=\"47\" style=\"vertical-align: 0px;\"\/>, so the solution is 6-periodic. I used this in my solve, but something tells me this was not an intended approach.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Warning: Spoilers for this puzzle ahead. I am not a fan of sudoku puzzles. However there are sudoku variants that are interesting. Usually when they solve nothing like a sudoku. I want to share something that came up when I &hellip; <a href=\"https:\/\/petermc.net\/blog\/2026\/11\/14\/linear-recurrences-and-applications-to-sudoku\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[1],"tags":[],"class_list":["post-495","post","type-post","status-publish","format-standard","hentry","category-uncategorised"],"jetpack_publicize_connections":[],"jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p7V6a7-7Z","jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/petermc.net\/blog\/wp-json\/wp\/v2\/posts\/495","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/petermc.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/petermc.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/petermc.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/petermc.net\/blog\/wp-json\/wp\/v2\/comments?post=495"}],"version-history":[{"count":2,"href":"https:\/\/petermc.net\/blog\/wp-json\/wp\/v2\/posts\/495\/revisions"}],"predecessor-version":[{"id":497,"href":"https:\/\/petermc.net\/blog\/wp-json\/wp\/v2\/posts\/495\/revisions\/497"}],"wp:attachment":[{"href":"https:\/\/petermc.net\/blog\/wp-json\/wp\/v2\/media?parent=495"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/petermc.net\/blog\/wp-json\/wp\/v2\/categories?post=495"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/petermc.net\/blog\/wp-json\/wp\/v2\/tags?post=495"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}