## Archive for the ‘Uncategorized’ Category

### (An additional note on the new blog)

24Apr08

I’m studying modal logic with the  Konyndyk textbook and (the philosophical aspect) of kripkean semantics with “Naming and necessity”. That should be a factor on deciding whether the new blog goes or not to planet haskell, as the recent drug-oriented material isn’t representative of *everything* I like about the world.

### I shall no longer be blogging here

24Apr08

I’m moving all my blogging activity — I even transported the posts and comments from here — to dayvancowboy.org.   Whether the address at Planet Haskell should be changed is a judgement call on the Planet Haskell admins as the new blog contains vast amounts of nonhaskell material, (there is some maths though), but basically […]

### Is last.fm leaking information to Google?

04Jul07

I use last.fm, which means in effect I’m giving up large ammounts of privacy — the kind of music I listen to — for the sake of social networking (which in the end I don’t use at all) and fun stats. And that’s okay; at least the terms of service assure me that We won’t […]

### This might or might not qualify as a theorem prover

13Jun07

Just been implementing sentential logic as I progress through the textbook. module Main where import Control.Monad data Formula a = Prim a | (Formula a) :+ (Formula a) | (Formula a) :* (Formula a) | (Formula a) :-> (Formula a) | Not (Formula a) deriving Show (<->) :: (Formula a) -> (Formula a) -> (Formula […]

### Magic Caesar autodecipher

13May07

import Char import List charRot r w = let base = (if isUpper w then 65 else 97) in if (isAlpha w) then chr (base + (mod ((ord w) – base +r) 26)) else w strRot r w = map (charRot r) w unRot w = [strRot r w | r<-[1..26]] countString st = [length […]

### Simple linear analysis of the performance of two algorithms.

04May07

I’ve mentioned over and over and over again that I’m not a programmer, but a econometrician. Today we put that to good use. 1. The problem I can think of two ways of producing the list of divisors of a number: divisors x = [ y | y<-[1..x], (gcd x y) == y] fdivisors x […]

### A quick me-too and a suggestion

03Mar07

First of all, let me get this out of my system: Ok, now I have one more reason not to move out from WordPress.com The LaTeX people should, by now, have a simple “web” version of LaTeX that can be easily installed by dropping files in your cgi-bin directory. The vast majority of people with […]

### A slightly better function-DOT dsl

24Feb07

In some of the graphs in Bycicling for Collatz (the divisibility graph with lots of arrows and the collatz one with 1, 2 and 4 highlighted) we manipulated the Haskell-generated graph either in the DOT file source or directly in the Graphviz GUI. The structure itself was somewhat confusing, too; the Dot class never managed […]

### Bicycling for Collatz

22Feb07

Q: How many people with ADD does it take to change a lightbulb? A: HEY! Let’s ride bikes! module Bikes where Graphviz is fun. Graphviz is fair. You may already have one. You may already be there: data Arr a = a :-> a Graphviz plots graphs from .DOT files consisting of remarkably simple syntax: […]

19Feb07

[] is really the gee-whiz monad. Haskell code that prints *all the five-number combinations of integers in [-5..5]: mapM (\x->[x+i | i<-[-5..5]]) [1..5] No, really, try it. This has to qualify as the “most surprisingly long output” line of code in all of computer programming.

• ## Dr. Syntaxfree

Dr. Syntaxfree has no PhD and shouldn't call himself a "doctor", but does so for amusement value anyway. An unemployed (ok, graduate student) econopundit by day, he's been progressively obsessed about Haskell to the point he often can't fathom not working on it. A jack-of-many-trades, he has an unusual CS background in that he knows no imperative programming at all, he hopes to be both helpful to those less knowledgeable than him and illustrative to the really smart people trying to understand the mentality of a common man trying to tackle functional programming.