Tuesday, October 27, 2009

My Driving Algorithm


So many people speak of driving as an emotional thing. Road Rage, getting angry on the road, "I hate that driver", etc.

I would like to provide an alternative description of the problem. As an engineer, this is right up my alley. I postulate that driving is only emotional because humans are executing the problem. And humans have emotion. It really gets in the way of everything when it comes to driving, because the driving situation is best solved algorithmically and logically. Humans are terrible mechanisms for algorithm implementation, but they tend to be the only thing that society trusts these days for actually doing the driving.

There are several reasons for why humans are still best for driving, but one of the chief among them is their superior ability to adjust and react to new stimuli. If a driving computer were given stimulus that its algorithm didn't comprehend, the most likely result would be, well, a crash.

Another reason behind this is an amazing ability of the human being, a capability that computers still have yet to match. What is this ability? I will succinctly state that it is complex pattern recognition. And a human can do it pretty well. The brain is well connected to the human's high quality input peripherals, and does a great job and recognizing patterns in the inputs from those peripherals.

Is it the peripherals themselves, for example the eyes? Well, no, not really. We have cameras that can match the human eyes as a mechanism. Is it our ears? No, there are microphones much better than a human ear. How about the accelerometers in our ears? No, we have better stuff available for computers. The real advantage is the brain, which can detect patterns that are hard to define and very hard for a computer to detect accurately.

While humans have great I/O features and unsurpassed pattern recognition abilities, we have a few shortfalls. Humans are slower to react. And humans get distracted. This wouldn't be so bad if we were multi-threaded organisms, but we tend to be single-threaded, and our ability to context switch isn't on the order of milliseconds or microseconds like a computer, but more on the order of seconds - if we're lucky. And when we are focused on something else, we think we can drive, but the truth is we become severely impaired, due to the fact that our brain stems, for some strange reason, don't have driving built in. Guess it hasn't been around long enough to have evolved. So driving really has to be an engaging process, involving our brain's higher functions. So cell phones, pretty women on the side of the road, dogs, cats, billboards, smoke, car crashes, all these things tend to distract the mind, and reduce our processing cycles.

So one of the first and most important aspects of a good driving algorithm is focus. The driver must stay focused on the algorithm and the goal. If the driver doesn't do this, then abilities to recognize patterns are lessened and the reaction time is increased. If attention waxes and wanes the driver becomes unpredictable, and this is a bad thing. Another appropriate way to increase reaction time is to look around, and look far enough ahead. I often see drivers that look about 10 feet in front of them and have tunnel vision. The truth is that traffic is an organic thing, and the more you understand about what is going on around you, the safer and more smoothly the organism of traffic will flow.

Okay, so on to the driving algorithm that I use. I have honed this over the years, and it may not be perfect, but it has served me well so far.

Algorithm Goal
- Get from point to A to point B as quickly and efficiently as possible

I don't like being on the road. It is much more comfortable to do everything in life somewhere other than in the car. The car serves one purpose in my opinion, which is to get a person from one place to another. Comfort is a luxury that makes it less painful, but no matter what, I'll always like the couch better than a car seat no matter what kind of car it is. So I have realized I want to minimize my time in the car.

All algorithms have parameters. These parameters help the algorithm to stay in control and provide bounds within which the algorithm operates. While I want to get from point A to point B as quickly and efficiently as possible, there are many requirements I need to follow. Ideally, I would drive straight from one place to another. Unfortunately there are things in between. I need to use roads, obey the law, and do it safely. I have listed below several parameters that influence the driving algorithm. Within these bounds, I go as fast as possible.

Algorithm Parameters

- Safety

Safety is paramount. Injury never served to help get from point A to point B. Accidents slow progress down immensely. So I want to drive in such a way as to avoid colliding with other objects. These means driving as fast as possible while staying comfortably within the limits of what the vehicle can do and how quickly I can react.

- Cost

