Archive for August, 2009

mo

Monday, August 31st, 2009

Dinosaur Island Challenge on Facebook

Tuesday, August 18th, 2009

Facebook hosts a series of programming challenges. The latest one is called Dinosaur Island and involves a “Server” that hosts a persistent environment called Dinosaur Island. The challenge is to write a client that can compete against other people’s clients, reproduce and thrive.

The client program you write gets compiled into a framework for cross language services called Thrift, which was open sourced by Facebook and is now an Apache project. Thrift is a way to do Remote Procedure Calls across languages. It compiles your code into “same”, kind of like the java compiler compiling your java code into bytecode. Compiled this way, all the parts of a distributed Thrift application would be in the same language as opposed to SOAP, where you would need all kinds of services hooks to make it work.

I can see why Facebook would use a language interoperability framework like Thrift because this allows developers to make applications in any language and have them work on Facebook. It also allows all the disparate parts of Facebook to work together, even when they acquire another company.

The Dinosaur Island idea hints at where Facebook wants to go in the future. Maybe it starts serving up engaging and persistent environments, or opens up its infrastructure to developers who want to create their own persistent environments like Dinosaur Island.

bike spoke pov

Tuesday, August 18th, 2009

LEDs on bike spokes used to create images. It is called spoke Persistence of Vision (POV) and looks really fun.

and these freaks decided to add an odometer and speedometer display :

One the one hand, I think of all the parts of this that could fall off and get caught in the spokes. On the other hand, this would be such a great homeschool project.

Tour with Frank

Monday, August 17th, 2009

Frank and I took a 30 mile bike ride yesterday. He was tireless. We passed the new Twin’s stadium.

Frank: Why did they build a new stadium?
Tim: The team wanted it.
Frank: The WHOLE team?
Tim: yes the owners, the players.
Frank All the players?
Tim: Yes.
Frank: Even the Juicers?

Wearing a Device?

Tuesday, August 11th, 2009

So, you want me to have a device by my side day and night, a device that allows me to be contacted instantly, roused from whatever original thoughts I might manage tohan piece together in rare moments of silence? A device that records my location, conversations, purchases and keeps me trained to repsond properly to beeps and bells and social cues? A device that keeps me reminded of my sectarian biases? A device that has a slightly better chance of making me drive off the road than if I just had four drinks?

and for this privilege, I pay $40 to $100 per month?

And, as of this writing, this is optional? So I can pass? Good.

So, um.. yeah. Can’t afford a G1. Its too bad because I was really looking forward to bumping mine against someone else’s, you know, to share stuff.

a cognitive linguist hits the nail on the head.

Friday, August 7th, 2009

Bernard Malumud and Phillip Roth

Wednesday, August 5th, 2009

Indignation Indignation by Philip Roth


My rating: 4 of 5 stars
In Indignation, the character starts out in what could be a Bernard Malamud short story, a son of an over-protective Jewish butcher going to a local college. To escape, he pulls a stunt that is not available to Bernard Malamud’s characters and blasts off for middle America and gets embroiled in the “Indigenous American Berserk” at a small Midwestern liberal arts college in the 1950s. Like in every Roth book, someone blasts man gravy all over an inanimate object, so readers have that to look forward to. Our protagonist manages to explode every relationship or chance at relationship that he is offered and one is left to contemplate his stubbornness. Should he have stayed in New York among his people? Should he have given in to his adopted culture a little bit? Is he a hero for his refusal to submit to the pull of that adopted culture? Is he as crazy as his father? Read it and decide.

View all my reviews >>

99 bottles of beer

Tuesday, August 4th, 2009

This, believe it or not, is a working PERL program that prints out the lyrics for 99 Bottles of Beer on the Wall
perlBeer3

For comparison, here is another PERL program to do the same thing:


sub b{$n=99-@_-$_||No;"$n bottle"."s"x!!--$n." of beer"};$w=" on the wall";
die map{b."$w,\n".b.",\nTake one down, pass it around,\n".b(0)."$w.\n\n"}0..98

From http://www.99-bottles-of-beer.net/

by the way, here is a version written in a programming language called BrainFuck:
##########################
### 99 Bottles of Beer ###
### coded in Brainfuck ###
### with explanations ###
##########################
#
# This Bottles of Beer program
# was written by Andrew Paczkowski
# Coder Alias: thepacz
# three_halves_plus_one@yahoo.com
#####

> 0 in the zeroth cell
+++++++>++++++++++[<+++++>-] 57 in the first cell or “9″
+++++++>++++++++++[<+++++>-] 57 in second cell or “9″
++++++++++ 10 in third cell
>+++++++++ 9 in fourth cell

##########################################
### create ASCII chars in higher cells ###
##########################################

