Pretty much the most interesting blog on the Internet.— Prof. Steven Landsburg

Once you get past the title, and the subtitle, and the equations, and the foreign quotes, and the computer code, and the various hapax legomena, a solid 50% English content!—The Proprietor

Showing posts with label Haskell. Show all posts
Showing posts with label Haskell. Show all posts

Friday, October 16, 2015

Beta Rabbit vs. Doctor Boolean: or; How to Be Recruited by Google

Peter Rabbit

A few days ago, something remarkable occurred when the author performed a Google search on a technical subject. Suddenly the search results folded away to reveal something like a UN*X command line console. What was this?

Monday, October 12, 2015

Gleichschaltung at Haskell

lamdbdika

Recently a semi-prominent Haskeller, some of whose work the author has in the past enjoyed, has unfurled his personal flag. It consists out of \(\lambda\), the traditional ensign of theoretical computer science (of the practitioners of which Haskell has in recent years been a favorite plaything) and the flag of one of the twentieth century’s great genocidal totalitarianisms, similar to the title image here.No, of course not that one. The other one.

A lot of talk has grown in the programming scene about 'keeping politics out of code' so I decided instead to create a banner for those who feel rather more otherwise.

I believe in a programming community that is aware and conscious of its place within the greater society, and acts with conscience and considerations of the consequences of its actions, rather than one that hides in an imaginary apolitical space oblivious to the effects its creations wreak upon civilization.

I also believe in the ideals of equality of opportunity, regardless of race, gender, sexual orientation, or economic class, and that the needs of all members of society should be met, rather than only those of a wealthy and privileged elite and those who can claw their way into its good graces.

This saddened the author on several levels. For one it means that the author and that Haskeller will likely never be able to collaborate on anything Haskell related. Even if the author could, as he hopes he can, banish his revulsion at the Haskeller’s political views long enough, this Haskeller must consider this author’s views equally contemptible and makes it clear that such suppression of politics is not only not desirable, but would constitute an unacceptable act of ideological treason.

More importantly it means that an effort at ideological Gleichschaltung is underway in yet another field of thought. Even if this Haskeller does not succeed, another one very well might. And when they do, people like the author (or any other views different from that of this Haskeller) will no longer be welcome there.

Saturday, September 19, 2015

The Idea of My Year: Curry-Howard Correspondence

Curry-Howard Correspondence

Edited on September 20, 2015 to add footnote 4.

Curry-Howard Correspondence was first published in 1969, before the author was born, but the author only learned of it in the present year. That alone is enough to induce a desire to go back to everybody one has ever encountered, starting with one's mother and father, grab and shake them, and cry You knew I lived, breathed, thought! Yet, you allowed me to remain in ignorance that such beauty and cleverness existed. How could you have been so cruel and thoughtless? Regardless, it is the idea of the author's year. To rescue the reader from the purgatory that ignorance of Curry-Howard Correspondence is, let one make an inexpert attempt to explain it here.

Monday, August 31, 2015

A Coda on the Periods Function

A recent post discussed the problem of a periods functions which, when given a potentially infinite list, will reliably determine whether that infinite list is periodic and, if so, with which parameters. It was claimed that a general strong periods function, which always works, is impossible because it would imply a solution to the unsolvable halting problem. Instead, a weaker, but still useful, periods function was offered that produces useful output, but does not terminate on infinite lists.

Wednesday, August 26, 2015

Testing Periodicity in Haskell

If you are dealing with infinite, but potentially periodic, series, you may sometimes have wished there was a function, let's call it periods, that could be given such a series and tell you whether it is periodic and, if so, the length and starting point of the period.

Sadly, such a function is impossible. There is no way for the function to determine whether any apparent period is genuine or there is a break at the \(n\)th element without looking at every single element. And checking every single element of an infinite series obviously cannot be done in finite time.

Tuesday, August 18, 2015

Tribonacci Function: Exercise in Elementary Haskell Optimization No. 2

This is the second entry in an intermittent series of posts on how to optimize some basic mathematical functions in Haskell. The previous entry is here.

Consider the following problem: A person is ascending a staircase with \(n\) steps. The ascendant is sufficiently tall and the steps sufficiently shallow that with each gait, the ascendant can take one, two, or three steps. How many different ways are there for the ascendant to reach the top?