Sunday, September 21, 2008

Financial Meltdown - Unbelieveable







What a week it's been.

Is everyone else as incredulous as I am about the week's news? The US government, long the champion of free markets and deregulation being best for everyone, led by a Republican administration that styles itself as the champions of small government, has bailed out Bear Sterns, nationalized the mortgage market by taking over Fannie Mae and Freddie Mac, ponied up $89B to shore up AIG, and then promised to take on all the bad assets that were too radioactive for a rational investor to touch to the tune of $700B?

Each move was supposed to calm the markets and restore confidence, but the tonic never lasted more than a day.

I thought that Congress was the branch of government that controlled the purse strings. Now Henry Paulson and Ben Bernanke, neither of whom is an elected official, seem to be calling all the shots. Is this constitutional? Why aren't Congress and the Supreme Court weighing in on this?

George W. Bush must be hiding in a bunker, riding his mountain bike, or clearing brush somewhere. He's not much in evidence. I'll bet he sits silently in any meetings he's actually invited to. He's certainly doesn't appear to be a main player. Is this what degrees from Yale and Harvard get you?

Glass-Steagall was repealed in 1999 by Phil Gramm et. al, during the Clinton administration. Sandy Weill and his cohorts said we didn't need it anymore, so the wall between commercial and investment banks came down. We were so much smarter than we were in the 20's.

Eight years of Republican leadership have brought us to this. They actually controlled both the House and Senate for six of those eight years, so there's no one else to blame.

The Democrats have not distinguished themselves, either. Has there ever been a less effective opposition? I've lost count of all the times when they rolled over and died in the name of bipartisanship. From where I sit, there's not much difference between the parties. Democrats might be tax and spend, but Republicans are cut taxes and still spend. We'll have the largest deficits and overall debt in history at the end of this Republican administration. Our children and grandchildren will be left to survey the wreckage and curse their parents for what they've allowed to happen.

Henry Paulson used to be the chairman of Goldman Sachs. It feels like an inside job. The fix is in, and he can bail out all his cronies from Wall Street.

We can come up with three-quarters of a trillion dollars to bail out people who have been collecting bonuses that are more money than I'll make in a lifetime, but anything else is "fiscally irresponsible" or "liberal".

And all we can talk about during election season is Sarah Palin's hair, lipstick, and who's more of a Christian.

I simply can't believe it.

Saturday, July 5, 2008

Bicycle Riding, Past And Present





Last Saturday was a brilliant summer day, sunny but not too hot, with low humidity. I got my road bike out for a ride at 1:30 in the afternoon. My wife and daughter were out, so I had the afternoon to myself. When I turned out of the driveway I had to make a decision: which loop would I follow? I've been taking a familiar loop around a lake in the next town. It takes a little more than an hour, and there's a long, steep climb in the middle, but an hour in the saddle is not too difficult. I've gone out a few times this year, the first rides I've taken in two years after hurting my neck. But I haven't tested myself with a longer ride.

When I was younger I fell in with a bunch of bicycle riding enthusiasts at work. I rode my bike to and from work several times a week for as long as light and weather would permit. I'd put between 500 and 1000 miles on my legs in a good year. The season would end with a 100 mile ride to raise money for the Hemlocks Educational Center in Hebron. I trained all summer with the goal of finishing that ride. The first 25-mile loop took us south to Colchester and back to the center of Hebron. It was challenging, with a lot of climbing. I decided to attempt it, so I turned my bike to the left when I rolled out of my driveway.

I wasn’t sure that I was up for it when I left the house, but I wanted to try. I was worried about my neck, but it turned out to be just fine. I suffered on a lot of the climbing, but I surprised myself by doing pretty well. It took me 2:13 to cover 28.5 miles. That included a stop at the convenience store next to Butterball’s to get a cold Gatorade. I wanted to sit down and drink it, but there was a couple smoking outside the bar when I rolled up. The woman looked hard and worn. What the hell were they doing at a bar in the middle of a brilliant summer afternoon? How could beer taste better than Gatorade at that moment?

There’s one stretch in particular that I’ve always loved. A long downhill into Colchester has to be paid back, so there’s a fair bit of climbing after crossing the center of town. But once things level out you find yourself on a quiet, lightly traveled, two-lane paved road with a canopy of trees overhead to provide shade. You can get up on the biggest gear you have and fly along at an easy 20-25 mph. It’s a wonderful spot, one that makes me glad to ride a bicycle.