Running into things costs money. That's another reason I want to avoid it. Also, I want to keep wear and tear on the vehicle and gasoline costs down. So I try to drive smoothly and not really push the car to its limits too much. Often drastic acceleration is pointless when there are cars in the way or the next light will be red. Being aware of the traffic around you and pacing your driving will do well to help keep the car in good shape and save on gas.

- Speed

I drive as fast as I can subject to the other parameters. I accelerate mildly so as to save on costs. But moving at higher speeds is more efficient time and gaswise (except above 65 MPH or so) But I am willing to sacrifice some gas costs to go as fast as allowed on highways.

- The Law

The law is always getting in the way of what I want to do. Like stopping at red lights. I'd be happy to treat some lights like stop signs, especially late at night at small intersections. But I sit there twiddling my thumbs anyway.

- Look ahead and pay attention! Offset the reaction time problem.

You can increase your speed and efficiency dramatically if you look around. I try to minimize distractions. No phones, no texting, no looking at things on the side of the street. Look as far ahead as possible. Plan routes, be engaged. If you have people in the car, try to focus more on driving than the conversation. Especially in the city, on the highway, it is easier to be lax about that because there's less stimuli.

Freeways
- Lane algorithm

I can never figure out what people are thinking on the highway. I have a very simple algorithm that I believe all the world should use, and I am mad that nobody seems to get it.

Stay right except to pass. It is extremely simple! No, really! I go as fast as I can, and stay as far to the right as I can. There is no more efficient way for traffic to flow. I never understand the fools that get on the highway and immediately go to the left lane. Why? They operate under a false assumption that just by virtue of being in the left lane you will get places faster. Well, with so many thinking that way, I tend to do most of my passing on the right these days. Oh, and if you are on a cell phone, get in the right lane, and drive slowly enough not to crash into things. Better yet, save your conversations until later.

Algorithm Inhibitors

There are a lot of things on the road that inhibit the smooth functioning of my driving algorithm. Here are just a few:

- Other cars (this is a big one)

Other cars are nothing but a problem. A big problem. I could always do better on the road if other people just weren't there. I deal with this by going around them as much as possible. But the infamous roadblock inevitably happens regularly. Some mousy driver in the left lane scared or clueless that won't drive past some cell-phone impaired driver in the right lane. The mouse parks in the cell-phone driver's blind spot while enough steel for a skyscraper piles up behind them, all the drivers thinking about how much they'd rather be earning money, or shopping, or spending time with grandma, or be home with the kids. And these strange folks are thinking about, well, I never know. Some people seem to love being on the road. They cruise along at low speeds like they haven't a care in the world, and I always wonder where they are going, or why they find being on the road so much more pleasurable than being at their destination. I haven't figured it out.

- Railroad tracks

Railroad tracks aren't really that big of a problem. Most vehicles can go over them at regular speeds without much of a bump. But this goes back to the cars being in the way part. There are drivers that somehow want to prolong their time on the tracks as much as possible, and slow to a veritable crawl to go over them. I never understand this. They are going to pay more replacing brake pads than they ever will on struts or shocks. Plus I have found the faster you go over them, the less you feel them. Again, just go over them at regular speed, there is no problem with it!

- Intersections

Now I like to save gas like the next guy. But intersections are just big obstacles in my driving algorithm. I do whatever I can to get through them within the bounds of the law. I also like to be courteous to those behind me by accelerating when the car in front of me starts to move. The incredible molasses-like nature of traffic starting up when a light turns green is a perfect example of distraction and the pathetic reaction time of the human brain. Or something. I am sure that at a crowded intersection twice as many cars could get through per cycle if people just moved as soon as they could. It is a most regular occurance for the first car to 1) wait 3-5 seconds after the light changes to start moving, and then to accelerate almost as an afterthought. If the light is backed up and it has taken three cycles to get to the front, this seems to have no effect! I like to think, "There are lots of people behind me, they probably want to get through this light. If I move quickly when it turns green, maybe people will only have to wait through two cycles instead." But few others appear to think this way. The light turns green, and they wait the usual 3-5 seconds. The car behind them eventually wakes up to realize there is 30 feet in front of them and they finally start moving. If you are 6 cars back, you could be waiting a long time.