>>++++++++[<++++>-] ” ”
>++++++++++++++[<+++++++>-] b
+>+++++++++++[<++++++++++>-] o
++>+++++++++++++++++++[<++++++>-] t
++>+++++++++++++++++++[<++++++>-] t
>++++++++++++[<+++++++++>-] l
+>++++++++++[<++++++++++>-] e
+>+++++++++++++++++++[<++++++>-] s
>++++++++[<++++>-] ” ”
+>+++++++++++[<++++++++++>-] o
++>++++++++++[<++++++++++>-] f
>++++++++[<++++>-] ” ”
>++++++++++++++[<+++++++>-] b
+>++++++++++[<++++++++++>-] e
+>++++++++++[<++++++++++>-] e
>+++++++++++++++++++[<++++++>-] r
>++++++++[<++++>-] ” ”
+>+++++++++++[<++++++++++>-] o
>+++++++++++[<++++++++++>-] n
>++++++++[<++++>-] ” ”
++>+++++++++++++++++++[<++++++>-] t
++++>++++++++++[<++++++++++>-] h
+>++++++++++[<++++++++++>-] e
>++++++++[<++++>-] ” ”
++>+++++++++++++[<+++++++++>-] w
+>++++++++++++[<++++++++>-] a
>++++++++++++[<+++++++++>-] l
>++++++++++++[<+++++++++>-] l
>+++++[<++>-] LF
++>+++++++++++++++++++[<++++++>-] t
+>++++++++++++[<++++++++>-] a
+++>+++++++++++++[<++++++++>-] k
+>++++++++++[<++++++++++>-] e
>++++++++[<++++>-] ” ”
+>+++++++++++[<++++++++++>-] o
>+++++++++++[<++++++++++>-] n
+>++++++++++[<++++++++++>-] e
>++++++++[<++++>-] ” ”
>++++++++++[<++++++++++>-] d
+>+++++++++++[<++++++++++>-] o
++>+++++++++++++[<+++++++++>-] w
>+++++++++++[<++++++++++>-] n
>++++++++[<++++>-] ” ”
+>++++++++++++[<++++++++>-] a
>+++++++++++[<++++++++++>-] n
>++++++++++[<++++++++++>-] d
>++++++++[<++++>-] ” ”
++>+++++++++++[<++++++++++>-] p
+>++++++++++++[<++++++++>-] a
+>+++++++++++++++++++[<++++++>-] s
+>+++++++++++++++++++[<++++++>-] s
>++++++++[<++++>-] ” ”
+>+++++++++++++[<++++++++>-] i
++>+++++++++++++++++++[<++++++>-] t
>++++++++[<++++>-] ” ”
+>++++++++++++[<++++++++>-] a
>+++++++++++++++++++[<++++++>-] r
+>+++++++++++[<++++++++++>-] o
>+++++++++++++[<+++++++++>-] u
>+++++++++++[<++++++++++>-] n
>++++++++++[<++++++++++>-] d
>+++++[<++>-] LF
+++++++++++++ CR

[<]>>>> go back to fourth cell

#################################
### initiate the display loop ###
#################################

[ loop
< back to cell 3
[ loop
[>]<< go to last cell and back to LF
.. output 2 newlines
[<]> go to first cell

###################################
#### begin display of characters###
###################################
#
#.>.>>>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>
#X X b o t t l e s o f b e e r
#.>.>.>.>.>.>.>.>.>.>.>.
#o n t h e w a l l N
#[<]> go to first cell
#.>.>>>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>>>>>>>>>>>>>.>
#X X b o t t l e s o f b e e r N
#.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>
#t a k e o n e d o w n a n d p a s s
#.>.>.>.>.>.>.>.>.>.
#i t a r o u n d N
#####

[<]>> go to cell 2
- subtract 1 from cell 2
< go to cell 1

########################
### display last line ##
########################
#
#.>.>>>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>
#X X b o t t l e s o f b e e r
#.>.>.>.>.>.>.>.>.>.>.
#o n t h e w a l l
#####

[<]>>>- go to cell 3/subtract 1
] end loop when cell 3 is 0
++++++++++ add 10 to cell 3
<++++++++++ back to cell 2/add 10
<- back to cell 1/subtract 1
[>]<. go to last line/carriage return
[<]> go to first line

########################
### correct last line ##
########################
#
#.>.>>>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>
#X X b o t t l e s o f b e e r
#.>.>.>.>.>.>.>.>.>.>.
#o n t h e w a l l
#####

[<]>>>>- go to cell 4/subtract 1
] end loop when cell 4 is 0

##############################################################
### By this point verses 99\10 are displayed but to work ###
### with the lower numbered verses in a more readable way ###
### we initiate a new loop for verses 9{CODE} that will not ###
### use the fourth cell at all ###
##############################################################

+ add 1 to cell four (to keep it non\zero)
<-- back to cell 3/subtract 2