I started thinking back to twenty years ago during my ride. In 1988 I finished the 100 mile Hemlocks ride for the first time after several attempts that ended in pain and disappointment and after the metric century (63 miles). Michael Fraley, a young co-op who was working in the finite element group at the time was my companion.

I experienced “second wind” for the first time. I was spent and hurting at the second checkpoint. Every other year I decided that I couldn’t press on and turned for home, but this time I ate peanut butter and jelly sandwiches and bananas until it was time to go. I was in agony when I left the checkpoint. I could barely push the pedals down. I thought I would need a broom wagon to come and get me.

And then – like magic – the pain lifted. I felt a rush of energy through my body. The next loop was a hilly one, but I had no trouble getting up and down. I remember finishing the day in triumph, steaming up the road to the Hemlocks Educational Center feeling stronger than I had all day. It was wonderful!

I was the proud father of a two-year-old daughter. I was taking classes towards a doctoral degree that I never expected to finish. My father and brother were both still with me and in good health.

It was a good memory to carry with me on the ride. I wondered if extreme old age will be a blending of time? I felt like I was in the present and past all at once.

I was glad to be a middle aged man, still able to enjoy a long bike ride on a beautiful summer day.

Thursday, May 15, 2008

Changing The World

It's been a busy time of year. My oldest daughter will graduate magna cum laude from Wheaton College on Saturday. I'm very proud of her. I never got within shouting distance of having Latin on my undergraduate diploma. I've got a lot to do to get ready for the party on Saturday.

I stopped to watch some NBA playoff basketball the other night. During a time out I naturally surfed the channels to see what else was on. When I got to VH1, I saw that they were running a four-part history entitled "Sex and the Revolution". It had "sex" in the title, so of course I stopped to see what it was about. It was a documentary about sexuality in America from the 50s on. It featured Kinsey, Hugh Hefner, all the usual suspects.

The thing that struck me was the style. It interspersed still and moving pictures between commentary by "celebrities" and "experts", weaving them all together with a narrator on top.

The first time I saw history presented this way was Ken Burns' "Civil War" series on PBS. I was riveted during that presentation. I wasn't a Civil War buff, but that program almost turned me. Ken Burns has done a lot since then (baseball, jazz, World War II), but that first one was truly ground breaking and influential. Every document since seems to copy his ideas.

Ken Burns is a very talented man, but not every talented person gets to say that they changed the world for those that came after them.

What a great accomplishment. It started me thinking about how I've changed the world in my time on this earth. I can't come close to Ken Burns, let alone any truly ground breaking individual. I'd better get busy. Who knows how much more time I'll have?

Tuesday, May 6, 2008

Swim Tracking Application - Requirements




I do love to write, and the personal musings I put out onto the web from time to time might be fun, but I want this blog to be about technical matters. I hope that I'll learn something, and perhaps the things that I post will help someone else.

I've written about my love of swimming in the past. Since 1994 I've kept an electronic journal. I create a new Word document every month and write as often as time and energy permit. Each one includes an embedded Excel spreadsheet where I keep track of the number of trips I make to the pool and the yardage for each workout. I used to only swim at noon, 1800 yards at a clip. In 2000 I worked up the courage to swim with a Masters group for the first time. These workouts tend to be longer and more intense, so after 2000 I started breaking out Masters and noon workouts. At the end of each year I roll up all my yardage to see how I did.

2007 turned out to be an average year, in spite of my C6 disk problem. I had three months (Mar, Apr, and May) where I didn't swim at all, and I was still limited in June. By August I was back swimming with my Masters group. The last four months of the year were my best ever. I think that seeing the yards pile up and having a chance to get back to "average" were great motivations for working hard and not skipping workouts.

There are only two problems with this system.

The entry into Excel every month is very manual. I copy & paste the embedded spreadsheet from one month to the next, which is a bit of a pain. I manually transcribe the data into a second Excel spreadsheet that I use to roll up results and display lovely plots of yardage versus time. This is error prone and time consuming.

I would love to be able to index all those journal files with a search engine like Lucene. I have fourteen years of my life stored in Word files, and sometimes I find myself wondering when a particular event happened. I'd love to be able to type some search terms into a UI and have it return a list of files and dates when those terms appear. Since Word is Microsoft-proprietary I have to rely on a library like Apache's POI to read and parse the documents for indexing. Alas, the embedded Excel spreadsheets gum up the works. I get an exception when I try to read my Word docs, and POI isn't a very active project these days. There's a bug reported, and a promised fix, but it's been years since it was first posted. I won't hold my breath waiting.

