The iPhone App

App

You may recall that I was slightly busy from shortly before Will was born until early October. Well, my big project was finally released yesterday. The Wolfram|Alpha iPhone application is now available in the iTunes app store.

The app has generated quite a lot of buzz over the past 24 hours, mostly because the price is significantly greater than the vast majority of iPhone applications. While I was intimately involved in the development of the application, I am completely in the dark about the business and marketing side of the product. On the bright side, most of the reviews speak relatively highly of the app itself, even though many are quite critical of the price.

Since I work primarily on Mathematica, I’ve been fairly uninvolved with the Wolfram|Alpha project prior to this iPhone app. I’m still not an expert on innards of Wolfram|Alpha but I do understand the big picture a little better than I did before.

1.0.0

If you’ve never used Wolfram|Alpha before, go ahead and give it a try on the website. It’s kind of hard to describe what it does, simply because it’s not like any other application you’ve ever used before. Despite certain visual similarities to web search engines like Google or Yahoo, Wolfram|Alpha is not a search engine. It doesn’t find web pages that might be related to your query, it computes factual answers to your query (except when it doesn’t).

Typically this means your query must be constructed in a slightly different way (perhaps using slightly different language) than you would use for a search engine. It’s worth taking the time to experiment to see what works and what doesn’t work. Perhaps my best description of Wolfram|Alpha is that it is a combination of a calculator and an encyclopedia.

The iPhone app features optimized input and output for the interesting and useful Wolfram|Alpha computation engine.

W|A knows all sorts of interesting facts. For instance, Robert was a more popular given name than William in the U.S. for most of the 20th century (though William recently overtook Robert… a sign of things to come?).

The app provides a number of ways to share the interesting results you find. Click the “share” button in the upper-right corner, or press and hold on a result.

The app also has numerous built-in examples to help you get started.

It also contains a complete history of all your queries.

Many of the computations have parameters that can be fine tuned for more precise results.

So there you have it. The app was a lot of fun to write, even if the release schedule was a bit hectic. The next version should be even better.

Late night coding

The End of September

If I look tired, it's because I am

Between the baby and work, I’ve been utterly exhausted. Hopefully the work-related busyness will ease up before the end of this week when I finish up with the big project from the last two months.


Photo of the Day

"September 2009 Photo of the Day"


Running

Well, I’ve been running a couple times per week, usually pretty fast. I feel like I’m definitely getting back into shape, despite the fact that my fun run times have been slightly slower each week.

Course

Month Distance # Workouts Avg per Workout
January 109.34 Mile 10 10.934 Mile
February 55.83 Mile 7 7.97571 Mile
March 108.792 Mile 10 10.8792 Mile
April 74.85 Mile 8 9.35625 Mile
May 64.5669 Mile 9 7.1741 Mile
June 7. Mile 1 7. Mile
July 0 0 0
August 16.3 Mile 5 3.26 Mile
September 39.78 Mile 7 5.68286 Mile
Total 476.458 Mile 57 8.35892 Mile

Cycling

I’ve been doing roughly one ride per week. It’s been too hectic to get out any more than that. I had a fun ride up in Chicago last week with the XXX Racing team.

September 2009

Bike Distance # Rides Avg per Ride
Bianchi 33.15 Mile 9 3.68333 Mile
Pocket Rocket 73.96 Mile 8 9.245 Mile
Thundercougarfalconbird 180. Mile 4 45. Mile
Total 287.11 Mile 21 13.6719 Mile

January – September 2009

Bike Distance # Rides Avg per Ride
Bianchi 500.65 Mile 112 4.47009 Mile
Big Red 12.07 Mile 4 3.0175 Mile
El Fuego 54.42 Mile 7 7.77429 Mile
Pocket Rocket 280.93 Mile 39 7.20333 Mile
Thundercougarfalconbird 1638.2 Mile 39 42.0051 Mile
Total 2486.27 Mile 201 12.3695 Mile

Walking

Will loves walking, so I’ve been doing quite a bit of that, more so earlier in the month.

A quiet moment

