## Helping Nancy and Esther with a math problem

The Nancy comic strip for June 12 2018 has a math problem which Nancy and Esther seemed to be intimidated by; I figured I would try to help out a little.

## How far apart can squares be?

Consider the squares: 0, 1, 4, 9, 16, 25, 36… “No two squares are 6 apart,” I say. After some subtractions you believe me. Exercise: prove no two squares are 6 apart. “Nor are any two squares 134 apart,” I say. You look at me in surprise. After some puzzlement, inspiration strikes. Exercise: prove that any two…

## Perl scripts to encrypting and decrypt text using Rijndael

I talked about Rijndael in a few previous posts: Expressing a function f: GF(2⁸) → GF(2⁸) as a polynomial using a Lagrange polynomial, Generating the Rijndael S-box, Efficient multiplication and division in GF(28), Sieving irreducible monic polynomials over a finite field, Addition and multiplication table for GF(22). Today I wrote a couple of Perl scripts…

## Expressing a function f: GF(2⁸) → GF(2⁸) as a polynomial using a Lagrange polynomial

I talked about Rijndael in a couple of previous posts: Generating the Rijndael S-box, Efficient multiplication and division in GF(28), Sieving irreducible monic polynomials over a finite field, Addition and multiplication table for GF(22). I’m going to talk some more about it today. The Rijndael non-linear S-box S(x) is a composition of two invertible functions…

## Generating the Rijndael S-box

I talked about Rijndael in a couple of previous posts: Efficient multiplication and division in GF(28), Sieving irreducible monic polynomials over a finite field, Addition and multiplication table for GF(22). I’m going to talk some more about it today. One of the more interesting steps used in the Rijndael transformation is the non-linear S-box. This…

## Efficient multiplication and division in GF(2⁸)

I talked about Rijndael in a couple of previous posts: Sieving irreducible monic polynomials over a finite field, Addition and multiplication table for GF(2²) I’m going to talk some more about it today. Rijndael does a lot of arithmetic operations (addition and multiplication) on elements of GF(28)4. These are represented as polynomials b0 + b1…

## Sieving irreducible monic polynomials over a finite field

Last time we talked about the addition and multiplication tables for GF(2²); GF(28) is relevant for the Rijndael encryption scheme. Joan Daemen and Vincent Rijmen use a representation of GF(28) where each element is a polynomial of the form b7x7 + b6x6 + b5x5 + b4x4 + b3x3 + b2x2 + b1x + b0, with the…

## Addition and multiplication table for GF(2²)

I’m reading Joan Daemen and Vincent Rijmen’s book The Design of Rijndael and I’m giving myself a refresher course on group theory. Key to the encryption standard is the Galois field on 256 elements GF(28). A multiplication table of 256 elements by 256 elements quickly becomes a wall of text, so let’s reason by analogy…

## Why is 1 Pascal equal to 94 dB Sound Pressure Level? (1 Pa = 94 dB SPL)

Last time we talked about why a full-scale digital sine wave has a power measurement of -3.01 dB FS (Spoiler: because it’s not a square wave.) This time we’ll discuss why an atmospheric sound which generates a root-mean-square pressure of 1 Pascal has a power measurement 94 dB SPL. As before, dB is defined as…

## Sample app for RECT functions

Riffing on Raymond Chen’s post today about SubtractRect I threw together a toy app which demonstrates three rectangle functions: UnionRect, IntersectRect, and SubtractRect. Usage: >rects.exerects.exe    union     (left1 top1 right1 bottom1) (left2 top2 right2 bottom2) |    intersect (left1 top1 right1 bottom1) (left2 top2 right2 bottom2) |     subtract  (left1 top1 right1 bottom1) (left2 top2 right2 bottom2) Sample…