Author Archives: Mirkules

Marine Snails, Politics, and Artificial Intelligence

According to Konrad Lorenz, marine snails waive their long breathing tubes from side to side in search of food — or, more specifically, in search of scent of food — as they move randomly across the ocean floor. Since they are sensitive to the differences in the strength of a scent at the two extremes of the breathing tube’s motion, the scent of food is strongest when the snails are turned at right angles to the food. But instead of turning at right angles towards the food, they make a sharp reversal (almost a 180-degree turn) and continue crawling so that the scent strikes the other receptor, resulting in a zig-zag path that takes them towards the food.

Drawing from this analogy, public opinion and government policy are very much like the marine snail — in the presence of an external stimulus, they sharply reverse direction. For example, after British police found explosive materials in a water bottled on a US-bound flight, any and all liquids were banned on airplanes (even the ones bought in the shops). In this case, the explosives were the stimuli for public opinion and government policy, and the reversal of direction was the transition from utter obliviousness to complete prohibition. Of course, the system reached equilibrium after some time, and the snail is not hungry anymore.

The marine snails were an analogy for an artificial intelligence algorithm in a seemingly randomly-organized book, Swarm Intelligence by Kennedy and Eberhart. The book converges on the ideas of multiple agent interaction from a range of topics, including mathematics, biology, psychology, history and evolution. Even though I am only 1/4 of the way through the book, I find it a fascinating read, and recommend it to anyone even remotely interested in the field. After all, even if you don’t make any progress in AI as a result of this book, you will surely be able to draw random analogies to random occurrences in the world.

A few updates

With the new year come a lot of new responsibilities. I am starting school again (yikes!) while work is probably going to pick up even more.

Last quarter was fierce because of our end-of-quarter and end-of-year financials — they made a push for everything on the production floor to get shipped, so we slaved for a long, long time after hours, burned through our weekends, neglected our families right before christmas just so Bill Lumbergh’s stock would go up a quarter of a point. We didn’t even get a pat on the back (well, at least I didn’t). This year is shaping up to be even more aggressive.

I need to make this server publicly accessible, but I simply don’t have the bandwidth to do it. If I had a few more readers, it would become more worthwhile to update this site more frequently, but, alas, until I get a better server, I am writing just for family and close friends.
Check out some of the new pictures.

MazdaSpeed Challenge

Last weekend, Ky and I went to the MazdaSpeed challenge, where, much like the Lexus Taste of Luxury, officials let you drive select cars around cone-designated tracks. However, Lexus and Mazda cater to different demographics — Lexus to the rich, middle-to-upper class, and Mazda to a younger low-to-middle class.

To my surprise, Mazda encouraged “controlled” driving — meaning a little drift here and there, rubber-chewing turns, or even turning the traction control off was definitely allowed. Uncontrolled driving was demonstrated by idiots with more horsepower than brains, who generally wound up facing the wrong way after a nasty hairpin, and was discouraged to the point of disallowing those people to drive again.

The cars constituted pretty much the entire Mazda lineup: MazdaSpeed6, Mazda6, Mazda3, MX-5 (Miata), CX-7, RX-8, and the occasional Mazda5. Different types of tracks were designated to different types of vehicles and their strengths and abilities. MazdaSpeed6 and Mazda6 had a timed autocross track, CX-7 had a “target hunt”, RX-8 and MX-5 had a trial course, and the rest had a mild “Time Match” course.

MazdaSpeed6

We tested the Autocross waters with the MazdaSpeed 6, which is only available with manual transmission. The car has a 274-horsepower, Inline 4-cylinder, 2.3-liter, turbocharged engine. Traction is achieved through an All Wheel Drive system that does not impress, especially not under extreme driving circumstances — but I’m getting a little ahead of myself. The interior is everything I expect from a Mazda, and very similar to the Mazda3, which is neither good nor bad, but average.
Unlike the Mazda3, however, the clutch was extremely sensitive and had a very short depth, causing me to (embarrassingly) bunny-hop the car for the first two times I eased off the clutch. Rolling through the start gate, I couldn’t help but notice the underwhelming low-end power, undoubtedly caused by turbo lag. Fortunately, once the turbo spooled up (somewhere after the 3,500 rpm mark, I think), the car produced gobs of power on demand, complete with the distant and distinct sound of an unmodified turbo “whoosh” in the background.

Going around the first bend, it became apparent that this was a mid-size sedan. The amount of body-roll the car produced in the right-hander was almost equivalent to that of my (late) ’99 Wolfsburg Jetta — which, if you know the car, is just short of the car being propped up on two wheels. Ok, so I exaggerated a little, but the fact remains: the MazdaSpeed6 could definitely use a stiffer suspension and some anti-roll bars. Understeer was also definitely noticeable due to the car’s AWD and the traction control (you’re probably thinking I should have turned it off, but I only had 2 laps in it, and didn’t want to lose control and my driving privileges). To be fair, these are racing conditions, but even then a car that bills itself as the sport-sedan in the sub-$30K range should definitely sport better handling.

The brakes, on the other hand, had decent response and never faded. It’s also worth noting that by the end of the day (we did the first run in the morning, and the second run in the afternoon), the clutch was worn out to the point of gripping really high up — a sign of a) torture exhibited upon the car by the masses of people gathered to practice the “drive-it-like-you-stole-it” methodology, and b) a sportier clutch, sacrificing durability for performance — which, for this car, is fine by me.

All in all, I am not overly impressed by this car. It seems like the Mazda engineers wanted to create a sport version of the Mazda6 sedan for the parent on-the-go, but had to stop short in order to meet the budget, unfortunately sacrificing suspension (the most crucial part, in my book). I am interested in how the MazdaSpeed6 compares to the MazdaSpeed3 and a Subaru STi on an autocross track.

Rating: 6 out of 10.
Pictures and more review to come. Stay tuned.

SAMBA Server and Ubuntu

Install SAMBA Server on Ubuntu Server with the following command:

sudo apt-get install samba smbfs

Next, we need to set up the share in /etc/samba/smb.conf:

[global]
hosts allow 192.168.0 #allows everyone in my house to access all the shares

[share]
comment = My Test Share
writeable = no
locking = no
path = /share/
public = yes

Next we need to add smb users, which are already existing users on the linux box:

sudo adduser joe
sudo smbpasswd joe

Finally, (re)start the server:

sudo /etc/init.d/samba start|restart

CVS and Ubuntu (and some WordPress weirdness)

Managing users/groups for CVS. Here’s how to allow user joe to modify code in a CVS directory. Depending on how your permissions were set up, the following commands may or may not have to be run with sudo.

First, we need to create a group dev that will eventually have rw access to the CVS directory:

groupadd dev

Then, we need to add user joe to the dev group:

usermod -G dev -a joe

The -G flag adds joe to the dev group, while the -a flag assures that joe retains his original group as well. Without the -a flag, joe would only be a member of dev, erasing his previous group.

Then, change the group ownership of the target directory, in our case /cvs/test/:

chgrp -R dev /cvs/test/

Finally, add group rwx permissions for the dev group:

c hmod 774 -R /cvs/test/

Note: Apparently, WordPress does not allow me to publish the word “ch”+”mod” as one word. A page comes up with “An appropriate representation of the requested resource /wp-admin/post.php could not be found on this server.” and of course all my work is gone.

In any case, in the last line above, the “c” and the “hmod” should be one word.