If you remember the words in a seed phrase out of order, try permutations in order of their permutation distance from what you remember.| John D. Cook
Base58 and Base85 can easily be confused and they differ in subtle ways.| John D. Cook
About how many items can you expect to hash with a secure hash function before risking into collisions? Here's a rule of thumb and a proof.| John D. Cook
The birthday problem, sometimes called the birthday paradox, says that it's more likely than you'd expect that two people in a group have the same birthday. Specifically, in a random sample of 23 people, there's about a 50-50 chance that two people share the same birthday. The birthday problem makes a nice party trick, but| John D. Cook
What is randomness? Nobody knows, or at least there's no consensus. Everybody has some vague ideas what randomness is, but when you dig into it deeply enough you find all kinds of philosophical quandaries. If you'd like a taste of the subtleties, you could start by reading one of Gregory Chaitin's books. Or chew on| John D. Cook
How likely is it that a mistyped Bitcoin address is a valid address? How likely is it that some address is a plausible typo of another?| John D. Cook
Powers of the golden ratio are nearly integers. This post explains why. Also, these integers are the sum of two Fibonacci numbers.| John D. Cook
Visualizing a determinant identity whose symmetry is obscured by its algebraic expression.| John D. Cook
The idea of an 8-bit floating point number sounds kinda crazy at first, but they come in handy in applications where you don't need much precision and you're memory constrained. Comparing IEEE-like numbers and posit numbers.| John D. Cook
Posit numbers make more efficient use of the bits representing real numbers than do conventional IEEE floating point numbers. This post explains what posits are, how their bits are interpreted, their dynamic range, etc.| John D. Cook
How to calculate large powers of 3 + √2 numerically with bc and symbolically with Mathematica. Conjecture regarding the integer and irrational parts.| John D. Cook
First Brian Hayes wrote an excellent post about the remainders when primes are divided by other primes. Then I wrote a follow-on just focusing on the first part of his post. He mostly looked at pairs of primes, but I wanted to look in more detail at the first part of his post, simulating dice| John D. Cook
There are five Platonic (regular) solids: tetrahedron, 4 triangular sides hexahedron (i.e. cube), 6 square sides octahedron, 8 triangular sides dodecahedron, 12 pentagonal sides icosahedron, 20 triangular sides Each face of a Platonic solid must be a regular polygon and each face must be congruent. Also, the solid must be convex and the number of| John D. Cook
What exactly does it mean to say a number is PROBABLY prime?| John D. Cook
There’s a well-known formula for the sum of the first n positive integers:| www.johndcook.com
How to handle floating point exceptions such as 1.#IND, 1.#INF, nan, and inf| John D. Cook
Knowing the details of how floating point numbers are implemented can help you avoid problems with them.| John D. Cook | Applied Mathematics Consulting
My two latest blog posts have been about compound interest. I gave examples of interest rates of 6% up to 18% per year.| www.johndcook.com
A plot of the log of a row in Pascal's triangle makes a circular arc.| John D. Cook
Python code for finding the distance between two points on earth, taking into account the equatorial bulge (oblate spheroid shape).| John D. Cook
For any x, the behavior of multiples of x mod 1 is easy to classify. The powers of x mod 1 are more interesting. We give examples of different behavior.| John D. Cook
Fresnel ellipsoids are regions of space in which obstacles will cause destructive interference for radio transmission. Post explains why ellipsoids.| John D. Cook
Most numbers that are representable as machine integers are not exactly representable as floating point numbers.| John D. Cook
Gardener's method for drawing an ellipse and how it could be useful in computer graphics| John D. Cook
Suppose you have n cannonballs and want to stack them in tetrahedral stacks. How many stacks will you need?| John D. Cook
I sold six technical books to a used book store on the way home today. The store paid me $5 total for four of the books. Two books they didn't want at all. The books were not that old, but they were practically worthless. It's sobering to think how little a technical book is worth| John D. Cook
Programmers write a lot of code that is never used. There are numerous reasons for this. In Peter Seibel's book Coders at Work, Peter Norvig gives his take on why this happens. Seibel: Why is it so tempting to solve a problem we don't really have? Norvig: You want to be clever and you want| John D. Cook
The Star Trek opening theme is a famous example of a quartal melody.| John D. Cook
Equations and Python code for going back and forth between quaternion and matrix representations of rotations.| John D. Cook
Examples of how to use a chi-square goodness of fit test and what it says about a pattern in prime numbers| John D. Cook
Functional analysis is central to applications such as differential equations, approximation theory, control theory, optimization, etc.| John D. Cook
Contact info for John D. Cook Consulting. Phone, email, Twitter, etc. Reach out for a free consultation on how we can help your business.| John D. Cook
How the bits of a floating point number are organized, how (de)normalization works, etc.| John D. Cook
People are able to copy Morse code at a rate that seems to exceed the limits of human perception. How is this possible?| John D. Cook | Applied Mathematics Consulting
The Fredholm index, its robustness, and how it relates to Euler characteristic| John D. Cook
Kernel and cokernel are dual concepts, but the former is far more likely to appear in textbooks. The cokernel is often in the background without a name.| John D. Cook
I’m really tired of seeing the nonsense claim that appears in the title of this article, which is a clear and concise explanation for why it is nonsense.| lee-phillips.org
I knew about dual numbers from studying automatic differentiation, but had never heard of double numbers. John Cook reveals a surprising variation of the familiar Euler’s formula.| lee-phillips.org
Expert consultants with experience providing expert determination under the HIPAA Privacy Rule. Clients in insurance, law, medical devices, research, and more.| John D. Cook
The Kullback-Leibler divergence between two probability distributions is sometimes called a "distance," but it's not. Here's why.| John D. Cook
Adding Laplace or Gaussian noise to a database can protect privacy while preserving statistical usefulness.| John D. Cook
Suppose a value came from one of two random variables. An extreme value most likely came from the random variable with greater variance.| John D. Cook
Rényi differential privacy is a variation on differential privacy less pessimistic than ε-DP and with simpler accounting than δ-DP.| John D. Cook
How to evaluate the gamma function of a complex argument using tables. How to extend the range and resolution of the tabulated values.| John D. Cook
How to use a table of sines and cosines of angles 0° to 45° to calculate sines and cosines angles outside the range and beyond the resolution of the table.| John D. Cook
Practical calculation using numerical tables is not simply a matter of looking up numbers. You had to be more sophisticated than that.| John D. Cook
What do you learn just in case you'll need it in the future, and what do you learn just in time when you do need it? In general, you learn things in school just in case you'll need them later. Then once you get a job, you learn more things just as you need them.| John D. Cook