Michael Phelps' past and present converged at the Rio Olympics in a last explosion of gold for a swimming icon who showed he is more than a "medal machine".
After amassing 22 medals, 18 of them gold, in four prior campaigns, Phelps delivered an epic ending to his Olympic saga in Rio de Janeiro, powering to five gold medals and one silver in seven days.
He leaves Rio with 28 medals to his name, 23 of them gold. No other athlete in any sport comes close.
In a departure from Games past, Phelps' fifth Olympics offered a glimpse not only of a sporting great relentless in pursuit of success but also of a man buoyed by warm relationships heading purposefully into a post-swimming life.
That was not a picture presented before by Phelps, not as a young striver in his first Olympics at 15 in Sydney in 2000, not in Athens in 2004 where he arrived working his way up into the heavyweights alongside Ian Thorpe and Pieter van den Hoogenband.
It certainly wasn't the Phelps of 2008 in Beijing, when the unprecedented achievement of eight gold medals at a single Games required an isolating determination and focus.
London 2012 was supposed to provide the fond farewell. And it wasn't until after the fact that Phelps lifted the curtain to reveal the anger and unhappiness of those Games, when he wanted nothing more than to be done with swimming.
Despite four gold medals and two silvers, Phelps was "haunted" by knowing he failed to prepare as he could have and particularly stung by the loss of the 200m butterfly title he surrendered to Chad le Clos.
Phelps said he had felt himself "starting to crack" with emotion as he went to the Rio pool Saturday where he played a decisive role in his final relay victory.
"This is how I wanted to finish my career. I've lived a dream come true. Being able to cap it off with these Games is just the perfect way to finish," said the 31-year-old.
Rio, according Phelps' coach of 20 years Bob Bowman, was the swimmer's chance to fashion the ending he deserved.
"He mentions it all the time that he wants to go out on his own terms -- on good terms, not 'Let's get out of here,'" Bowman said.
But a comeback launched in 2014 ground to a halt within months when Phelps' personal demons caught up with him in a Maryland tunnel. He was clocked driving 84mph (135 Km/h) in a 45mph zone while under the influence of alcohol.
The incident launched Phelps on a "brutal" personal journey that included a stay at a facility specializing in personal trauma and addiction treatment.
There Phelps, who after his parents' divorce was brought up by his mother, Debbie, reconnected with his estranged father.
That renewed relationship has taken on even greater resonance since Phelps became a father. Fiancee Nicole Johnson gave birth to their son, Boomer, in May.
Johnson and Boomer were front and center in Rio, Phelps sealing the celebration of his longed for 200m fly victory with a tender kiss for the baby boy as the Olympic crowd roared.
It was the kind of expansive public demonstration the old Phelps rarely allowed himself, just as the old Phelps wouldn't have let himself get too emotional on the 200m medley medal stand, knowing he had a 100m butterfly semi coming up.
"That was nice to see, actually," said Bowman, adding that in the past he would have counseled Phelps not to bask in the moment but to "build the fire up in you while you're hearing the national anthem".
"He's usually like a machine on those," Bowman said, invoking a word often used in connection with Phelps.
Bowman has called Phelps a "motivation machine" spurred to action by the slightest snub, and the sheer number of his triumphs have earned him the reputation of a "medal machine".
Bowman, however, said each one of those golds was the product of sweat and stress.
"Every one of those was hard," Bowman said. "Maybe the very first one was the easiest one. After that they've all been super-hard."
Bowman, who first detected the determination he cites as Phelps's greatest asset when he began coaching the 11-year-old swimmer, has lived through some stormy times with Phelps. He watched as Phelps fought through youthful scandals including his first drink-driving charge at 19 and a tabloid ruckus over a picture of Phelps with a marijuana pipe in 2009.
Their relationship hit rock bottom as London approached, but Bowman said Phelps in Rio is really changed.
Phelps soaked up aspects of the Olympic experience he previously ignored -- serving as a captain on the US team for the first time, carrying the US flag at the opening ceremony he had never before attended.
Then he dived in and did what Michael Phelps does, helping the US to gold in the 4x100m and 4x200m freestyle relays, avenging his 2012 200m fly loss to le Clos and notching his fourth straight 200m individual medley title.
Even his lone silver -- to Singapore sensation Joseph Schooling in the 100m fly -- carried a whiff of the extraordinary: it was a rare three-way tie with le Clos and Phelps's longtime Hungarian rival Laszlo Cseh.
"I think he wants to wrap it up knowing that he gave everything and prepared well did it the right way," Bowman said. "And he loves it."
His success in the pool -- far from assured when the Games began, begs the question, "how do you not come back?"
"I just don't see it happening," Bowman said. "I think he's in such a good place personally he doesn't need it.
"I think he's got a lot to do, I think he has a plan for what he's going to do with his life, and he's just in a good place."
(For more sports news and updates, follow Ahram Online Sports on Twitter at @AO_Sports and on Facebook at AhramOnlineSports.)