Andy Murray, shown at last year’s French Open, has not played since July. (Christian Hartmann/Reuters)

There is at least one upside to the hip injury that has kept Andy Murray off the tennis court since July: The Scot has more flexibility with his schedule for the rest of 2018.

The former world No. 1 simply wants to play as many matches as possible when he makes his return, anticipated for June, after undergoing surgery on his right hip in early January. At the same time, the injury layoff has caused his ranking to dip low enough that he will have fewer tournaments he is required to play. That gives him the freedom to play in the places he likes best — including Washington.

On Saturday, tournament officials announced the three-time Grand Slam winner will return to Rock Creek Park Tennis Center to play the Citi Open for the third time in his career. This year’s event, which will be Murray’s first trip to Washington since he lost his opening-round match here in 2015, will run July 28 to Aug. 5.

“I enjoyed it both the two times that I played,” Murray said in a telephone interview Friday. “I was pretty young the first time. I had a good run there. This year has been difficult with injury, and obviously I’ve been trying to play matches once I come back. It’s a nice tournament, good conditions, nice and warm, and the players get looked after very, very well there. I like it, even though it didn’t go well the last time I was there. Me and my team had a good time there and wanted to come back.”

Murray, who held the No. 1 ranking for 41 weeks in 2017 but has since slipped to No. 29, joins a solid Citi Open field that is scheduled to include defending U.S. Open champion Sloane Stephens, ranked ninth in the world, and defending Australian Open champion Caroline Wozniacki, ranked second, on the women’s side and a trio of top-10 ranked players on the men’s side. No. 8 Kevin Anderson, No. 9 John Isner and No. 10 David Goffin all have committed to play, in addition to 2015 champion Kei Nishikori and doubles specialists Bob and Mike Bryan.

“We are thrilled and honored to have Andy return to D.C. as we celebrate a milestone anniversary,” Donald Dell, Citi Open chairman and co-founder, said in a statement. “The 50th edition of the Tournament will be greatly enriched by Andy’s competitiveness, and what a privilege it is for our fans to watch him in action.”

Murray first played in Washington as a 19-year-old in 2006 when he lost to Frenchman Arnaud Clement in the final of what was then called the Legg Mason Classic.

This year, he’s planning to make his return at a tournament in June in the Netherlands at the start of the grass-court season. He said he will not play the French Open even though his name appears on the entry list.

The Citi Open will serve as a tuneup before the U.S. Open, which will start Aug. 27. The timing of the two tournaments was another factor Murray considered when drawing up his schedule.

“We chatted about maybe playing a couple of tournaments there start of the summer, then maybe not playing as much as close to the U.S. Open,” Murray said. “We kind of look at different things that worked in the past . . . I can be a little bit more flexible.”

The 30-year-old father of two spoke Friday about his eagerness to return to the court after more than nine months away — by far the most time he has missed in his career. A back surgery in 2013 waylaid him for less than four months, most of which was during the offseason.

“This time’s been harder. . . . There’s been a lot more ups and downs this time,” Murray said. “It’s been a longer and lot more complex than the back issue. Having been through a back injury and a difficult surgery before helps, but the back injury was easier because I was back on the court competing quite soon afterwards.”

Murray yearns for that competition again, though he’s approaching the rest of the 2018 season with some perspective. He wants to play matches and tournaments without rankings goals in mind, do what’s best for his body and set himself up for the deepest runs possible at Wimbledon, which he has won twice, and the U.S. Open, where he won his first Grand Slam title in 2012.

“I’ll enjoy it more. I think when you go through an injury like this you realize how much you miss playing, how important it is to you. I like pressure. I miss that, something that you don’t get in day-to-day life, something that I’ve had as part of my life for, well, it’s been 13, 14 years since I became a pro. I miss that. I miss the competition,” Murray said.

“There will always be pressure there, but I’ll definitely make sure I enjoy it more and make sure I don’t get too down with a bad result or a tough loss and not get too high when things are going well. Because you never quite know what’s around the corner. . . . I certainly never anticipated something like this. So I certainly won’t take anything for granted when I come back.”