Month Distance # Workouts Avg per Workout
January 0 0 0
February 3.75 Mile 2 1.875 Mile
March 0 0 0
April 8.51 Mile 4 2.1275 Mile
May 6.7 Mile 4 1.675 Mile
June 11. Mile 3 3.66667 Mile
July 29.52 Mile 10 2.952 Mile
August 35.02 Mile 14 2.50143 Mile
September 29.82 Mile 12 2.485 Mile
Total 124.82 Mile 50 2.4964 Mile

The Silence

It’s been a little quiet around here lately at My Name is Rob. In real life things have been anything but quiet. Nearly all my time at home has been occupied by our little bundle of joy, Will (now six weeks old).

Six weeks

On top of that I’ve been busier at work than I’ve ever been before. I am in the middle of seven projects at the moment (up from the usual two or three), one of which has completely monopolized my time for a month or so. The other six haven’t gone away, they’ll still be waiting for me when I finish this one. Needless to say, things have been pretty tense lately. It’s no wonder Will has been able to post way more to his blog than I have to mine.

As I write, I am putting off packing for my weekend trip to Chicago for a software development conference. I really should get back to that.

Oh, and what’s the deal with the damn soy aphids?

Muggy and buggy night

The Past Few Weeks

I’ve been somewhat quiet lately.

First, there was the Tour. I watched almost every minute for three weeks. There were lots of exciting moments and plenty of dull moments as well. One thing that kind of annoyed me was the extent to which the media (TV & Web) tried to create controversy around every little thing (Alberto vs. Lance, Cavendish vs. Hushovd, Hincapie vs. Garmin, etc, etc). Sure, there was probably some legitimacy to it, but everything just seemed to be blown completely out of proportion.

Next, as Melissa mentioned, I’ve apparently been nesting. We’ve done lots of work around the house in preparation for Fig’s arrival, and there’s still plenty more to do. On top of that we had baby week.

Fig's car seat

Hand rest

Finally, the I’ve been busy working on a couple of interesting (to me) software applications in my spare time. I’ll probably talk more about them in the future.

The bad news is I’ve been out with this knee problem for around six weeks or so. Earlier this month I completely stopped riding my bike (I already stopped running at the beginning of June). I still swam a little bit, but it didn’t help that my swim practices conflicted with my watching of the Tour.

The so-so news is that I started riding the bike to work again last week and picked back up with the Wednesday night rides. Last Wednesday I didn’t feel great. I kept complaining about how hard the ride was when everyone else was talking about how easy it was. I’ve got some work ahead of me. My poor ride was further complicated by a complete bonk with about 10 miles to go. 24 mph became 22, then 20, then 18, then 16, then 14, then finally 12 mph the last mile or two. It was the worst I had felt since, well, the Illinois Marathon.

The good news is I’m feeling better day by day. Since monday I’ve had no knee pain on the bike around town, and only very little knee pain on tonight’s hard 50 mile ride. I felt much better on this ride than I did last week, but my fitness is still very poor (by my standards). My heart rate was absolutely through the roof for most of the ride. My average heart rate was 154 and my max was 189, which is fairly ridiculous. Typical numbers from two months ago would be closer to 135 average and 178 max.

Sangamon River route

Tonight’s ride combined several commonly used routes along the Sangamon river into one, making for just about as much rolling hills as one can get around here.

The Scooter

Yes, I bought a scooter. No, I am not 12 years old. Let me explain.

As I mentioned, I’ve been having some knee problems lately. Weight-bearing isn’t a problem, but bending the knee is. Even riding my bike two short miles to work has been bothering it. The knee kept not getting better and not getting better. It was time to take drastic steps.

I drove to work on Monday. I loathe driving to work. I had to deal with traffic & parking, all while cramped up in a tin can, spewing toxic chemicals into the air. It took the same amount of time as riding my bike. Surely there’s another way.

Walking would take around 40 minutes each way, and it doesn’t really solve the bending-my-knee dilemma. I checked into taking the bus, but there’s not a good way to get there. I would have to go miles out of the way, change buses multiple times, and it would take the better part of an hour.

How could I travel a moderate distance under my own power with minimal bending of my problematic knee? The answer came to me while perusing the Wikipedia page for human powered vehicle: the kick scooter.

