Tuesday 8 July 2008

Hello World

I am a scientist. I am also very very bored.

I have become frustrated with my job. I'll go into the reasons for this creeping disillusionment in later posts but recently I've found during work that my mind wanders. I take up hobbies (photography, golf, cycling, plenty more) and spend far longer reading and thinking about those than I do thinking about my day-to-day science. I also spend a lot of time wishing that I could do more activities that actually create something physical. In an ideal world i would be a chef or, in a world where I had any artistic talent at all I would spend my days sculpting, making furniture or being an architect. It's a bit late for some of those changes now (at least it is without a massive source of cash to support me while I sort myself out) so I've decided on something else.

A few months ago a very generous uncle gave me some money to buy a new computer and I decided to switch from PCs to a Macbook Pro. I have a soft spot for Macs nurtured by using them in my Apple-centric department at University and I've been attached to my iPod ever since the second-generation one that I had in 2001 (even though it was a brick compared to models that came later). I love the design of the hardware and software, the fact that the company seems to care about the user experience and, if I'm honest, the slight feeling of superiority that I get from owning one. The main problem was that I couldn't afford a Mac - despite all of the convincing evidence that the total cost of ownership is the same or lower for Macs vs PCs I didn't ever have the free, disposable capital available to start to actually OWN one. Now I do and I'm infatuated with it.

I've spent some time getting used to OS X instead of Windows and exploring the software available for the platform. I've been blown away by the quality of applications available. Anyone who's ever looked for Windows software to achieve a specific task will be familiar with the experience of finding a million different programs that all seem to do the same thing and that all look like they were designed by a blind idiot who actively hates the users of his program. Rarely do they work well. Lots of people before me have noticed that this experience is somewhat different on the Mac - the quantity of software is somewhat reduced BUT what is available is worlds ahead in terms of quality. It feels like it's been designed rather than hacked together and is way more pleasant to use.

I guess this is due to the desire of developers to continue the experience of the OS into their software because mac people complain vociferously if programs feel "wrong". Whatever the reasons, the users all win. I think that developers win too - I've found myself massively more willing to buy software for the Mac than I was for the PC. If everything available is horrible to use why would you buy something if there's an equally unpleasant freeware alternative? Or, if the only option requires payment why would you buy it when it's easily available via t3h torrentz for free (not that i'd ever do that....)? I'm more than willing to pay for software if it works, looks good, is nice to use and solves a problem that I have.

One of the best pieces of Mac-only software that I've found is Papers. A large part of science (especially when doing a PhD) is the reading of journal articles. These papers are where scientists publish their work for others to read (eg in Nature,Science or other much smaller, more specific journals). When writing up one's own work for a paper or a PhD thesis it's incredibly important to reference the articles that one has read to back up statements and demonstrate an awareness of the field. You can probably guess that having a system to organise your papers is rather useful to save time and effort. Most journals are now available online (often requiring a heart-stoppingly expensive institutional subscription) and so a collection of papers is usually a load of PDFs rather an a pile of print-outs. When I was using Windows I followed most other academics and used EndNote. This ticks the boxes mentioned earlier of looking nasty and being difficult to use - it *is* good for inserting citations into a Word document but otherwise used to suck the life out of me on a regular basis. I had a look at the Mac version but it is equally unpleasant to use and, since Microsoft decided they couldn't be arsed to implement VBA in Office 2008 for Mac, doesn't even insert references into Word. Some searching around coupled with a well-timed Ars Technica reviewpointed me at Papers. It's written by two guys (Mekentosj) who did it during their PhDs and it's a revelation. Nice to use and look at, it makes all of my article-management tasks quick and easy and uses the excellent PDFKit in OS X to allow reading of articles from within the program. In short, it's great.

So, finally, the reason for this blog. Whilst browsing around the Mekentosj website I found this page about how they write their software.

...we had no programming skills whatsoever. Being interested, and having tried to start a few times, we had desperately failed each time, stumbling upon this utterly steep learning curve. But somehow, the release of Mac OS X in combination with all the talking about this great Cocoa programming environment and free tools made us feel that now was the time to really go for it. We bought a great book on the C programming language just to learn the basics. Soon after, we downloaded the developer tools, and made the switch to Objective-C with help of O'Reilly's Cocoa book. After the obligatory "Hello world" and "Currency Converter" samples, things really started to take off, and soon after we finished our first program. LabAssistant was launched in the summer of 2001, only a few months after the C programming book was bought. If you have ever thought to start programming, now is the time!


This started to fire some inspiration in me. I have never properly written programs. As a geeky teenager I played around with Basic and OPLon my Psion 3a (told you I was a geek!). More recently I've had to write some moderately complicated VBA macros to automate tasks in Excel and Word for work. I've discovered that I really enjoy the challenge (even if it's pretty simple) of bending a computer to my will and making it do my bidding. I like the fact that getting a program to work is basically just a big puzzle to be solved - this pleases my slightly obsessive-compulsive brain. So I've decided to teach myself how to write software in Cocoa and Objective-C for Mac OS X. I have some ideas for what I want to write but it's going to be a long time before I'm proficient enough to even attempt those so I won't go into them yet.

I also want to do some more (non-scientific) writing so I've started a blog. Hopefully this will enable me to document some of the process of learning Cocoa and Objective-C which will help crystallise the ideas in my head but, maybe, also be of use to anyone in a similar position who stumbles across my posts. I won't only be writing about programming but also about anything else that might be interesting. Maybe people other than me will read this - who knows? If you are reading this and you're not me, please leave a comment so I know that I'm not just shouting into an empty room.

1 comment:

Gareth J said...

Dude -the old 2nd gen ipod, that took me right back to portugal place! I'm still somehow keeping my 3rd gen alive having promised myself i wouldn't replace it until it a)died or b)something came along that did A HELL of a lot more. Now with all the bloody speculation about a 32gb iphone i can't bring myself to commit yet...

Just checked & i appear to be your first reply-ee, feel honoured