IN JANUARY 2009, when Barack Obama was inaugurated as the first black president of the United States, hopes of Americans and Europeans were high that he would make a greater U.S. commitment to Afghanistan in terms of money, troops, economic development, and state building — and above all, to finding a political solution to end the war. Obama’s promise to do all of that, and his expressed desire for a regional solution that would bring Afghanistan’s neighbors together in order to help the peace process, were even more welcome.

Obama did commit more of everything to Afghanistan, and many fields (such as education, health, media, the building of a new Afghan Army, and the degrading of Al Qaeda) have seen substantial improvements. However, the country has also seen a steady deterioration at almost every level — military, political, economic, and human. Violence has increased substantially, and the Taliban insurgency is now a nationwide movement. Tragically, as the endgame approaches, the administration still lacks a political strategy: the U.S. military and intelligence are in the driver’s seat. The United States and NATO now plan to leave by 2014. The administration makes statements about Western forces transitioning and about handing over authority to the Afghan government and army, but it offers no clarity about how that can be accomplished in the midst of a civil war.

The escalation of the war has helped prolong and deepen an already-long-running crisis in Pakistan. Its political and military leadership has shown neither the courage nor the will nor the intelligence to carry out major reforms in the country’s foreign and economic policies. The Pakistani state still fosters many extremist jihadi fighters belonging to various groups, even as the Pakistani Taliban directly threatens that very state. The military has allowed the Afghan Taliban factions and their leaders safe sanctuary and support ever since 2001 — something the Americans knew well but failed to raise effectively. Social services are near collapse, law enforcement is abysmal, economic hardship is widespread, natural disasters occur with little or no government assistance, and the majority of the population has no security.

Undeniably, the military and political situation in both Afghanistan and Pakistan has deteriorated considerably during Obama’s tenure in office. Moreover, for two years, the critical U.S.-Pakistan relationship has been in a steady process of breakdown or deterioration. Obama and his senior officials share a major part of the blame because their failure to act as a team has resulted in contradictory policies, intense political infighting, and uncertainty about U.S. aims and objectives in the region. Regional players have been allowed to manipulate these very contradictions. The legacies of the cold war and the war on terror are still with us. Against the backdrop of an American and European recession, we are still trying to wipe clean those historical legacies so that we can get on with improving our world.

China and India are making huge economic advances, the Muslim world has seen the upswing known as the Arab Spring, struggles for democracy are occurring in countries that have hitherto known nothing but dictatorship, and women worldwide have made enormous strides. Sadly, such progress made has not been duplicated in South and Central Asia. This vital part of the world, the birthplace of Al Qaeda, remains beset by extremist groups and nuclear weapons. Yet Afghanistan and Pakistan have a greater impact on the world’s stability than any other place on earth. We ignore efforts to forge peace and stability there at our peril.

This is my third book on the wars in Afghanistan, and on political developments in Pakistan and Central Asia, framed by the U.S. administrations that have tried to tackle these issues. For three decades, I have traveled, reported, written, and spoken about the wars and political events I have witnessed. During those 30 years, I have spent an inordinate amount of time trying to help politicians and diplomats find a solution to Afghanistan.

I have spent much of my adult life writing this trilogy. The first book, Taliban, covers the Afghanistan of the 1980s and 1990s and the rise of the Taliban and Al Qaeda, seen through the eyes of one of the few reporters on the ground there. It is very much a reporter’s notebook. My second book, Descent into Chaos, is an attempt at a comprehensive history of the first eight years after September 11, 2001, during which the United States went to war in Afghanistan, and Pakistan became a reluctant partner. It covers the presidency of George Bush and looks at events from the different perspectives of Pakistan, Afghanistan, and Central Asia.

This third book, Pakistan on the Brink, is neither a reporter’s notebook, a historical epic, nor a comprehensive history. It describes selected events during the first term of the Obama presidency; the focus is on the current crisis and on the solutions that are needed to ensure a future peace. It resembles a book of essays, each dealing with a different aspect of the same problem, discussing the processes that have led to the present impasse. As such, it can be opened anywhere, and any chapter can be read separately from the rest.

All parties to the conflict in Afghanistan and to the deterioration in Pakistan have made terrible mistakes. Almost all the major players have shown arrogance, hubris, rigidity, and stubbornness; all have, to some degree, lived in the past and been unable to change their thinking. As an observer of these events, however, I have also found this period to be a time of exhilaration and hope. No one who has covered the never-ending Afghanistan wars, as I have, can expect to be an optimist, but I am constantly looking for that open window and hoping it will stay open long enough for peace to emerge.

I hope younger readers will one day read my trilogy as a single document that covers a terrible period of mankind’s history, from which crucial lessons were learned that made it impossible to repeat such death and destruction. Even though the same miseries have been inflicted on the same people, only in different eras under different masters, I believe fervently that we do learn from our mistakes, and that is where hope lies.