The Journalist-Industrial Complex

Posted August 7, 2008 by Brandon Zylstra
Categories: Uncategorized

In another post I made mention of the “Journalist-Industrial Complex”. Okay, so I was saying that with my tongue in my cheek. There is, however, at least one review of the world of journalism that you should take seriously: How the News Makes Us Dumb: The Death of Wisdom in an Information Society

Advertisements

Is Open Source Communist?

Posted August 7, 2008 by Brandon Zylstra
Categories: Uncategorized

So the Redmond PR machine has convinced many people that

open source software = communism
proprietary software = capitalism

but this could not, from all the facts I can see, be further from the truth.

Let’s review some of the characteristics of communism, as compared to some characteristics of capitalism, and decide which one is closer to the Redmond approach and which is closer to the open source movement.

Communism requires central control, with one all-powerful dictator.

While there may be some distribution of control at Microsoft (and probably more so now that Gates has retired), I don’t think any Microsoft developers are going to decide on their own to fork Windows and see what happens. There is very much a top-down hierarchy in place, and people do what they’re told.

And while Linus Torvalds has final say on what becomes a part of the official Linux kernel, he’s not deciding how all the Linux developers in the world spend their time. They have complete freedom to do anything they want, and it may or may not bear fruit. That sounds a lot like capitalism: I can try anything, and it may or may not sell on the open market. Linus just happens to be a big customer, but there’s nothing stopping someone from forking the Linux kernel and making their own. They wouldn’t be able to call it Linux, but they’re free to make what they want. Linus has freedom to decide what is called “Linux”, and they have freedom to take Linux and make something new with it. Freedom! Doesn’t that sound like capitalism, not communism!?

Communism makes a few very very rich, and the rest very very poor

If you “got in early” to Microsoft, you could be retired now and living on your own cruise ship. Just like those involved in planning the revolution in Russia or China (or wherever).

In Communism power is seized through force

Communist dictators were obviously not voted into office. (Although by deluding the public with visions of great improvements to their lives that were never delivered on, they did gain a lot of popular support.) Looking at a history of Microsoft you’ll see that they lie cheat and steal their way to success. They steal innovations from other companies and bring them to market more forcefully. This leads to the next point.

There is very little innovation under a Communist regime

Very little original work comes from Redmond nothing that I can think of, and I’ve been looking for something original from them for years. When I thought I found something that they originated the task bar I discovered it was a combination of the dock from NeXT and the menu bar from the original Mac OS. (Drag the Windows task bar to the top of the screen, then compare with an old Mac running OS 9, and you’ll see what I mean. Anything not stolen from the Mac OS was stolen from NeXT.)

Communism depends on propaganda

No one that I know of has a better PR machine than Microsoft.

So there is this one similarity that Redmond (et al) are (no pun intended) capitalizing on: capitalism allows people to earn money for their work, and so does proprietary software. However, this similarity is tangential at best.

Are people compelled in a capitalistic society to work only for money? No, of course not that would be absurd. How many volunteer movements do you think started in the Soviet Union? How many do you think started in the United States?

Does open source software prevent people from making money for their work? No, not really. It might prevent them from making money from the software, since it is usually largely the work of others, but there are many very successful open source software businesses, making bundles of money from support. Open source software in no way whatsoever precludes making money, it just prevents you (in many cases) from making money from someone else’s software. Under the Gnu Public License, if you modify (improve) someone else’s open source software, you can’t turn around and sell it your improvements must be given away freely as well. But the MIT license is growing in popularity, and it does not preclude selling the software you build using code you nabbed from someone or some where else. So not only does open source software in no way preclude making money, in some cases it doesn’t even limit how you make money.

How to use Ruby in TextMate Snippets and Commands

Posted July 25, 2008 by Brandon Zylstra
Categories: Ruby

Tags: , ,

Dr. Nic, one of our favorite Aussies (along with Ray Ozzy), posted a screencast on how to create TextMate snippets with Ruby embedded in them, as well as how to create commands with Ruby. Here’re the Cliff’s Notes versions of a snippet and command that will guess the class name you want to use based on the file name:

Snippet with Ruby

class ${1:`#!/usr/bin/env ruby
require 'rubygems'
require 'active_support'
puts ENV['TM_FILENAME'].gsub(/\.rb$/, '').camelize
`}
$0
end

Command with Ruby