- Speed Bumps

Speed bumps are around for one reason. Jerks that don't go slowly where they should. So now I have to put wear and tear on my car, go slower around the speedbumps and endure the displeasure of bumping over them. They were recently installed in our neighborhood because 25 MPH was something people just couldn't manage sticking to on the street. So now we have to go 15 or 20 over the speed bumps, speed up in between, etc. All because there are a few people that won't just go slow on their own. I really hate speedbumps. They are a visible sign of a lack of thoughtfulness among a part of society.

- Road Hazards

Well, I am just careful to watch for them, and avoid them. This is one good reason to look ahead and pay attention while driving.

- Weather

All cars have brakes on all four wheels. Truck or not. If there is snow, rain, or ice on the road, all vehicles have about the same chance of stopping. Truck or not. A few other tips. When the road is slick, don't accelerate or brake when turning or changing lanes. This is a big mistake. Accelerating or braking should be ginger and only when going straight.

- Slow turners

Just repeat my rant for slow starters at intersections. Left turn cycles are notoriously short. Get the heck through the light! Also, if you are turning right or left off a road, pull over _before_ slowing down, it is much more curteous.

- Hesitant or fearful or distracted drivers

These types of drivers are a big annoyance. Sometimes they are hesitant or fearful because of an impairment. This may be mental or physical. Impairments are legitimate. I try to just get around these types of folks safely and without being rude to them. Sometimes these drivers are just dumb or distracted, or somehow never learned to drive. Of course, there is never a point in getting angry with them or scaring them or road raging them. They exist, I just to my best to get around them and avoid them.

Distraction's effects on the algorithm. I have noticed that the more distracted I am, the worse I execute the driving algorithm, the longer I take, and the more I annoy other drivers. Also, I am less safe. It is important to focus on driving. The brain can really only focus well on one thing at a time. Multitasking in the car is asking for trouble. I know, because I have tried it and it never works well.

Finally, the big question. Why doesn't everyone have the same algorithm? I have fine tuned it for so long, and I really haven't been able to come up with anything better. It is really simple, and it works. Everyone join in! The Daniel Gowans driving algorithm will make your life better too.

Friday, October 2, 2009

Highway 12 in Southern Utah

This is a little late, but I just had to write a blog entry about this!

Jun 12-15 this year we took a wonderful trip to southern Utah to travel Highway 12. Last time we drove this highway was in the summer of 2007. We drove it back then from Capitol Reef National Park toward Zion's National Park and ended up in St. George to visit family. It was a great trip then, but a little too fast paced.

This time we slowed it down a little bit and traveled from Cedar City onto Highway 12 and toward Capitol Reef. It was a spectacular trip. Some of you in the Western states may remember the wonderful and mild spring and early summer we enjoyed. It was the same in this fairly high country down south, it had been raining and it was cool, beautiful, and green. The air was clear and the clouds were unique and of every sort, not just that boring blue sky. This was perfect hiking and picture taking weather.

This is a gem of a weekend trip that many don't know about, even locals. This is fast on its way to becoming a tradition for us.

We started out by driving down I-15 to Cedar City. We drove up Cedar Canyon, which in and of itself is a very pretty drive, and stopped at Cedar Breaks National Monument. We didn't stay for long, but we visited most of the view points. We spoke some with a neat couple from New Zealand who had rented an RV and were traveling the United States for three months. The wind was really kicking up at the northern viewpoint!


Above is at the lookout while driving up Cedar Canyon. That's my GPS on the sign, I wanted to know how high up we were. Spectacular view! I don't remember what dumb joke I cracked to make Joanna laugh.
Above is from one of the viewpoints in the middle of Cedar Breaks. The drop is a couple thousand feet to the trees below. This is the same rock layer that forms Bryce Canyon, where we spent the next day!


This is a panorama shot I made of the Cedar Breaks amphitheater. As will be the theme throughout this entry, the pictures don't do anything justice!



