{"id":210,"date":"2016-06-30T05:49:22","date_gmt":"2016-06-30T05:49:22","guid":{"rendered":"http:\/\/konukoii.com\/blog\/?p=210"},"modified":"2016-06-30T05:49:22","modified_gmt":"2016-06-30T05:49:22","slug":"calculating-nonlinearity-of-boolean-functions-with-walsh-hadamard-transform","status":"publish","type":"post","link":"https:\/\/konukoii.com\/blog\/2016\/06\/30\/calculating-nonlinearity-of-boolean-functions-with-walsh-hadamard-transform\/","title":{"rendered":"Calculating Nonlinearity of Boolean Functions with Walsh-Hadamard Transform"},"content":{"rendered":"<span class=\"span-reading-time rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\">Reading Time: <\/span> <span class=\"rt-time\"> 2<\/span> <span class=\"rt-label rt-postfix\">minutes<\/span><\/span><p>It was during Winter 2016 that I took an extremely interesting course on Computational Algebra. This course was solely devoted to analyzing topics that ranged from cryptography to error-resistant functions. Among the many topics, one that stood out for me was LFSRs (Linear Feedback Shift Registers).<\/p>\n<p>LFSRs\u00a0are simple circuits that use their internal state to calculate a linear function. The output of the function is then fed into the circuit's new state, and the cycle continues. Perhaps that sounds a bit to abstract right now. The truth is that I will most likely write about them in the weeks to come. (Because they are fascinating!). Wikipedia has a nice little animation that shows one in action:<\/p>\n<figure style=\"width: 500px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/upload.wikimedia.org\/wikipedia\/commons\/7\/7f\/LFSR-F4.GIF\" width=\"500\" height=\"300\" \/><figcaption class=\"wp-caption-text\">LFSR in Action - Source: Cuddlyable3 @ wikipedia.com\u00a0<\/figcaption><\/figure>\n<p>However, this article is not about LFSRs, but rather something even more fundamental: Boolean Functions.<\/p>\n<p>Boolean functions are simply functions whose variables are either a 0 or a 1. While this might seem quite simple, it is the basis of substantially complex cryptographic constructs. In cryptography, researchers are particularly concered on a the \"non-linearity\" property of boolean function. Non-Linearity is a measure by which we are able to determine the inputs of the function given the output.<\/p>\n<p>For a trivial example, imagine we have a function <strong>f(x<sub>1<\/sub>,x<sub>2<\/sub>)\u00a0= x<sub>1<\/sub>+x<sub>2<\/sub><\/strong>\u00a0 and another function <strong>g(x<sub>1<\/sub>,x<sub>2<\/sub>)\u00a0= x<sub>1\u00a0<\/sub>.\u00a0<\/strong>Clearly, it is easier to correlate the output of g to it's inputs (namely if g = 1 then x<sub>1<\/sub> = 1 and if g = 0 then x<sub>1<\/sub> = 0) than f with its inputs (although it is not that terribly hard). The overall idea is that the harder it is to figure out the inputs of a function given it's output, the more \"non-linear\" it is and the more cryptographically useful it becomes.<\/p>\n<p>The following is a \"tutorial\" style paper that explains the basis of boolean functions and how to compute their non-linearity. It explains how to calculate such non-linearity in one of the most refined and proficient ways to do so: with the Fast Walsh-Hadamard Transform. I also included a bit more information on what it means for a function to be \"non-linear\" and what benefits this brings.<\/p>\n<p>(You can also check this paper out in the Academia.edu <a href=\"https:\/\/www.academia.edu\/26618638\/Calculating_Nonlinearity_of_Boolean_Functions_with_Walsh-Hadamard_Transform\">link<\/a>.)<\/p>\n<div class=\"ead-preview\"><div class=\"ead-document\" style=\"position: relative;\"><div class=\"ead-iframe-wrapper\"><iframe src=\"\/\/docs.google.com\/viewer?url=http%3A%2F%2Fkonukoii.com%2Fblog%2Fwp-content%2Fuploads%2F2016%2F06%2FFinalPaper.pdf&amp;embedded=true&amp;hl=en\" title=\"Embedded Document\" class=\"ead-iframe\" style=\"width: 100%;height: 500px;border: none;visibility: hidden;\"><\/iframe><\/div>\t\t\t<div class=\"ead-document-loading\" style=\"width:100%;height:100%;position:absolute;left:0;top:0;z-index:10;\">\n\t\t\t\t<div class=\"ead-loading-wrap\">\n\t\t\t\t\t<div class=\"ead-loading-main\">\n\t\t\t\t\t\t<div class=\"ead-loading\">\n\t\t\t\t\t\t\t<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/konukoii.com\/blog\/wp-content\/plugins\/embed-any-document\/images\/loading.svg\" width=\"55\" height=\"55\" alt=\"Loader\">\n\t\t\t\t\t\t\t<span>Loading...<\/span>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t\t\t\t<div class=\"ead-loading-foot\">\n\t\t\t\t\t\t<div class=\"ead-loading-foot-title\">\n\t\t\t\t\t\t\t<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/konukoii.com\/blog\/wp-content\/plugins\/embed-any-document\/images\/EAD-logo.svg\" alt=\"EAD Logo\" width=\"36\" height=\"23\"\/>\n\t\t\t\t\t\t\t<span>Taking too long?<\/span>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t<p>\n\t\t\t\t\t\t\t<div class=\"ead-document-btn ead-reload-btn\" role=\"button\">\n\t\t\t\t\t\t\t\t<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/konukoii.com\/blog\/wp-content\/plugins\/embed-any-document\/images\/reload.svg\" alt=\"Reload\" width=\"12\" height=\"12\"\/> Reload document\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t<span>|<\/span>\n\t\t\t\t\t\t\t<a href=\"http:\/\/konukoii.com\/blog\/wp-content\/uploads\/2016\/06\/FinalPaper.pdf\" class=\"ead-document-btn\" target=\"_blank\">\n\t\t\t\t\t\t\t\t<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/konukoii.com\/blog\/wp-content\/plugins\/embed-any-document\/images\/open.svg\" alt=\"Open\" width=\"12\" height=\"12\"\/> Open in new tab\t\t\t\t\t\t\t<\/a>\n\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t<\/div>\n\t\t<\/div><\/div>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>It was during Winter 2016 that I took an extremely interesting course on Computational Algebra.&#8230;<\/p>\n<div class=\"more-link-wrapper\"><a class=\"more-link\" href=\"https:\/\/konukoii.com\/blog\/2016\/06\/30\/calculating-nonlinearity-of-boolean-functions-with-walsh-hadamard-transform\/\">Read the post<span class=\"screen-reader-text\">Calculating Nonlinearity of Boolean Functions with Walsh-Hadamard Transform<\/span><\/a><\/div>\n","protected":false},"author":1,"featured_media":120,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[49,39,40,28,50],"class_list":["post-210","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-cryptography","tag-boolean-functions","tag-cryptography","tag-lfsr","tag-ucsb","tag-walsh-hadamard-transform","excerpt","zoom","full-without-featured","even","excerpt-0"],"_links":{"self":[{"href":"https:\/\/konukoii.com\/blog\/wp-json\/wp\/v2\/posts\/210","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/konukoii.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/konukoii.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/konukoii.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/konukoii.com\/blog\/wp-json\/wp\/v2\/comments?post=210"}],"version-history":[{"count":2,"href":"https:\/\/konukoii.com\/blog\/wp-json\/wp\/v2\/posts\/210\/revisions"}],"predecessor-version":[{"id":213,"href":"https:\/\/konukoii.com\/blog\/wp-json\/wp\/v2\/posts\/210\/revisions\/213"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/konukoii.com\/blog\/wp-json\/wp\/v2\/media\/120"}],"wp:attachment":[{"href":"https:\/\/konukoii.com\/blog\/wp-json\/wp\/v2\/media?parent=210"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/konukoii.com\/blog\/wp-json\/wp\/v2\/categories?post=210"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/konukoii.com\/blog\/wp-json\/wp\/v2\/tags?post=210"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}