Random thoughts, daily life, being a student, quantum computing.

2007-07-30

Setting Goals

So, how do you set them? How do you determine what is or isn't important enough in your life to be a goal?

Stephen Covey gives a very simple method in his 7 habits book. Write your eulogy. Determine how you want to be remembered by family, friends and others.

I've done this in my past and the biggest thing that comes up for me is that I really want to get a doctorate and teach. So, that is my long term direction. At the same time, there are many other items in my life that are very important. Among them are:
  • Financial security

  • Family

  • Health


Obviously the list is at a higher level than "Get a Ph.D.". That one fits under an item probably called "Personal Improvement".

So, for a start, I have the four areas I want to concentrate on. Thinking somewhat more abstractly though, what are the principles and purpose I want to govern my life? Purpose is usually an angst filled discussion :). Typically, if someone asks me that, i would respond, "To fullfill god's will." (For god - feel free to replace with your higher power of choice. I was raised an Anglican, but feel more agnostic / Buddhist than anything else now) .

At times, I have felt this was a cop-out. What if my purpose really is to teach math and computer science. (I am quite good at teaching this stuff, and really enjoy it)

Well, time will tell. The next post(s) will explore how to turn the concentration areas into actual goals.

2007-07-09

Haskell and Java

In my day job, I program with Java. In my grad studies, where I'm working on a Ph.D. in Computer Science, I program with Haskell. Most of my research involves computer languages, my Masters thesis was on creating a quantum programming language, including an operational semantics, a simulator and a compiler. The compiler and simulator were written in Haskell.

I like Haskell. It appeals to the way my brain works. Being a functional language, it tends to be less verbose and "It just works." The last part refers to the fact that once you have the types defined correctly and the compiler accepts your program, it often is correct. The amount of debugging tends to be minimal.

Java, as you may know, requires a lot of debugging. Null pointer exceptions, class cast exceptions in collection objects (we are still stuck at 1.4 at work), and general algorithm problems.

So, when I get any chance, I sing the praises of Haskell vs. Java. This last week, I needed to create a small tool that would check consistency of the CVS Repositories in a project. Sometimes, my developers get a bit excited, copy over code or supporting files to a new directory and neglect to remove the CVS information from the copied files. (Sigh!). So, a nice simple directory walker that checks the consistency is all I needed. I thought - why not Haskell? So, I wrote it up in Haskell, using GTK2HS for the interface.

After showing it to my team, one said "Gee, that would be nice to have as an ant task". I thought so too, so I resolved to do that on the weekend.

Much to my dismay (and depression). The Java code was shorter, simpler and faster to write. Why?

Well, some of it is due to the interface documentation. My GTK2hs code involved using a tree list, which is new with the latest release ot GTK2HS and required a bit of trial and error. The Ant task documentation in the O'Reilly ant book is excellent.

Some of it is due to the interface. Any one who has programmed with gtk knows that there is a lot of setting up to do the simplest screen. Ant tasks, on the other hand, have a pretty direct and simple interface to the world.

Lastly, and this is the really sad part, I'm probably faster with Java lately, as that is what I use day to day. Sigh.

2007-07-07

Love, Love, Love.

What is the nature of love? I've been married for almost 10 years now, and it feels like I'm more in love than ever. I also feel more loved than ever. I consider myself quite blessed.

I think it may be trite, but true, that love comes from commitment. I was committed, she was, and so our love grew. Very cool. Sometimes it takes work and sacrifice, sometimes not. I can be moody, as can she. Sometimes it requires distance, sometimes we just can't get close enough.

So, why do I feel more loved than ever? A simple example happened this morning. I swore up and down yesterday that today I was going to be glued to my desk and nothing she could do would get me out and about. (Yes, I'm Canadian, eh!) However, this morning, I remembered I had left my O'Reilly Ant book at work, and I have to write a custom ant task for Monday. I needed the book. Because of my ankle (see post from a few days ago), I had to have her drive me.

This was love. She just said: "Sure - let's go".

So, that's the nature of love.

2007-07-06

Analysis paralysis

In my day-to-day job, I'm a computer consultant.

One of our pet phrases in the management / PM end of things is Paralysis by analysis. In case you have never heard of that, or just don't work in the industry, it works like this: System development in larger companies often follows a few set phases:
  • Initiation (Gather requirements, sponsorship, estimates)
  • Analysis and design (Detail what needs to be done, what will the system look like)
  • Development (Code!)
  • QA andimplementation (Test and start using it)
Of course, this is quite an oversimplification. If you are interested in this sort of stuff, a good starting point is wikipedia.

Paralysis by analysis refers to the penchant for certain developers to never move out of the analysis or investigation phase. This is a common trap to fall into, because there is always more to know.

Since my last blog almost a week ago, I've fallen into that myself - with respect to blogging. I would spend some time thinking about what I should write and then do nothing.

So, my resolution is to just not do that, or stealing from Nike - "Just blog it!"

2007-07-02

Why blog?

My understanding the nature of blogging is to do it often and do it quickly. Hmmm. How do people shift the priorities in their life to do this? Why would I want to trade an hour of my life to publish something that likely no one is going to read? (I use a blog tool on Ubuntu rather aptly named drivel).

Since my initial foray below, I've been involved in numerous time users:

  • Living life - cleaning my office, doing book-keeping, cleaning my house, spending time with my wife.

  • Going on a train ride with my daughter, son-in-law and grandchildren.

  • Upgrading the aforementioned Ubuntu to release 7.04.

  • Recovering from a sprained ankle.


Perhaps the most interesting item to others on this list was the upgrade. It went very smoothly in general. Two items required additional work. First, I have mediawiki installed from long ago when I was using Debian Gnu/Linux. It was time to actually upgrade it and use the packaged version. To convert over, I installed the package using synaptic and then:

  • Edited the apache2 configuration files so that only the new version had an alias of mediawiki.

  • Copied the images data under the old version to the update directory of the new version.

  • In MySQL, created a "superuser" for the wiki database and added that to AdminSettings.php.

  • Ran the update.php and then the update links script in the maintenance directory of the new version to update the database.

  • Copied in extensions etc, fiddled with caches and away I went.


Truly not difficult.

The next one, VmWare, was also easy. My initial install of Ubuntu, at version 6.10, spoiled me as it was the first time in my 5 year history with VmWare that I was actually able to download the modules. I was not as lucky with version 7.04.

So I tried compiling and as is normal for fairly recent kernels and VmWare, it did not work. So, I go get vmware-any-any, apply it as I am used to doing and the compile complains about "cc1plus" not found. Ha! It took a while to figure out that I did not have g++4.1 installed. I added that and voila!.

So, how much time of my life have I traded to compose this drivel? About 1/2 an hour. At this point, I rather enjoyed it, perhaps because I felt I had something to say. Maybe that's the point.