29 June 2012


I'm back in the tri-state area for the summer. While it's unfortunate that none of my MIT buddies are remotely close to me, I figured these three months alone were sorely needed to get stuff done.

Or not.

It's too bad that I have more or less only two hours of down time at home every weeknight; transportation is significantly nontrivial compared to last year; I lived half a mile away from the Infinite Loop. Transportation is especially horrendous when the weather is ungodly humid or when the bus is late.

I also miss the shenanigans I'd partake with my MIT buddies. My internship friends are the kind who wouldn't want to be caught dead in a McDonald's, never mind play the Triangular Burger game, in which a group of people line up and, starting with ordering three cheeseburgers, order one more cheeseburger than the person in front. *cough* #richpeople. After two months without McDonald's, I got a little nostalgic for my favorite infant-hood food:

Tower of Hamburger!

For the record, the cheeseburgers from 56th and 8th in NY are considerably drier than the ones from Central Square in Cambridge. They're also 20% more expensive, to my dismay.

On the bright side, work has been pretty fun. My boss has a 5ft remote-controlled flying shark! After only a week I've learned how to drive it really well. I am really tempted to glue an Arduino onto it and make it do something silly, like 8-bit music.

And then of course there are the NYC zoos, which are quite picturesque. I've only been to the Bronx Zoo so far; I'm hoping to go to the other four and practice my photography.

I've also seen some exotics around the city, namely a Mercedes SLS AMG, a Rolls-Royce Phantom, and a Maybach 62S. There's also a ton of fullsize luxury sedans; Audi A8, Mercedes S-class, Lexus LS, and BMW 7 series. It's too bad that one cannot take advantage of the potential of these cars while crawling through streets cluttered by yellow cabs and people.

Now excuse me as I hide from the humidity.

28 June 2012

[NT] Learning and Life: a late mid, er, end-semester update

I haven't blogged about non-technical subjects in some time; in fact, readers have told me they couldn't understand what I was talking about in my previous few posts.

Classes have been going fine, well, not quite. I finally discovered my tolerance for code when I had four coding assignments (read: projects) due in a span of 27 hours. As much as I worked on them over spring break, I hit my breaking point come that period, so I ended up dropping a class. Luckily, it was only an elective.

6.005 Elements of Software Construction: On the surface, this is a relatively easy class for anyone with experience, except when you need to deal with the staff because a miscommunication resulted in automated testing disasters.

6.115 Microcomputer Laboratory (dropped): I walked in confident in my assembly skills, but as time went on, I got incredibly sick of writing assembly code. Who wouldn't? In addition, I found the labs to be incredibly contrived and boring. Luckily, I stayed in the class long enough to have learned a sufficient amount of EE approaches and skills for me to tackle decently nontrivial side projects.

6.815 Computational Photography: This class is incredible! You make sense of photography using mathematics and Fredo is an awesome professor :-) Sadly, my motivation for going to class is so that I can drool over his backpack of Canon L-lenses (read: expensive) since the assignments aren't too hard and lecture notes are posted. I really enjoyed the class because it isn't just pure coding; I had to work out the math of the algorithm to be implemented before I coded it up, which alleviates some of the pure-coding-related boredom.

18.06 Linear Algebra: This class solidified my fuzzy understanding of applied linear algebra. It was useful for understanding the algorithms in 6.815.

21W.789 Communicating with Mobile Technology: This HASS class is actually a programming class in disguise. Mobile apps aren't my forté, but it's still interesting to play with them, especially if you get credit for doing so :-) It's a three hour class that runs once a week in the evenings, but usually only runs for two hours.

The workload (erm, codeload?) about 600 lines of code a week (including 6.115; taking that out reduces it to approx 400), just for classes, sometimes more. Sometimes I feel that coding is dreadful.

At one point in the semester, I felt that I was losing focus -- especially in side projects, and thus getting extremely annoyed at myself. I think I had six or seven things I wanted to do, which is quite impossible given my time-constrained schedule. Thinking back to Steve Jobs' words:

Focus is about saying no.

I pared down that list to something more reasonable and stuck to it. I'm nearly done with the CAD of my scooter and the assembly of my scooter's hub motor. I am looking forward to finishing it before I leave campus. :-) Sadly, both NJ and NY outlaw electric vehicles (or registration of such vehicles is incredibly convoluted).

Another thing that's been really holding down my productivity was constantly worrying about my grades. Don't get me wrong; I realize grades are important, but recruiters only care so much, i.e. that you're not a miserable failure. In other words, think of it as a high-pass filter, with qualification on the y-axis and GPA on the x-axis. Once you hit a certain threshold, you're more or less fine in that respect.