Scooty Puff Jr.

The Scooty Puff Jr. (cf. Futurama)

Kick scooters were a fad when I was a kid. This newer type has been popular with kids the past few years, though the kiddy models don’t support the weight of a full grown human male. Fortunately, Razor also makes an adult model with a higher load capacity and larger wheels for a smoother ride. I was so desperate for a solution I bought one.

Rob takes the scooter out for a test ride

It arrived on Monday and it took it for a quick test ride around the block, much to Melissa’s amusement. At first it was remarkably unstable. The platform is almost exactly the size of my right shoe and balancing is a little tricky. It definitely took some getting used to. I found it to be more stable the lower I adjusted the handle bars.

The “tires” on the 7″ wheels do not inflate, they’re a solid rubbery-platic material. The ride is not smooth, it’s much more jarring than riding a bike. I’ve learned to seek out smoother sections of pavement and to prefer concrete over asphalt.

Urbana welcomes you

I rode the scooter to and from work and the swimming pool three days this week, putting about 11 miles on it. I assume most of these cheap little scooters don’t see that much mileage over their entire lifetime. I wonder how long it will hold up. It takes 20 minutes each way, so it’s half the speed of leisurely cycling and twice the speed of walking.

While riding the scooter is somewhat enjoyable, I do get some strange looks. It’s not everyday you see a 30 year old man riding a tiny scooter wearing a backpack and helmet. I do not intend this to be a permanent solution. I just need to take a couple weeks to hopefully let my knee heal completely before starting to ride my bike again.

The Homer Fireworks

“Celebrate the independence of your nation by blowing up a small part of it.”

My friend John and another coworker of mine were helping out with the fireworks show at Miller Aquatics and Health Club, just outside of Homer, on Wednesday. They invited us out to watch, though I didn’t think I’d be home from my bike ride in time to make it out to Homer by 9 pm. Fortunately, I was home in time and we decided at the last minute to go.

The show was really well done and we sat very, very close to the launch site, so we had a different perspective than I’ve ever had for fireworks before. As you can imagine, I brought my camera to try to get some good shots of the fireworks. It took some getting used to, but I think by the end I started to get some good photos.

It's that time of year

The iPhone

The original iPhone was announced at Macworld Expo in January 2007 while Melissa & I were living in Nicaragua. It was amazing, a phone that ran the same beautiful, wonderful operating system as my desktop and laptop computers. The crowd at the Macworld keynote was disappointed the device wouldn’t be available until June. No matter, I wouldn’t return to the U.S. until August.

I ordered my iPhone in July and had it shipped to my parents’ house so it would be waiting for me upon our return. Around the same time I also ordered a new (non-i) phone for Melissa. We arrived at my parents’ house on a Sunday evening. The iPhone was there, in all it’s glory, but I couldn’t actually use it yet. Apparently, because of the way I set up our account with AT&T, I needed to activate Melissa’s phone first. This required talking to AT&T customer service, which wasn’t open on a Sunday evening.

The disappointment only lasted a few short hours, which was nothing compared to the months of waiting I already endured. I got everything straightened out with AT&T first thing Monday morning and my iPhone was up and running. I loved it.

Cracked screen

Two months later, while I was locking up my bike at work, I dropped my padded carrying case about two feet onto the concrete. The phone slid out face down. I was concerned the concrete might scratch the glass. Even worse, the glass cracked. It was still usable, just less beautiful… but not enough to warrant $199 to replace the screen.

In April 2008 the iPhone (and iPod Touch) developer program was announced and I signed up right away. As a software developer I am exited by the prospect of running my own code on my phone/PDA (much as I did with three previous Palm OS devices, and three Windows Mobile devices). At first Apple highly recommended not using your primary phone for development purposes, so I bought a refurbished iPod Touch.

The iPhone 3G was unveiled in June 2008 to much fanfare. I didn’t really care that much as AT&T still does not offer 3G data service in Champaign-Urbana. I was excited about the built-in GPS and larger storage capacity, but not enough to upgrade. Fortunately, my employer acquired on which I have been able to use. Score. In the meantime I set up my old iPhone for Melissa.