Here is a picture from the Northern viewpoint looking South into Cedar Breaks. The wind was crazy here! The video below will illustrate what I mean. Note the beautiful clouds. No simple blank blue skies on this trip, but rich and interesting sky layers! Parallax scrolling at its finest.




I am yelling in this video, but sometimes you still can't hear it. Joanna was frozen to the bone in a matter of seconds after stepping to the edge. Me, with a little more natural insulation, only had my ears and hands "severely chilled" by the frigid gusts.

That evening we had a rousing nightlife experience in the city of Panguitch, consisting of an exciting visit to the local pharmacy for some allergy medication. Realizing that was all the action we could get there, we headed out and a little later checked in the the "Bryce Grand" hotel just south of Bryce Canyon. It had just been completed, and like all new construction, was working hard to suck all moisture out of the air and earth around it. Every morning we awoke needing to drink about 10 glasses of water. Otherwise though, the room was great.

But what was even better was Bryce Canyon itself. The weather was absolutely perfect in every way. I mean, PERFECT. I really could just go on and on. High 60s during the day, broken clouds that seemed to offer shade just when we needed it, and a mild breeze. We hiked from Bryce Point through the amphitheater to Sunset point on the Navajo trail. It went up and down and up and down through the hoodoos and canyons. There was significant wildlife and the flora was excellent also due to the recent rains.


Joanna at the Bryce Point lookout. I may belabor this point, but the clouds are rockin'! So are the amazing hoodoos. The amphitheater is so majestic, and as usual, the eye popping beauty is only partially captured in photos.



I like stuff that's pretty.




This tree's roots had been exposed by erosion, or something. It was pretty neat to see the roots snaking down the hillside.



The infamous Gowans flaming arrow from my family. Unfortunately Joanna has put all the native Gowans family folks to shame by excelling at her flaming arrow precision crafted stance.




Since it was spring, there was much new growth on the pine trees. This new growth had this remarkable, velvety feel. Joanna couldn't get enough of it. She would talk to the trees and tell them they were pretty. She was right.



After this fine hike, we thought we would hike the rim back to our car at Bryce Point. We had the option of taking a shuttle, but thought the rim would be prettier, and we had the energy still. As we were leaving Sunset Point on the rim trail, everyone was hurriedly hiking to opposite direction. I saw up ahead some looming dark clouds. I talked to Joanna about how it was probably okay if we got a little wet, we had the gear for it. I thought for a second about all the burned out trees on the rim that have been hit by lightning over the years and said, "We should stay inside of the rim as much as we can, and if you feel your hair standing on end, run or drop or something. But we should be fine." Well, the people were flowing faster and they were looking at us heading toward the stormcloud like we were a little crazy.

The wind was kicking up and I was contemplating heading for cover when I was startled by a lightning strike only about 100 yards away off the rim of the amphitheater. CRASH!!!! about a millisecond later, and Joanna and I might as well have been scared deer at that point. She runs into me and I run into her as we bolt into the forest away from the rim. Seriously, I'm glad I went to the bathroom at Sunset Point or I'd have been in trouble! I have never heard anything so loud in my life! It is really beyond the point where you can decide to be manly or anything, it was pure flight mode.

Almost immediately after the crash, pea and marble sized hail started pelting us. Honestly, it hurt a little bit and we looked for cover under the paltry evergreen trees in the fields west of the trail. They weren't much help. As we were now freestyling over the meadow, too scared to go back to the trail, we scared a group of three deer to death as we rounded a tree and nearly tripped over them. They bounded off hurriedly. I've never run into deer before, so that was interesting. At that point I was finally getting over the adrenaline and we stopped and took this video. The video of course doesn't do it justice. There was constant thunder, the hail was very loud, and I was kind of yelling over it all.





We clomped over the uneven ground toward sunset point and waited it out underneath the eaves of the bathroom building, elbowing a place amongst the other tourists. In moments, the parking lot was a muddy mess and there were piles of hail around the buildings where they'd rolled off the roofs.