So I'm proposing to write a swim tracking application for myself. If done correctly, this will give me more capability. As a bonus, I'll be able to remove those embedded spreadsheets and index my electronic journal files. That'll be another fun application to write!

I'd like to use technologies that I love and am familiar with, but would like to know better: Java 5, Spring, Hibernate, and MySQL or PostgreSQL for the relational database. I'll deploy on either Tomcat or WebLogic.

Should I think about an embedded database like Hypersonic? It'd be great to have a SourceForge or Google project that would allow someone to be up and running with a minimum of effort. If I follow that thought to its logic conclusion, should I also bundle it with Jetty? I'd like to have the lightest weight app server possible. Spring makes it possible for me to do robust Java EE development without EJBs, so that helps.

The user interface will be either straight JSPs, using JFreeChart for graphics, or Jasper Reports.

I'll use IntelliJ as my IDE.

I'll set up a Subversion repository for my source code.

Like any good software project, I'll start with my requirements.

Are there any good commercial or open source alternatives worth looking at? A Google search on "swim tracking software" tells me that there are some low-cost commercial programs available: Swim Shark, Jack Rabbit Swim, and Swim Log. But there are no open source alternatives out there. Maybe this will be a good niche for me.

I wouldn't mind stealing a peek at what they've done to see if I could duplicate any neat features. UI design isn't my forte, so having a few thoughts about how to lay things out might help, too. But the journey is as important as the destination, so I'll still be writing this myself.

This is a swim tracking database, but I could see where it might be possible to extend this to all sorts of activities. What about cycling? Running? I'm doing yoga on my own now. What if I had a nice calendar control to show me how frequently I was keeping up with daily yoga? Wouldn't a goal of 3-4 days per week be helped along by seeing a calendar tracking success? There's nothing like a string of "no yoga" days staring you in the face to motivate better effort.

I'd like to write it for multiple users. My daughters are both athletes, so maybe they'd like to track progress on their workouts. Security will be an issue. I'll have to have roles for different users and administrators.

I had a choice when I started tracking. Would I keep book yards on a monthly or weekly basis? I decided to stick with a weekly basis. The week ends on Sunday, because most of the swimming was done during the work week. If Sunday fell within a given month, that week would count against that month's totals. So a given month might be credited with four or five weeks of swimming, depending on when the Sundays fell. Would I continue with that system? Or should I switch to a true month accounting? It makes a difference when determining personal best yardage totals for a given month. Having a real relational database might give me some flexibility there.

So I account for total number of visits and yards each week, with a special tracking for Masters workouts and yardage. I'd like to keep that breakdown.

I've hit a lot of pools in the state. Most of the time these are 25 yard pools, but there are happy days when we're allowed into the 50 meter pool at the University of Connecticut. Unfortunately, those opportunities are rare. We haven't had a Masters workout in the big pool in years now. Should I maintain units, too? Or just leave everything in yards and convert in the UI when necessary?

I only keep track of total yards, but swimmers know that a workout can consist of different sets. Masters swimmers usually do all four competitive strokes in a single workout - butterfly, back, breast, and freestyle. Should my database allow me to break workouts down by set? Keep individual times? This is what a real coach would probably want. Maybe a database of workouts would be worth having. I could associate a given day's swim with a particular workout that way. It could be useful.

The payoff comes with the plots and reporting. I like knowing what my best total yardage is for a given month. So far in 2008 every single month has been either my best or second-best for total yardage. Sometimes I might feel tired in the morning, but knowing that I'm close to a best monthly total is all the incentive I need to get out of bed. I have plots of yardage versus month for each year, along with an "average" year curve. I could supplement that with theoretical curves for best and worst years, keeping track of all my milestone monthly totals.

Should I use a relational model, or explore a data warehouse-like star or snowflake schema? I'll have to think about what the pertinent dimensions should be. Since this is mostly a reporting database, there might be some advantage to going that way. I'm not sure how objects and Hibernate work with data warehousing schemas.

That's enough to think about for now. I'll have to see if Blogger allows me to post UML diagrams. I'll flesh out the design a bit more soon. But this is a fine start.

Saturday, April 26, 2008

First Toastmasters Speech




I presented my first speech at Toastmasters this past week. It's the icebreaker, and the topic should be a familiar one. The handbook suggests a speech about you. It helps club members know you better, and makes preparation easy.

I wrote my speech out - once, twice, three times. I practiced it in front of a mirror at home, timing myself to get an idea about the pace. I presented it in the car on the way into work. I felt ready on Tuesday.