Finally, earlier this month the iPhone 3GS was announced. More storage, better camera, video recording, built-in digital compass. My AT&T contract was nearly up so I qualified for upgrade pricing. It didn’t take much convincing for me to order one. It was Fig’s Father’s Day present for me. It arrived last night and I’ve been using it all day today.

All in the family

from left to right: my original iPhone (now used by Melissa), my iPod Touch (used for development), my employer’s iPhone 3G (soon to be returned), my new iPhone 3GS

The Keynote

As I write, Melissa & I are at Chicago O’Hare airport waiting on our (delayed) flight to San Francisco. I am attending Apple‘s Worldwide Developer Conference (WWDC) this week. Melissa is along for the ride.

Since I started working full time as the primary Mac OS X developer of Mathematica at Wolfram Research in 2001 I have attended this conference every year except 2006. That year the conference was scheduled (Apple has been really bad lately at waiting until the last minute to schedule this huge conference) during the week Melissa & I were moving to Nicaragua, so I missed out. The conference is exciting every year, but none was more exciting for me than 2005 when I (along with my boss Theo Gray) participated on stage during Steve Jobs’ keynote address.

Note: some of this information was confidential at the time, but is now mostly publicly known. I can’t imagine any of the details I mention below would still be considered sensitive information.

On Wednesday night the week before WWDC I got a call at 9:30 pm from Theo. I was almost ready to go to bed. He asked if I would be able (and willing… but more able :) ) to fly to California at 6 am the following morning. I suppose I could, but why? Theo went on to tell me that Apple had a super secret project and they wanted our help, but he wouldn’t tell me what the project was.

I have since learned that he actually knew what the project was at the time of that call, but he couldn’t tell me. Stephen Wolfram, the founder and president of Wolfram Research wouldn’t sign off on the idea until he knew what was going on. Steve Jobs told Stephen Wolfram & Theo what the project was and they agreed to take part… but they couldn’t tell anyone else.

I spent the next two hours packing (including the Dahon, my folding bike at the time) before going to bed. Early the next morning I arrived at the Champaign airport. Apple purchased my one-way ticket to San Jose (by way of Chicago). An Apple limo picked me up at the San Jose airport and drove me straight to Apple’s campus in neighboring Cupertino. Luggage still in hand I entered 3 Infinite Loop (I think). A few minutes later I was in a meeting with Ron Okamoto, Vice President of Worldwide Developer Relations.

Ron told me what the secret was, that Apple was building a Mac which used an Intel x86 processor. They had ported all of Mac OS X to this new architecture (Darwin, the open source core of Mac OS X, already ran on x86). They intended to demonstrate this new x86 version of Mac OS X on Monday’s WWDC keynote. They wanted to demo a 3rd party application running on the x86 Mac. They chose Mathematica to be that 3rd party application. He asked me if I thought it would be possible to get Mathematica up and running on Mac OS X Intel by Monday.

Uhhhh.

That’s a potentially huge task. Our code is fairly portable (at the time Mathematica ran on several Unix platforms in addition to Mac and Windows), but supporting new platforms usually takes a fair amount of time. Ron told me Apple was prepared to provide significant resources to make this happen, including a small team of Apple developers and immediate access to any other relevant Apple developers. I was cautiously optimistic.

(Now 30,000 feet over Iowa)

We travelled across De Anza Blvd (luggage still in hand) to a different Apple building where I was ushered into a conference room with a single desktop computer sitting on the conference table. It was in the same metal case as Apple’s high end desktop computers at the time, the PowerMac G5. I think the case even said “G5” on the side. From the outside you couldn’t tell the difference between this machine and a G5 unless you carefully peeked through the holes on the front and noticed it didn’t have the huge heat sink the G5’s had.

I was greeted by the team of Apple engineers (Matt, Eric, & Ronnie) who would be providing technical assistance in the porting process. This place was not only hidden from the public, but it was hidden from the rest of Apple. Very few people at Apple were even aware this project existed. The four of us got busy.

