IRVINE, Calif. (AP) -- Ryan Lochte and Michael Phelps, a couple of Olympic champions on the comeback trail, got a step closer to finding their form.
Lochte beat Phelps to win the 200-meter individual medley at the U.S. national championships Sunday night, leaving Phelps winless in four races at his biggest meet since coming out of retirement.
They weren't in their usual lanes in the center of the pool. Those spots go to the fastest qualifiers.
Lochte was in lane two and Phelps was in lane six. They couldn't see each other either, with Phelps breathing toward the stands and Lochte the other way.
Still, the race came down to the two old rivals, with Phelps chasing Lochte for a change.
Lochte, the world champion, led all the way and touched in 1 minute, 56.50 seconds. He is coming off major knee surgery, and had a setback at a meet in April, all of which limited his time in the water.
''This year has been up and down, but I'm glad I got a win knowing that I really haven't done the work I wanted to,'' he said. ''I always relied on my training, but this year I haven't done that training so my confidence was low.''
Phelps, the three-time Olympic champion in the event, was saying the same thing, although he pronounced himself pleased with his time.
''That's a good spot to be,'' he said after finishing second in 1:56.55. ''I'm a lot happier with finishing like that than having some of the sub-par performances that I've had throughout the final sessions in this meet.''
Lochte's time was second-fastest in the world this year; Phelps' was third-quickest.
''If you go out in that race it's pretty painful in the end,'' Phelps said.
It was Lochte's first victory of the five-day meet after finishing second in the 100 freestyle and third in the 200 backstroke.
''I guess we can say this is kind of our off-year,'' Lochte said of him and Phelps. ''Well, I can say that.''
Four months into his comeback, Phelps came up empty. He finished second in the 100 butterfly, sixth in the 100 back and seventh in the 100 free. But those second places were enough to qualify him for the Pan Pacific Championships this month, where swimmers can compete in any events they want.
''I'd rather lose all the national championships that I swim in as long as I'm ready for the big races,'' he said.
Olympian Tyler Clary was third in 1:57.94.
Lochte and Clary are headed to Australia for Pan Pacs, too.
Lochte took the medals stand in glitzy green high-tops with attachable wings.
''I kind of like the wings,'' he said. ''They're helping me out. I should have worn them all week.''
Anthony Ervin won his first 50 freestyle national title in 13 years, upsetting five-time champion and training partner Nathan Adrian.
''Unexpected,'' Ervin said. ''I still feel like I haven't let that fully sink in.''
Ervin, at 33 the oldest man in the final, won the chaotic sprint in 21.55 seconds, third-quickest in the world. The 2000 Olympic champion in the event raised both tattoo-sleeved arms in triumph.
''I've been doing the no-breath since 2000,'' he said, smiling.
Adrian took second in 21.69, and two-time champion Cullen Jones was third in 21.83.
Simone Manuel won the women's 50 free in 24.56 to go with her second-place finish in the 100 free.
Natalie Coughlin, at 31 the oldest woman competing at nationals, finished sixth. She failed to make her record-tying fifth Pan Pacific team and as a result won't qualify for next year's world championships. That leaves Coughlin out of the two biggest international meets leading up to the 2016 Rio Olympics.
Michael McBroom won the 800 free in 7:49.66.
Melanie Margalis won the 200 individual medley in 2:10.20 to earn a berth at her first major international meet.
Swimming on the far outside in lane eight, Katy Campbell won the 1,500 freestyle in 16:17.59 after world record-holder Katie Ledecky decided not to swim on the meet's final night. Ledecky set a world record in the 400 freestyle on Saturday, giving her world marks in the 400, 800 and 1,500 at the same time.