Caveat: The Algorithms of Beleriand

I spent Sunday doing two very nerdy but utterly unrelated things. 

I was reading The Children of Hurin. The author on the book is JRR Tolkien, but I rather suspect whatever he left behind was pretty fragmentary, and I think it would be more realistic to assume this is mostly the work of his son and editor, Christopher Tolkien. Not that that takes away from it – as always, I like these "obscure" bits of Tolkien much better than the famous ones. 

And I wrote a computer program in python. Python is a programming language. The program I wrote takes a text file of data points that form a polygon, and "simplifies" the polygon line (reduces the number of points in the line without sacrificing the shape). It's computational geometry, such as is done in graphics programming or, more to the point, GIS (geographic information systems – the tools that we use to present maps online).

It's really the sort of exercise one might do in an Intro to Computer Science course, except that I stole the actual algorithm off the internet, rather than doing the heavy lifting on that front. Mostly I had to familiarize myself with the syntactic features of python, which I've never used before. 

Why did I do this? Um… maybe I'll figure that out later.

[daily log: running, 6 nm]

Back to Top