The structural engineer strides through Kathmandu's old city, past buildings reduced to rubble, buildings whose facades are cracked in dozens of places, like the fractured shell of a hardboiled egg. But it's the many buildings that made it unscathed through the earthquake that amaze Kit Miyamoto.
"It could have been so much worse," said Miyamoto, head of a global earthquake and structural engineering firm, who flew to Nepal soon after he heard about last weekend's 7.8- magnitude quake. He shakes his head, topped by a white hardhat. Before landing, he'd envisioned a flattened moonscape of dust and debris. He thought as many as 40,000 people could be dead.
That the reality has turned out to be far less destructive has a lot to do with the vagaries of geology, geography and construction decisions. Not to mention sheer luck.
The danger, however, may not be over. Dozens of mostly small aftershocks have hit Nepal since the quake. A more powerful aftershock a bit closer to the capital could cause immense damage.
"If a magnitude 6 or 6.5 quake happens within 20 kilometers of Kathmandu, it's going to be a nightmare," said Sandeep Donald Shah, a structural engineer with Miyamoto International, during the walk through Kathmandu. "The probability is pretty high that this may happen because we just had a (huge) earthquake, and the fault line has been activated."
The general state of Kathmandu's buildings—with their ancient soot-and-exhaust-stained concrete, their uneven bricks, their drooping facades and crooked balconies—raises questions about how so many still stand after such a big quake.
Remaining upright depended on a combination of factors, including age, size, building material and strength, location and the underlying soil. But the simplest explanation is that Kathmandu largely sits outside the danger zone of last week's quake.
Because the epicenter was about 80 kilometers (50 miles) from the capital, the quake's power had partially dissipated by the time it got to Kathmandu, said Miyamoto, who is also a seismic safety commissioner for the state of California.
Even so, some of Kathmandu's remaining buildings look "very bad, seismically speaking," with weak foundations and structures, Miyamoto said. They've also been "softened up" by the quake, making them more likely to collapse or be seriously damaged if another, closer quake hits.
The region will likely see aftershocks for another year, including some big ones, Miyamoto said, but it's impossible to predict where or when they will occur. The two biggest aftershocks so far have been more than 60 kilometers (38 miles) from Kathmandu.
A direct or even a near hit on Kathmandu by the April 25 quake would have meant a massive death toll.
The Nepal quake released 16 times the energy of the 2010 Haiti earthquake, where death estimates ranged from 100,000 to 300,000, yet the death toll in Nepal now stands at more than 6,600. This is a huge loss of life, but far less than recent estimates that 100,000 people might die in Nepal's next major earthquake.
Driving through the city, the juxtaposition of what crumbled and what survived is striking.
At some big hotel compounds it's almost as if the quake never happened: honking geese wander over manicured lawns and foreign guests start their days with hot showers before lining up at brimming breakfast buffets, eyes locked on phones connected to Wi-Fi.
Outside the gates, even many of those whose homes weren't ruined slept out in the open for days after the quake because of fears of aftershocks. In some closely packed quarters, there is spectacular damage, with tall buildings leaning against their neighbors like tipped dominoes. Many villages in the countryside, outside the capital, have been virtually flattened.
Generally, the older and bigger the building, the worse off it fared. So the so-called old city, home to many of Kathmandu's precious world heritage buildings, is obliterated in places. All over the city, destroyed brick walls spill into the streets like ocean waves breaking on beaches.
In much of Kathmandu, however, roads are choked with traffic, and businesses have begun to reopen. You can go blocks sometimes without seeing any obvious earthquake damage.
"It's getting back to normal, but ... it still doesn't feel safe," said Prabhu Dutta, a 27-year-old banker in Kathmandu.
He has started sleeping again inside his home, which has some cracks in the walls but is still standing. However, the dozens of aftershocks he has felt since the quake make him uneasy. Many people in Kathmandu have been leaving for the countryside because of fears of a big aftershock.
In the final equation, buildings collapse, or stand, because of the power and length of a quake's shaking.
The strength of the shaking depends on the magnitude of the earthquake, the distance from the epicenter, the depth of the earthquake—shallower quakes do more damage than deeper ones—and the type of soil, according to Susan Cutter, director of the Hazards and Vulnerability Research Institute at the University of South Carolina.
While both the Haiti and Nepal quakes were shallow—10 kilometers (6 miles) deep for Nepal, 13 kilometers (8 miles) for Haiti—the soil in Haiti made the shaking more severe and longer, Cutter said. Port-au-Prince was also much closer to the epicenter than Kathmandu—25 kilometers (15 miles) rather than 80 kilometers (50 miles).
Old or unreinforced masonry normally fares poorly in an earthquake, though much depends on the quality of the materials and the building methods, as well as on building codes and their enforcement. If Nepal is far below most Western nations in terms of construction quality and code enforcement, most experts also believe it is better than Haiti.
Miyamoto, the structural engineer, called the damage in Nepal's capital, and the possibility that aftershocks could cause much more, a wakeup call. The government and outside nations, he said, should begin work to strengthen existing buildings and construct stronger new ones.
But that may prove difficult for Nepal's leaders.
After the quake, as he stood outside a multi-story home where emergency teams were pulling out the body of a 12-year-old girl, Transport Minister Tek Bahadur Garung said that while Nepal does issue building regulations and licenses, there's no monitoring or enforcement.
Officials, he said, were simply overwhelmed.
"In this situation, what to do?" he said. "It's a big problem for our government to solve."
Explore further: Why the Nepalese quake was so destructive