View these frontiers as inconveniences and you won’t be disappointed. But view them for what they are – magical points on the atlas – and the possibilities are boundless.

International borders can be difficult to cross and easy to hate. Lines are long, tempers short, guns plentiful.

Borders mean hassles like paperwork and annoying questions – exactly the sort of nonsense you want to escape when you travel. By their very presence, borders are inconvenient, an obstacle separating where you are from where you want to be.

Borders also hinder. No wonder charitable organisations choose names like Doctors Without Borders, Teachers Without Borders or even Clowns Without Borders. (It’s only a matter of time before we witness the arrival of Cartographers Without Borders.) The implication is that humanitarian impulses observe no limits, especially those imposed by politicians.

Border towns – a certain kind, anyway – can be even worse; they’re rife with naked opportunism. And nowhere is this more true than in the Burmese border town of Tachileik. Snuggled along the Thai border, it’s one giant bazaar, a warren of tiny stalls stretching in every direction and proffering every imaginable ware. From the moment I set foot in the town until I left a few hours later, I was shadowed by a young man with passable English and a disarming smile, determined to sell me pirated DVDs, Louis Vuitton knockoffs and black-market Viagra.

Borders are all of these things, yet it is not the whole story. Borders serve a purpose, and there is pleasure, even beauty, to be found amid the barbed wire and persistent hawkers.

At a very basic level, borders provide contrast. It’s been said that time is nature’s way of ensuring everything doesn’t happen at once. Likewise, borders are mankind’s way of ensuring everything doesn’t happen in the same place. At some boundaries, life on either side stands in stark relief to the other. I felt that most strongly during a visit to Berlin when the city was still divided. After crossing from West to East Berlin (a process that involved as much paperwork and hair-trigger tension as any I’d experienced before or since) I felt as if I’d stepped into not only another country but another world, one rendered entirely in black and white, in sharp contrast to the living colour I’d left behind.

Borders can also serve as a relief valve. At the Wagah border crossing separating Indian and Pakistan, I marvelled as soldiers from both nations angrily stomped and high-stepped, mere metres apart from one another. This daily pantomime of violence, I realised, helps prevent the real thing from breaking out again.

Sometimes borders are almost comical in their arbitrariness. The US-Canadian border bisects the towns of Derby Line, Vermont, and Stanstead, Quebec. The boundary runs directly through a library, which I visited recently. It was great fun browsing science fiction in Canada and then walking a few steps to gaze at self-help in the US. (A line of masking tape on the floor demarcates the boundary.)

Even the renowned sleaziness of some border towns is, in a way, admirable. Such entrepreneurship takes root for sound economic reasons. In a border town, the typically interminable lag between buying low and selling high is compressed, so the resourceful, and the desperate, dive in. Can you blame them? Borders represent cracks in the wall of commerce, and for the desperate, cracks mean opportunities.

There’s something liberating about a good border town, and very liberating about a bad one. Neither here nor there, these interstitial places stand apart from the usual rules that govern the rest of the world. There’s something about their roughness, their raw energy, their perched-on-a-precipice insouciance that I find irresistible.

Yes, borders – boundaries of all kinds – are good and necessary. This holds true for even the most creative among us. No less of a poet than Robert Frost once likened writing free-verse poetry to “playing tennis without a net”. The truth is we crave limits and are lost without them. Research has found that we are at our most creative when faced not with unlimited freedom but, rather, with constraints. In one classic study, psychologist Ronald Finke asked participants to create an art project. Some people were given a wide range of materials, others little. He found that the most creative work was done by those with the fewest choices – that is, with the most constraints.

I imagine those artists who excelled despite these constraints – because of them, in fact – arrived in the studiowith the right attitude. They didn’t fold when faced with an obstacle. Likewise, a good tennis player doesn’t curse the net when she walks onto the court. She works with it, around it, over it, and realises the net makes her a better player. The same, I think, holds true for travellers and borders. View these frontiers as inconveniences or impediments, and you won’t be disappointed. But view them for what they are – magical points on the atlas – and the possibilities are boundless.