We took the shuttle back to Bryce point. Which was just as well because we needed to go to some of the other lookouts further south.

As one proceeds south on the Bryce Canyon drive, the elevation continues to rise. As the end of the road is Yovimpa and Rainbow points. I absolutely love the views from up here, and I got out the tripod and took a few pictures. Joanna and I walked the Bristlecone loop, it is peaceful, and quiet, and it smells good. Here's some photos. The first is a panorama off Rainbow Point I think. But it could have been Yovimpa. One faces North, the other South. I wish I remembered!



This is definitely at Yovimpa looking along the edge of the cliff, and a fine wall to my left.




Joanna's kind 'tree'tment of the trees continued. She liked this one. It was cute. I am sure they are growing better because of her encouraging words. She's all bundled up because the wind was a little much for her. It was colder and windier up there.




I wish I could continue to write about everything is as much detail, but Bryce Canyon was certainly a big highlight! We stayed another night and headed out on Highway 12 the next morning. We stopped at Petrified Forest State Park near Escalante. It was really much more interesting than I expected, and there was a plethora of petrified rock all over the place. We took a small hike around, the weather was great, and seeing the rock was a novel experience. There were also some kind of bug out there that were like crickets on speed, and they made their noises in the daytime, and the sound was nearly deafening! Here are some pics of the petrified wood. It was buried, sometimes above the ground. That last piece had wonderful striations!




This was my attempt at "The Thinker" I should have been looking down, but hey, I like to look to heaven when I think:



We drove the "Burr Trail Scenic Road" later that day. It was so pretty! Very remote also. It heads out of Boulder toward the southern end of Capitol Reef National Park, and goes through a pretty red rock canyon. Just before the canyon was a trailhead that was remote and desolate. Joanna and I parked and walked this crazy trail that seemed to be heading nowhere in particular. I have never felt so much like I was in the wild. The trail was overgrown with large wiry bushes, and there were aspen trees with giant cobwebs the size of mailboxes that had leaves and bugs in them of all kinds, like giant spiders or something were incubating within. We saw Mountain Lion tracks in the wet sand of the little creek that were very fresh (I wish I'd taken a picture of them.) After a while, it was just too unpleasant. Bugs, weird noises, it was like a Halloween trail or something and we got the bejeezuhs. We turned around after about 1/2 mile. Great memory though. I'll have to go back when I am in the mood for a wilderness experience.

We continued on to Capitol Reef National Park. Right at the border the road changes to gravel. We didn't want to get Betsy (our car) really dirty, but I knew about some really crazy switchback roads that went down the east side of the reef where the road crosses it and I just HAD to see them. They were awesome! We didn't drive down them, but some crazy folks in a beat up old Audi went tearing down them while we were looking around at high speed. This picture doesn't do them any justice, but the view from this area was incredible.



We headed up over the mountains toward Torrey, UT- the entrance to the better known area of Capitol Reef. These mountains are amazing, reaching over 10000 feet in this area, and there are a number of breathtaking viewpoints where, on a really clear day (and the air is so clean and clear out here) you can see over 100 miles! Here is a view from the mountains toward the south I think:


A picture of Joanna enjoying the view, and our fine Toyota Camry, "Betsy". Betsy is a good hard working car. And she takes care of us when we are in the middle of nowhere.




We stayed the night there, and the next morning took a hike to the "viewpoint" of the Golden Throne, some giant dome of rock high up in the reef. You can't really get to it, the whole hike is just a beautiful walk along the cliff of a wash up to a fine viewpoint. Joanna didn't get this at first, but it became obvious that we were there just to "look around" when we reached the end of the trail:



Here is the "Golden Throne" itself! Behold:




Joanna found a very nice throne of her own while we were hiking the trail:


So that's a brief overview of our trip! It was so great this time. Definitely on a way to being a tradition. We actually returned to Capitol Reef this fall, but that is a story for another time. If you are ever in Utah and want to go for a great weekender, consider Highway 12!