Monday, December 8, 2008

Arbitrary Precision

I think it'd be cool to implement arbitrary precision trigonometric functions using lazily evaluated Taylor series. (Is this how they're done?) Pretty bad performance, but at least you have a reliable algorithm.

I've also always wondered how TI calculators know that sin(pi) = 0. No floating-point calculation I've seen in a general-purpose programming language can figure it out.

Sunday, November 23, 2008

Stupid Type Erasure

I want to create a freaking generic array, dang it!

public T[] makeArray(int size)
return new T[size]; // compiler error. why? because Java sucks

Sunday, August 17, 2008

Yeah I know it's a stupid title.

And anyway, to be more true to the procedural paradigm it should be something like this:

Public Overrides Function ResultOf(ByVal a As Activities) as Moods
If a = Activities.Programming Then Return Moods.Happy Else Return Moods.Meh
End Function

Yeah it's Yes I'm trying to say that I like programming.