I sat down at the Macintel and immediately began working. The experience wasn’t just familiar it was identical to any other Mac I had used. I was blown away by how seamless Apple had made the transition. The whole OS was there it all its glory, including every bundled application (even Xcode). I could just work exactly like I do on any other Mac.

But wait, sometimes I use BBEdit to edit text. I guess I won’t be able to do that since it (or any other 3rd party application) hasn’t been ported yet. “Why don’t you just go ahead and try it?” Matt said to me as he tried to hold back a smile. It hit me immediately. “You’re kidding, right?” I downloaded BBEdit, double clicked the icon, and it ran. I ran just like it does on any other Mac. Apple had incorporated (with technology licensed from another company) a PowerPC translation layer into the OS. This meant that nearly all existing Mac applications would run on the new Intel machine, with a slight performance penalty. This was amazing news, as it meant the new machines could be adopted immediately by users rather than waiting until all their applications were ported. Very exciting.

Back to work. We started with MathLink. This is a low level library used by both the Mathematica user interface (FrontEnd) and the computation engine (Kernel). With one set of flags MathLink builds for Mac OS X PowerPC and with different flags it builds for x86 Linux (or Windows, etc.). It only took a few minutes of experimentation with the Makefile and headers to find the right set of flags to treat the OS as Mac OS X and the architecture as x86. The elapsed time from entering the conference room to having a built, fully functional MathLink library was probably around 20-25 minutes. As we progressed our excitement grew.

Xcode target architecture

Next was the Mathematica FrontEnd. I normally spend all my time working on the FrontEnd, so this part didn’t worry me much. The FrontEnd is built with Xcode, which had a new “architectures” setting checkbox. We checked the checkbox for the Intel architecture (actually, we didn’t because Intel was the default target architecture when building on Intel… but we did verify the checkbox was properly set). Within 4-5 minutes the FrontEnd built with only a couple of minor build errors which were easily fixable. After 10 minutes working on the FE we had it built and running. It wasn’t running flawlessly, but it was a very good start. I had only been at the secret Intel machine for around a half hour. This was getting really exciting.

The next step was the one which caused me the most concern, the Mathematica Kernel. The reason for my concern was that I don’t often work with the Kernel. I knew how to build it (the build system is somewhat complicated) and I knew roughly how the code was organized, but there are all sorts of minor details which could really slow down the process. It relies on many external libraries (open source and commercial) and custom build tools. Fortunately, the Kernel, like MathLink, already ran on Mac OS X PowerPC and Intel Linux & Windows. It took a while longer to figure out some of the proper build flags, and some of the build errors weren’t entirely obvious.

This is where Matt, Eric, & Ronnie really came through. They had each spent a lot of time porting open source applications to Mac OS X Intel to learn what types of issues developers might run into along the way. Each time we encountered some sort of problem in an open source library one of them would go off on their own for a few minutes to resolve the problem while the rest of us kept hammering away. Every few minutes we would get further and further along in the build process with new issues popping up all the time. It was like an assembly line. In parallel.

After about 90 minutes (2 hours from when I entered the room) we had the Kernel running, the FrontEnd running, and the two processes were able to talk to each other through MathLink. Again, it wasn’t perfect, but nearly everything just worked.

News spread up the ranks. Within minutes we had high level executives stopping by to see the first 3rd party commercial application running on Mac OS X Intel. By early evening Theo (who took a later flight) arrived frantically asking what he can do to help. He was a bit shocked, and very pleasantly surprised, that it was mostly done.

Friday we worked to fix bugs and showed off the software to an ever growing number of people. Since Mathematica already ran on Intel processors on other platforms, most of our cross platform code was byte order agnostic. There were a few cases where Mac specific code was assuming big endian byte order, particularly related to Quartz (bitmap drawing) and OpenGL. There were also some issues with Quickdraw PICT drawing.

Friday evening some of the Mac rumors sites (original CNET article appears to have been removed) reported that Apple would be announcing the switch to Intel processors at Monday’s keynote. Rumors like this had been published for years, so it wasn’t that out of the ordinary, but this report was different. It contained many specific (correct) details rather than just wild speculation (like every previous report like this). It was clear someone in the know had blabbed. The conference room was silent for a few moments. Oh well. Until Monday, it’s still just a rumor.

