## Sunday, December 28, 2008

### Patterns in Binary Lists

When you list out the binary numbers that result from a function, patterns naturally develop vertically - within in place value column. It's more obvious than it sounds - look at a list of the binary results for f(x)=x from f(0) to f(7):

000
001
010
011
100
101
110
111

In the first column (2^0), the pattern is 0101010101 and so on. In the second column (2^1), the pattern is 00110011..., the third column is 00001111... Because these are so simple, you can see what the pattern is without really thinking about it. Naturally, as f(x) gets more complicated, so do the patterns.

But the more complex patterns are pretty, so I needed a way to generate the pattern of any given column for a function f(n). This is really very simple - I wrote a function that produces the binary digit in a given place value (2^k) of a given number (n):

([n-n%(2^k)]%[2^(k+1)])/(2^k)

Make this into a series, and substitute f(n) for n, and I have the formula for the columnar pattern in a given f(n) and place value value.

b
Σ   [([f(n)-f(n)%(2^k)]%[2^(k+1)])/(2^k)]*(10^n)
n=0

Using this formula, the pattern for the 2^4 column of f(x)=x^2 from 1 to 16 is:

000110101011000

It's prettier when the trailing and leading zeros are removed:

110101011

That is my useless and probably not original (but pretty) contribution to mathematics for the day. Thank you.

EDIT: The equation will generate the proper digit, but as the series loops, the digits will not add together into a nice and tidy list. To remedy this, one must multiply the whole business by 10^n, as shown in red above, to put each one into its proper place value.

## Friday, December 26, 2008

### Centipede Bear

This bear was a gift for my sister - I suppose it could be considered an arachnid, what with having eight legs (six arms and two legs, but still), but it has more of a centipede look to it.

### Dewey Decimal Clock

As I write this, the time is 8:05, or "Serial Publications," depending on which clock you look at. I've added a little gadget to this mess (over there, on the side bar) called "Dewey Decimal Time" that provides you with access to the latter sort of clock.

I'll assume that you know what the dewey decimal system is.

A clock that runs in dewey decimal is less obvious, but really quite simple. The time is, in its standard form, numbers. The dewey decimal system also uses numbers. So all the clock does is convert the time to a three digit number (9:03 matches up with the dewey decimal category 903).

Naturally, some accommodation must be made for any time later than 9:59. For these, I simply add the middle two digits (10:29 produces 129, and 12:52 produces 172).

It may not ever become a widely used system of time, but it has some of the character that the usual digital clock lacks.

### Random sketch: Science

This is what I imagine it is like to be a scientist. Accordingly, I had to do some tailoring on my lab coat for chemistry class.

## Tuesday, December 23, 2008

### Mandelbrot the Fractal Bear

Continuing my mutant teddy bear theme, a gift for my brother: the fractal bear.

His name is Mandelbrot.

UPDATE! People who are asking me about buying a fractal bear of their very own, see here

## Saturday, December 13, 2008

### Random sketch: Tsiology

Tsiology: noun, a treatise on tea.

### Prisoner's Dilemma

I wrote a little java applet for a simulation game of the prisoner's dilemma ages ago. After changing computers a couple times and many years passing, I had lost the source code. And for some reason my decompiler (which has always served me in the past) just pulled up blank .java files when I try to get the code from the .class file that I had online.

But this is for the best! In all likelihood, it was very bad, untidy code. And the scoring was wrong. So I rewrote the thing from scratch, and now have a sleek little time-waster, which, as far as I can tell, I can't embed in a blog, so it can be found over at utterly pointless, complete with an explanation.

Sure, the graphics aren't the 3D avant-garde, but I like to think I have made my contribution to the gaming world.

## Friday, December 12, 2008

### Emperor Norton I

I made this when teaching myself to embroider. I apologize for the inferiority of my stitching - it was a first try.

If you don't know about Emperor Norton, then you should go do some research; it's well worth your time, and a part of US History that is not given nearly enough consideration.

### Random sketch: Ghost!

Mildly inspired by the awesomeness of Freeman Dyson.

### Binary!

I've been sketching binary in my notes ever since I learned what binary was - I usually draw a box for every 1 and leave a blank for 0. There is a load of things you can do with this (try making the 1s into cubes and translating words into binary and then stacking them into massive 3D structures). It's pretty time consuming (and difficult at times), which is what makes it fun, but also serves as a limitation when I want to look a the patterns that are produced.

So I wrote a quick javascript bit to generate binary with black boxes for 1 and light grey for 0 - it has the place value along the top (the leftmost column is 1, then 2, 4, 8, et cetera moving to the right) and each row is a number in a function f(x). The image to the right is f(x)=x. It is much prettier when drawn by hand, but the pattern is lovely either way.

Notice that each column has a pattern - the rightmost one is every other, the next is two 1s and then two 0s - it's pretty obvious how it will continue in this case.

It get more complicated as the function gets more complicated, or course.
Here is f(x)=x^2

There is still a pattern to each column, but much less obvious.
But that's not all! There's another way that I like to visualize it - using
a diagonal line instead of a solid going from right to left or left to right depending on the number. This tends to just look like noise when the functions get more complex, but it can produce some lovely results.

The clip I've got here if f(x)=x, starting at about f(101), as there is more to see with the bigger numbers.

### Victoria Doll

This is Victoria - I made her out of a flannel comforter bag of mysterious origins and scrap cloth from old projects. Her right-most eye was the upper casing of an antique watch. Beyond that, she is mostly just immensely huggable, and creeps out my roommates.

A full view:

### Teddy Bear

It has all the cuddliness of three teddy bears in one! Pictured here is my as-of-yet-unnamed teddy bear - it's a bit lopsided, but that is the price of having two legs that come from different bodies.