I've always liked public speaking. I got over my fear early. My high school required two years of public speaking, so I had to take classes in my freshman and junior years. Both were taught by a rough and tumble man who was an assistant coach on the football team. He was a terrific speaker who knew how to prepare us well, but he wasn't above mixing it up with students who were unruly.

I had no problems in my freshman year. That was a time of "tracking", so I was in the highest track with a lot of students who were similarly serious minded. However, there was a scheduling conflict in my junior year, so the only section I could get was a class loaded with football players who were anxious for a shot at their coach. I learned to have no fear of the crowd there. I got to the point where I'd prepare on the way to the podium. My measure of success was how well I quieted the class. I began to think of myself as a pretty good speaker.

During my working career I had a few opportunities to speak. I had to present a paper to a large audience at Worcester Polytechnic Institute. The room was full when I explained my doctoral dissertation at a company conference. But I didn't get much practice or additional instruction. One day my boss decided to send me to a week-long class on public speaking. I was miffed when I heard it. Me? I don't need any help. I'm already a master! But I went anyway, and I was glad that I did. We were filmed during our presentations. I found it painful to see and hear myself. I learned a few good things from that class. The most important lesson was that I still had a very long way to go to be a good speaker.

All this went through my mind as I strode to the podium on Tuesday. I took a deep breath before starting. I could feel my voice shaking when I began to speak, but I remained calm and got into the rhythm of it. I had a problem with timing. The speech was supposed to be 4-6 minutes long. The red flag went up before I was ready to wrap things up. I didn't prepare enough; I'll have to spend more time on my next effort.

The club had an invited speaker join us: Douglas C. Comstock. He won the speech and tall tales contests at a recent regional competition, and he was gracious enough to come in and give his prize winning speech to us. I was knocked out by his skill. This is a man who knows how to imagine, prepare, and present a topic. He even had an encore: he had prepared a second speech for possible presentation in the next round, and he asked us to give him feedback on it. It was an emotional talk about the death of a beloved brother-in-law that had me choking up as I listened.

I was amazed by the feedback that the club gave. Even someone as talented as Doug Comstock was soliciting and receiving excellent comments. The suggestions were not fan boy fawning, either. Praise and encouragement were mixed in with points that were objective and pointed.

I got some great feedback from my reviewer. I have a very long way to go to become Doug Comstock. But I'm already thinking about a second speech. I sent an e-mail to the club president to ask how frequently people make speeches. Would I be hogging the podium if I gave four speeches this year? He said I should go for it. I'm going to start writing that second speech soon. I'd love to get 4-6 under my belt this year.

I'd like to ask Doug some questions. How often does he speak? Does he do this for a living or a hobby? What is the inspiration for his speeches? How does he prepare? He provided an e-mail address. Perhaps I'll send those questions along and see how he responds.

Saturday, April 19, 2008

A Pain In The Neck



I love to swim. It's been my primary form of exercise for my entire adult life. However, I learned late. I was terrified of being in water over my head when I was a kid. I was skinny, and the water always seemed too cold. I missed out on proper coaching, training, and competing.

After my junior year in college, at the tender age of 21, I was dumped by the woman I was seeing during the school year. I was home for the summer at my parents' house with little to do except go to work every day. I had dedicated my life to playing basketball during my teen years, but the hours of practice couldn't make up for the lack of height, hops, and skill. I would go running every night after work, but I noticed that my ankles and knees would hurt after long runs. I didn't think it would be a good idea to be running every day when I was old, like thirty. So I cast about for an exercise alternative that would be easier on my poor joints.

I decided to learn how to swim. The instructors at the YWCA were patient and did their best. I continued to work on being comfortable with going up and down doing freestyle, but my poor form necessitated a breathless stop at the end of each length where I'd hang onto the gutter for dear life and pant until the burning stopped in my lungs.

After graduation, I found a job and an apartment complex that had an indoor pool. It was a bathtub, not even 25 yards long, but it gave me the chance to practice my awful freestyle every day. I had a conversation about my difficulties with a friend who said "If you can do ten laps straight without stopping you should be able to do a mile." I took that advice to heart. I went home that night and tried it. He was right! I was hooked.

Somehow I've managed to work swimming into my daily routine. I'd put in my dutiful mile of freestyle every day at lunch. I learned how to do flip turns. I even learned how to do butterfly after I finished grad school. I started swimming with a Masters group eight years ago. Anyone who has been a competitive swimmer is better than I am. Winning high school times that I see in the newspaper are half mine in every distance and every stroke. I'm still glad to be in the water.