Saturday morning we drove up to San Francisco to prepare for the WWDC keynote. We had a rehearsal where I met and shook hands with Steve Jobs. I had heard horror stories about his temper, but he was in a great mood when I met him… sitting perfectly relaxed, legs crossed, smile from ear to ear. I could tell he was excited.

Theo practiced his speech, asking Jobs for feedback along the way. The funny thing was that Steve was so happy he kept telling Theo “say whatever you want” or “talk for as long as you want.” Meanwhile I set up the demo machine (and backup demo machine) with our freshly built Mathematica for Mac OS X Intel.

Monday morning before the keynote Theo & I hung out in the VIP lounge. Woz (Steve Wozniak, the other co-founder of Apple) was there, Sergey Brin (co-founder of Google and former Wolfram Research intern) was there, along with many other influential people in technology.

Once the keynote started we sat in the front row on the far right side. Midway through the keynote Jobs called us up to the stage. Theo described our experience porting Mathematica to Mac OS X Intel over the previous few days. I drove the demo machine as he talked. It was a big hit. Theo captivated the audience. At one point Theo mentioned my name, which immediately caused 4,000 people to turn their heads to stare at me. It was a little awkward (which is quite evident in the video). Had I known that was going to happen I think I could have played it a little more cool. Anyway the demo was a success. Mission accomplished.

Note that a few minutes of the demo were edited out of this video for some reason.

That wasn’t all for that WWDC. On Tuesday I gave a 10 minute presentation during Bud’s science session about Mathematica on Mac OS X, detailing how we utilize various OS features. This went more smoothly for me as I had actually been preparing for it for a few weeks. Later that week I spoke about Mathematica for a minute or two in Ernie’s 64-bit session. I went from participating in zero sessions my first four WWDC’s to three sessions in 2005, back to zero sessions every year since. Perhaps that was my 15 minutes of geek fame (actually, the total time I spent on stage was almost exactly 15 minutes).

Last year I attended a reunion for the non-profit organization where I worked in college, ASP. A guy who I hadn’t seen in 8 years came up to me and asked me if I was in a Steve Jobs keynote a few years ago. “I thought that was you…”

Anyway, tomorrow’s 2009 WWDC keynote won’t be as exciting for me, though I’m sure it will still be exciting. I won’t be participating in the keynote. At least, if I am they haven’t told me yet. Always with the secrecy.

The Hardman

A friend pointed me to this humorous blog post discussing various types of bicycle commuters. As many of you know I’ve commuted to work by bike for a number of years. Since we’ve been back from Nicaragua I’ve only driven a car to work three times, and all three of those times I was transporting large and/or heavy objects.

Back to the types of commuters. I’ve certainly seen each of these types of commuters before, which is why I found the article so funny. Clearly, I fall somewhere between The Pro and The Hardman.

The PRO

That’s right – YOU. You didn’t think you were gonna get out of it so easily, did you? You’re the only one who thinks you’re the coolest kat in town. You’re the guy who gets all kitted up, pins a number on, rides the Zipps, and has an espresso flavored powergel on your way to work. But I’m sure you have good reason to ride in like this…It could be because you have a race after work, you need to take your bike to the shop at lunch, or it could be because you like to show to all your coworkers how PRO you are. Sorry, but we’re the only people on the planet that think spandex, shaved legs, and tiny arms look cool.

During the summer I show up to work on my race bike with shaven legs, just waiting to start my training ride after work.

The Hardman

This is the guy who hasn’t missed a day of commuting to work since 1993. This is a badge of honor to this steed and everyone at work talks about him around the lunch table like he could win the Tour de France. You pipe up every time and try to make them understand that he is not as PRO as you are and that you’re in fact the much more dedicated cyclist.

I also ride all winter long. I don’t hesitate to grab the bike lock keys, rather than the car keys, on my way to work in 5˚ weather.

El fuego en la nieve

The one day this past winter I didn’t ride to work wasn’t because I didn’t try. The roads were covered with ice, I fell, bruised my hip, and limped back home. I worked remotely that day.

Icy streets