Sometimes it’s all too much…

code 23 June 2009 | 0 Comments

Argh #include <stdio.h> #include <math.h> #include <fenv.h>   int main () { // don’t set rounding here double ten0 = sin(pow(10.0,22));   fesetround(FE_DOWNWARD); double ten1 = sin(pow(10.0,22));   fesetround(FE_UPWARD); double ten2 = sin(pow(10.0,22));   fesetround(FE_TONEAREST); double ten3 = sin(pow(10.0,22));   fesetround(FE_TOWARDZERO); double ten4 = sin(pow(10.0,22));   printf( "Default: %f\n" "Downward: %f\n" "Upward: %f\n" "ToNearest: %f\n" [...]

Tagged in , , , , ,

Symbols used to represent functions

utility 22 June 2009 | 0 Comments

I was looking for some standard symbols to represent the Control key and the Alt key, and couldn’t find one until I came across ISO/IEC 9995-7. Because I had much trouble finding a free copy of the document on the ’Net, I have made a table of the symbols and their functions below. I have [...]

Tagged in , , , , , ,

Pearls Before Piglets

tips 27 May 2009 | 0 Comments

While Googling my way through the interwebs, I came across the 2008 Western Australian Certificate of Education sample examination for Stage 2 Biological Sciences. It contains this diagram: If you’re wondering, the entire hierarchy is drawn from Umberto Eco‘s novel Baudolino.

Tagged in , , , ,

What can we fit in 140 characters?

code 27 May 2009 | 0 Comments

This is in reference to the current ‘Twitter image encoding challenge’ running on StackOverflow. If we want to restrict ourselves to assigned, non-control, non-private Unicode characters, then by my reckoning that gives us 129,775 available characters. wget http://unicode.org/Public/UNIDATA/UnicodeData.txt awk -F ‘;’ UnicodeData.txt -f countUnichars.awk | bc countUnichars.awk source: BEGIN { print "ibase=16" } # set [...]

Tagged in , , , , , ,