Fast forward to my 50th birthday. I'm in the midst of my best swimming year ever. I'm swimming before work in the morning and with my Masters buddies twice a week. The yards are piling up. I feel great! I tell myself that swimming is the best exercise there is, that I don't need anything else. I don't stretch; I don't lift weights; I don't cross-train. There's only swimming, and it's kept me fit for my entire adult life.

I woke up on 4-Mar-2007 with a stabbing, blinding pain in my neck. I iced it and took ibuprofen, but the pain only got worse. I called my doctor, who gave me some strong pain medication and sent me over to a chiropractor. The chiropractor recommended traction twice a day with an over the door traction device. But the pain progressed to the point where I couldn't bend over to put on socks. I had to stay home from work for two days, lying in bed.

Finally I had an x-ray and an MRI done. When my doctor sent me over for the MRI, he said that I should try to get an appointment with a spinal specialist now, because it would take a month for him to squeeze me in. He called me when the MRI result came back and said I had an appointment with the specialist the next day. The disk between my C6 and C7 vertebrae was bulging into my spinal cord.

I was worried when I heard that. It must have been serious if they had to rush me in so quickly. Could it be reversed? Could I end up paralyzed or permanently disabled in some way? Would I ever swim again?

The spinal specialist decided to take the conservative route. He didn't want to do surgery or cortisone shots. He prescribed a pneumatic traction device and twice-weekly physical therapy sessions. "I think you'll heal", he said.

When things were at their worst I turned to the Internet for research and comfort. I Googled for "swim c6 disk" to see if anybody else had ever written about a successful return to the pool after an injury like this. There were a couple of entries on swim forums, but not enough information to be sure. I had no idea how long it would take.

I didn't swim at all for the rest of March; April's yardage total was a big goose egg. When I slid back into a pool again on 11-May I couldn't turn my head to breathe and my right arm was still experiencing numbness and pain. I put on a pair of flippers and kicked on my back for 1000 yards. I found that backstroke wasn't too painful, so I started mixing that in with my kicking.

I ordered a snorkel from Finis that arrived in June. I could do some freestyle without turning my head to breathe. I continued with physical therapy until the end of July. Soon I was able to do freestyle again, turning my head to either side, without the snorkel. I worked my way back to being able to do butterfly and individual medley. I went back to my first Masters workout at the end of August and became a regular fixture again.

I still wasn't out of the woods. I was back in the pool, but the pain and stiffness were still there. I started taking a once-a-week yoga class in September. That made a big difference indeed. I would do an hour's worth at home several times a week to supplement the class. I found that my core strength and flexibility were both much improved.

The fourth quarter of 2007 and first quarter of 2008 have seen the best swimming yardage totals of my life. I keep track of how often and how far I swim so I can gauge how I'm doing. The pain has subsided as the yards piled up. The best indicator of my recovery comes when I sneeze. Last year I would experience searing pain whenever I sneezed or coughed. Now I'm myself again.

The time from first pain to recovery has been 13.5 months. The spinal specialist said something to me that I thought was funny: "All the traction, all the exercises, all the physical therapy is really just a way to take your mind off it. The one thing that heals this kind of injury is time."

I read that this is a common injury for men my age, and 70-80% of them recover fully. There were a lot of nights when I feared that I'd fall into the 20-30% of men who couldn't come back from this. I wanted so badly to find stories from people who were in my situation, who could tell me that it would be all right.

So if your neck hurts, your arm is numb down to the elbow, you can't lie down for a full night's sleep because of the pain, and you're wondering if you'll ever see the end of it, take heart. I'm feeling great now, and so can you.

Sunday, April 13, 2008

About My Blog Title

I've had two careers in my life. My education and 16 years of my working life were in the field of mechanical engineering. One of the best courses I took in graduate school had to do with fracture mechanics. One of the topics it deals with is predicting the likelihood of brittle fracture and growth of small cracks into larger ones. You'll see the term "crack propagation" in papers on the subject.

My father was born in Ireland and emigrated to America when he was a young man. He came here in search of better economic opportunities. He found that and more: he met my mother, married her, and had a raft of kids. He became a US citizen. He thought he'd reached the Promised Land. He had little to look forward to in Ireland at the time. He didn't want to be a farmer.

Now Ireland has become the Celtic Tiger of the EU. The population is young, educated, and staying home to work in high-tech industries that have sprung up. I was lucky enough to go back a few years ago and see the town where my father grew up.

One thing I learned while I was there was the Irish slang for conversation: "craic", pronounced like "crack". "Having a craic" means sitting around with your friends and having a lively discussion.

So the title of my blog is an attempt to be clever and pay homage to my former profession and my father's homeland.