Where are you?

Dec 08, 2007 08:58

"Would you be interested in coming along to one of our get-togethers? They're quite fun, we have a few drinks, and chat about philosophy"

"No, I don't think so."

"Really? You're not interested in philosophy? You don't enjoy a debate?"

"No"

"Oh well, never mind then"

Actually, I am no less interested in philosophy than in any other topic, I just knew that the vast majority of amateur discussions about it end up actually being about belief, which is a totally different thing.

Anyway, I had my own philosophical problem to deal with, prompted by the (apparently trivial) need to provide a location string lookup for the positions reported by our little black boxes. These devices, being fairly stupid, just send us latitudes and longitudes periodically to tell us where they are, which we have to convert into something more interpretable before we show it to people. And therein lay the nub of the problem I was struggling with, how actually do you describe where something is?

Obviously no-one else thinks this is a difficult thing to do, since it has only been allocated three man days of effort on our Development Plan. If truth be told, I didn't think it would be very difficult either, since I was the person who foolishly allocated this unreasonably small amount of resource to it. After all, it must surely just be a question of seeing which town, or road, you're closest to, and printing that out.

In practice, though, when you really start analysing what it is you are trying to do, the matter becomes a great deal more complex. For a start, in order to describe where something is, you need to select some other set of things against which you are comparing it. It is not as if you are just replacing one way of showing a location (in this case, coordinates in a precisely-defined spherical frame of reference) with another, you are actually adding a whole new subjective dimension to the problem. Essentially you are arbitrarily choosing some target class of spatially fixed objects, with whose locations you are assuming the user is familiar, and describing how your subject location correlates with one or more instances of this type of entity.

For example, I could choose the class of 'large towns' and find the closest one. This would be no use to someone who just pottered around delivering milk in Dorset, though, since it would always just say 'you are in Bournemouth', since that is the only large town in Dorset. I could enhance the description to say 'you are 10.3 miles north-west of the center of Bournemouth', or 'you are 2.3 miles west of the center of Bournemouth', but that wouldn't really be very useful either. Alternatively, I could widen my search to include small villages as well, but then that wouldn't suit a sales rep, who spends his time traveling the length and breadth of the country, since his journey log would say 'You traveled from Upper Minety to Pokes Bottom, via Langley Moor, Cowplain and Tarring'. "Where are these places?" he would ask, irritatedly.

In truth, he probably doesn't want to know what towns or villages he passed by as he was zipping along the motorway. He wants to see what road he was on, and which junctions he turned off at. "You took the M4 westbound to Swindon, then turned off at junction 15 onto the A346 southbound". So now we need to choose different classes of thing depending on what he was doing at the time. Also, in his mind what he actually did was drive from his house to visit ACME Engineering Ltd, and that is how he would like to see his journey described. 'You left your house, drove along Nightingale Road to join the M4, turned off at junction 15 onto the A346, and then arrived at ACME Engineering in Stitchcombe, just outside Marlborough in Wiltshire'. We now have eight different classes of thing against which we have to compare his location, and some these actually have a different set of instances, depending on which object was actually at the position, since everyone's 'home' is different.

In addition, depending on the geometry of the thing, you need to use different rules to decide how close a position is to it. A town might be a point (or more accurately a polygon, being as it is an urban area, and you are either in it, or not in it), whilst a road is a polyline (or, more accurately, a linked set of polylines, arranged in a topological network). It is all very complicated, and we haven't even begun to consider postcodes or zip codes yet. Also, even when you have correctly identified the class of thing you should be comparing against, how do you express your relation to it? 'You are 20 yards south of the M4' is meaningless, even though it might be strictly true, since positions are not always completely accurate, and roads in geographical databases tend to be represented by lines, not corridors.

And, of course, there is the time dimension to consider. Towns do not move very often, but new roads do get built, and postcode areas change. So in theory, you might get a different description of where someone was, depending on when you asked the question. For example, what if someone moves house? Is the description of a journey he made last year from his old house to his prospective new house (which you had confidently labeled as 'traveled from Home to 28 Acacia Avenue, Wisborough') still valid?

If you start thinking about real-time descriptions of where things are, such as someone might be interested in if they were managing a fleet of delivery vehicles, then you have to start bringing in even broader contextual issues of intent and purpose. If you have a van on its way to a customer, then you want to say 'its half an hour away, approaching the turn-off at Stoke'. So now, in order to describe meaningfully where something is, you have to know where it is going. Which brings to mind a very wise observation made by my friend Ashley, who when asked if he was a glass half-full or a glass half-empty person, said "Well, it all depends on whether you are filling the glass, or emptying it".

In essence, then, in order usefully to provide a descriptive label for some position stamp received from a black box in a car, I have decided that I need to know firstly who was in the car at the time, together with how fast they were going, and where they were on their way to, and secondly who is going to be looking at this description, and why. Also, I need to know how good their general knowledge of the area is, so that I can choose a correlating place or thing they will recognize. Furthermore, my description will only be valid for the precise time at which they asked for it.

It is all horribly reminiscent of the 'what is a door' issue I experienced a while back. It is not so much that I am not interested in philosophical debate, I just find that it gives me a headache.

Luckily, since I am in charge of the Development Plan, I have adjusted it slightly. 'Location String Lookup' is now a six man-week activity, and we have employed a contractor specially to investigate the problem. "That sounds simple enough" he said, when we explained it to him.
Previous post Next post
Up