#!/usr/bin/env ruby
require 'rubygems'
require "active_support"
puts <<-EOS
class ${1:#{ENV['TM_FILENAME'].gsub(/\.rb$/, '').camelize}}
$0
end
EOS

He mapped these to “cla” in the bundle editor, but I recommend avoiding abbreviations. You’ll spend more time trying to remember how you abbreviated something than you’ll save by not typing two lousy characters.

The screencast’s volume is really low, so you’ll need to plug those external speakers into your laptop and crank the volume to what would normally be deafening levels just to hear him. The little tinny speakers on your MacBook won’t cut it this time.

Intuition in problem solving, and how that may relate to superstitions

Posted May 22, 2008 by Brandon Zylstra
Categories: Uncategorized

Matthew Bass wrote about how a hunch led to solving an unexplained problem with git. I’ve had many similar experiences, so I commented on his blog post

It’s surprising how often those hunches are right, and interesting how much we programmers do based on hunches when all else fails. Sometimes intuition comes through where careful logic falls short.

As something of a tangent, I’ve noticed that a lot of people (not so much programmers but common users) talk about computers and computer problems as though they were superstitious. They don’t understand how computers *really* work, but they sometimes have intuitions that help them solve problems. (Not to imply that we always understand everything that’s going on, but it’s easiest to see in people with less sophistication.) It’s sometimes easiest to understand the behavior of Windows, for instance, if you just assume that it is possessed.

I suspect this is where many superstitions arise: in a given group of people no one can explain a certain problem or how to solve it in a careful detailed logical way, but someone (on a hunch, often) comes up with a solution. Someone then, of course, comes up with an explanation for why that solution worked. If you’re a member of a stone-age tribe in Papua New Guinea then you might attribute everything to spirits.

On the other hand, if you’re a member of a post-spiritual modernist western culture, then you might attribute everything to physics or psychology, depending on the phenomena in question. Freud tried to explain away faith in the supernatural with psychological explanations, saying that people “project” their desires for security and create in their minds a Supreme Being. Paul Vitz has shown that the converse of Freud’s theory is far more defensible based on the data: disappointment with one’s father often leads to atheism. Those with good fathers (and therefore far less likely to be motivated by desire for a security that they lack) were more likely to believe in a Supreme Being:

Starting with Freud’s “projection theory” of religion-that belief in God is merely a product of man’s desire for security-Professor Vitz argues that psychoanalysis actually provides a more satisfying explanation for atheism. Disappointment in one’s earthly father, whether through death, absence, or mistreatment, frequently leads to a rejection of God. A biographical survey of influential atheists of the past four centuries shows that this “defective father hypothesis” provides a consistent explanation of the “intense atheism” of these thinkers. A survey of the leading intellectual defenders of Christianity over the same period confirms the hypothesis, finding few defective fathers. Professor Vitz concludes with an intriguing comparison of male and female atheists and a consideration of other psychological factors that can contribute to atheism.
Professor Vitz does not argue that atheism is psychologically determined. Each man, whatever his experiences, ultimately chooses to accept God or reject him. Yet the cavalier attribution of religious faith to irrational, psychological needs is so prevalent that an exposition of the psychological factors predisposing one to atheism is necessary.

And of course there’s the idea (held by such luminaries as Francis Crick and apparently Richard Dawkins) that life on earth came about because it was brought here by Aliens. Of course this avoids answering the question of how life came about, just sweeping it under an inter-galactic rug. Nonetheless, an appeal to an explanation couched in (astro)physical terms, because those are the only explanations some people think are allowed.

(To think I came here from git!)

Add Journalists to the List of Things Unreliable

Posted May 15, 2008 by Brandon Zylstra
Categories: Random Nonsense, Technology

Tags: , , , , , ,

Apparently a reference was made to an iPhone-like tablet as the sort of device that could benefit from Intel’s new CPUs, and ZDNet took this as a claim that such a thing existed. Read about it at http://www.appleinsider.com/articles/08/05/15/intel_apple_tablet_comment_simply_untrue.html.

Computers can’t even do math!?

Posted May 15, 2008 by Brandon Zylstra
Categories: Ruby, Software, Technology

Tags: , ,

Since the whole world by now should be aware of the general failure of artificial intelligence, it shouldn’t be very controversial to say that I’ve (mostly) always realized that computers can’t do many things that are very easy for people to do. Forget anything like thinking: the most basic identification of black shapes on a page as alphanumeric characters sometimes fails, and facial recognition seems to be a long way from being anywhere close to reliable.

But reading David Flanagan’s fabulous book “The Ruby Programming Language”, I discovered that computers can’t be trusted to do simple math either. Here’s the direct quote, followed by my simplified explanation.

Binary Floating-Point and Rounding Errors

Most computer hardware and most computer languages (including Ruby) approximate real numbers using a floating-point representation like Ruby’s Float class. For hardware efficiency, most floating-point representations are binary representations, which can exactly represent fractions like 1/2, 1/4, and 1/1024. Unfortunately, the fractions we use most commonly (especially when performing financial calculations) are 1/10, 1/100, 1/1000, and so on. Binary floating-point representations cannot exactly represent numbers as simple as 0.1.

Float objects have plenty of precision and can approximate 0.1 very well, but the fact that this number cannot be represented exactly leads to problems. Consider the following simple Ruby expression:

0.4 - 0.3 == 0.1 # Evaluates to false in most implementations

Because of rounding error, the difference between the approximations of 0.4 and 0.3 is not quite the same as the approximation of 0.1. This problem is not specific to Ruby: C, Java, JavaScript, and all languages that use IEEE-754 floating-point numbers suffer from it as well.

One solution to this problem is to use a decimal representation of real numbers rather than a binary representation. The BigDecimal class from Ruby’s standard library is one such representation. Arithmetic on BigDecimal objects is many times slower than arithmetic on Float values. It is fast enough for typical financial calculations, but not for scientific number crunching. Section 9.3.3 includes a short example of the use of the BigDecimal library.

So, in other words, if you ask what 0.4 – 0.3 is, you get the correct answer. But if you ask if 0.4 – 0.3 is equal to 0.1, you’re told that it’s not the same. And please remember: although Ruby is used in the example, this is not a bug in Ruby, but a generally accepted way for programming languages to work, which has been adopted by the international standards body IEEE.

Add to this the fact that different programming languages disagree what the remainder is when you divide a negative number by a postive number, and you’ll learn that you have to be very careful what you let computers do for you. They could even mess up the one thing that seems perfectly suited to them: basic math.

Parents have no idea what goes on in schools

Posted April 10, 2008 by Brandon Zylstra
Categories: Uncategorized

This sort of thing is only going to become more common. Actually, this general sort of thing—kids being cruel, even extremely so—has been going on for as long as anyone who pays attention can remember. All the people who are shocked by this are just showing that they’ve had their heads in the sand for years. It’s time to realize what’s going on and pull your kids out of school, or avoid putting them in in the first place.