[ loop
[>]<< go to last cell and back to LF
.. output 2 newlines
[<]> go to first cell

###################################
#### begin display of characters###
###################################
#
#>.>>>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>
# X b o t t l e s o f b e e r
#.>.>.>.>.>.>.>.>.>.>.>.
#o n t h e w a l l N
#[<]> go to first cell
#>.>>>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>>>>>>>>>>>>>.>
# X b o t t l e s o f b e e r N
#.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>
#t a k e o n e d o w n a n d p a s s
#.>.>.>.>.>.>.>.>.>.
#i t a r o u n d N
#####

[<]>> go to cell 2
- subtract 1 from cell 2

########################
### display last line ##
########################
#
#.>>>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>
#X b o t t l e s o f b e e r
#.>.>.>.>.>.>.>.>.>.>.
#o n t h e w a l l
#####

[<]>>>- go to cell 3/subtract 1
] end loop when cell 3 is 0
+ add 1 to cell 3 to keep it non\zero

[>]<. go to last line/carriage return
[<]> go to first line

########################
### correct last line ##
########################
#
#>.>>>.>.>.>.>.>.>.>>.>.>.>.>.>.>.>.>.>
# X b o t t l e o f b e e r
#.>.>.>.>.>.>.>.>.>.>.<<<<.
#o n t h e w a l l
#####

[>]<< go to last cell and back to LF
.. output 2 newlines
[<]> go to first line

#########################
### the final verse ##
#########################
#
#>.>>>.>.>.>.>.>.>.>>.>.>.>.>.>.>.>.>.>
# X b o t t l e o f b e e r
#.>.>.>.>.>.>.>.>.>.>.>.
#o n t h e w a l l N
#[<]> go to first cell
#>.>>>.>.>.>.>.>.>.>>.>.>.>.>.>.>.>.>>>>>>>>>>>>>.>
# X b o t t l e o f b e e r N
#.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>
#t a k e o n e d o w n a n d p a s s
#.>.>.>.>.>.>.>.>.>.
#i t a r o u n d N
#[>]< go to last line
#<<<.<<.<<<.
# n o
#[<]>>>> go to fourth cell
#>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>.>
# b o t t l e s o f b e e r
#.>.>.>.>.>.>.>.>.>.>.>.
#o n t h e w a l l N
#####fin##

and here is the program written in “Whitespace” (whitespace is all spaces, tabs and linefeeds) you have to highlight it to see anything:

 
 
        
 
                
 
 
 
 
         
 
                 
             
        
                                              
        
                               
        
             
        
                        
        
                               
        
                               
        
                                
        
             
        
                                              
        
                                       
        
             
        
                                 
        
                          
        
                               
        
             
        
                                              
        
                       
        
                                
        
                                
        
                         
        
                 
        
  
                 
             
        
                                              
        
                               
        
             
        
                        
        
                               
        
                               
        
                                
        
                         
        
                 
        
                          
        
                       
        
                                      
        
                               
        
             
        
                                              
        
                                       
        
                               
        
             
        
                         
        
                                              
        
                                              
        
                                       
        
             
        
                       
        
                                       
        
                         
        
             
        
                           
        
                       
        
                                      
        
                                      
        
             
        
                               
        
                                 
        
             
        
                       
        
                                
        
                                              
        
                                       
        
                                       
        
                         
        
                         
        
                 
        
        
                
                 
             
        
                                               
        
                               
        
             
        
                        
        
                               
        
                               
        
                                
        
                                
        
                 
        
                 
        
  
        
 
          
 
        
                 
 
                               
 
                        
 
        
                     
        
                        
        
                                              
        
                                 
        
                                 
        
                                
        
                               
        
                                      
        
  
        
 
                
                       
        
             
        
                        
        
                                              
        
                                 
        
                                 
        
                                
        
                               
        
  
        
 
                
 
 
                                
        
                                              
        
             
        
                                      
        
                                              
        
                                
        
                               
        
             
        
                        
        
                                              
        
                                 
        
                                 
        
                                
        
                               
        
                                      
        
  
        

 

First, a little Kundalini

Sunday, August 2nd, 2009

I went to a Kundalini Yoga class yesterday and I hurt in parts of my body that I didn’t know existed. It definitely invigorated me. I hates the camel pose.

There is a slight controversy with Kundalini Yoga. It used to be secret stuff, but rouge teachers such as Yogi Bhajan have brought the practices to the public.
Discover a huge store of nonsense on Wikipedia about Kundalini yoga and the results of hitting it too hard, Kundalini Syndrome, which is a melange of nervous twitches and creepy affectations.

I guess Kundalini differs from other yoga because of it’s specific breathing methods (Breath of Fire) and some more psychological aspects, which we did not address. My experience of it was to hold a pose that is slightly or massively challenging and then hyperventilate in that pose so that you feel really awesome when it is over and the rest of the day feels easy by comparison.