After this term, I'll be halfway done with college. Incredible, isn't it? There's only two more years left! Goals (in roughly order of importance):
  1. Acquire diploma
  2. Finish my scooter
  3. Build KawaiiKart
  4. Attend motorsports driving school (sadly, this is starting to seem unlikely)
And then afterwards, I hope to obtain a Porsche 911 Porsche Boxter (and then maybe a 911), the dream car I've always wanted as a kid. (Speaking of which, I've driven a 997 GTS, albeit for half a mile). But first, I need to learn how to drive a stick in order to appreciate operate the Porsche.

To those who have not experienced driving: there's a magical feeling when you're behind the 911 (or any comparable sports car). You have an immense amount of tactile feedback from the road from the steering. It's weighted quite a bit more than your average car, so it's easier to select a turning angle without overshooting. Then there's the engine, which is tuned to make a sweet roar while accelerating without accompanying white noise, but nearly nothing while idle. Here's a more concrete example:

It's also a shame that I'll be leaving so quickly, as I don't plan on staying in the greater Boston area or the east coast. I never had a constant home, a constant set of friends, or similar. Prior to coming to MIT, I've lived in six places. When I graduate and begin anew, I'll have lived on average 3.14 years per place, whereas many of my friends have just grown up in one area. I've grown accustomed to ever-changing aspects, such as meeting new friends, exploring new areas, and going through hardware relatively frequently, for better or for worse.

However, the one constant has been the venerated Hamburger, who has been by my side for eleven trusty years. He's traveled over 50,000 miles (I kid you not -- China and even the west coast are far away!) in planes, boats, trains, and of course cars.

17 June 2012

[Partially Resolved] Vim Segfaulting

So it turns out that files in OS X Lion that have extended attributes will cause vim to segfault every now and then. To determine whether a file has extended attributes, do an ls -l and see whether an '@' is next to the permissions. Now to figure out how to remove these pesky attributes…

10 June 2012

PhotoNotes: Bronx Zoo

Today was the first time I've been to the zoo since when I was a kid, probably. (I may have gone to a petting zoo in the last seven years, but that's beside the point.) Besides reliving my childhood memories, going to the zoo was a serious test drive of some sweet gear in preparation for my journey to Alaska at the end of this summer.

Tax returns well spent.

  • A gripped DSLR around your neck with a (white) telephoto lens will get lots of looks and comments of awe.
  • At the risk of sounding like a jerk, having a telephoto is really convenient for crowd-pushing; you stick your lens between people's heads and they will move out of the way.
  • On the same note, sticking your lens at an open exhibit will cause birds to attempt to land on it, thinking it's a twig.
  • Walking around for 4+ hours with six pounds of camera around your neck is really tiring. My hands were aching at the end of the trip trying to hold onto the camera.
  • The 70-300L on a 1.3x body was superb for outdoors and bird exhibits. The 50L was a beast for low-light exhibits, such as the reptile house.

I nabbed this cute little dude with the 50L @ 2.0.

Less cute, but the V formed by the branches makes for an interesting shot.

Obligatory tiger shot.

Bird. The turquoise/teal palette came out quite nice. (cleaned up in postproduction)

Nonwatermarked originals at full resolution are available at request.

05 June 2012

C++ Don'ts, Part I

Hello! Today we will be talking about things not to do in C++! Today's topic will be linked lists, more specifically integer linked lists.

We can define a non-null node as follows:

template<int I_, typename T_>
struct Node {
    static const int value = I_;
    static const int size = 1 + Next::size;
    typedef T_ Next;

and the null node as follows:

struct End {
    static const int size = 0;

We then can implement getting the size of a linked list:

template<typename L_>
struct Size {
    static const int value = L_::size;

where L_ is either a Node or an End.

Recursive prints can be done as follows using specialization:

template<typename L_>
struct Print;

template<int I_, typename T_>
struct Print<Node<I_, T_> > {
    static void print() {
        std::cout << I_ << "\n";

struct Print {
    static void print() {}

See where this is going? Now go implement map, filter, and reduce. :)

03 June 2012

Start of Something New

I've always wanted a go-kart since sixth or seventh grade. Fortunately, after years of hard work and meeting the right people (hi Charles and Shane!), I have the skills and support to build one of these. The target goals are as follows:
  • Weigh less than 25kg
  • Top speed of >30mph
It's going to be an AWD hybrid. The rear wheel will be driven by a Honda GX35 and the front wheels will be driven by two custom hubmotors and controlled by a custom motor controller.

This build will be largely based off the Democratic People's Republic of Chibikart and its older brother Chibikart, whose comprehensive build instructions are here. It will be an exercise of implementing a small asymmetric hybrid (similar to the Lexus RX hybrid with AWD).

And yes, the title is a High School Musical reference.