Knicks officials have been optimistic all along that Carmelo Anthony eventually would expand his wish list beyond the Rockets. And now he has.

A source confirmed an ESPN report that Anthony has added the Cavaliers and Thunder in hopes of the Knicks finding a deal for him before the Oct. 19 season opener. According to ESPN, the Knicks contacted the Cavaliers on Monday, but no names were discussed. The Post previously reported the Thunder had expressed interest.

The source told The Post that Anthony is heavily considering putting the Trail Blazers on his list as well.

Following the blockbuster trade of Kyrie Irving to the Celtics for Isaiah Thomas, Jae Crowder, Ante Zizic and draft picks, The Post reported the Knicks viewed Cleveland as having more assets to make a deal after the addition of coveted small forward Crowder, a stout defender. But under league rules, Crowder can’t be traded until Oct. 22 — 60 days after the trade that sent him to Cleveland. New Knicks president Steve Mills covets Crowder. The Cavaliers, in the Irving deal, also obtained first-round and second-round picks they can package.

The Knicks also may be interested in bringing back Iman Shumpert, their 2011 first-round pick, who was shuttled out by since-ousted president Phil Jackson. They already retained this summer another of their first-rounders Jackson had given up, Tim Hardaway Jr.

Anthony finally appears to realize the Knicks won’t be able to work out a deal with the Rockets and never really were close on a package, despite his reps lobbying for him to play alongside Chris Paul and James Harden.

The Cavaliers and Knicks talked over the winter about an Anthony deal, but the Knicks wanted Kevin Love and Cleveland was uninterested. LeBron James has wanted Anthony by his side since the start of his second stint in Cleveland, but Anthony was a free agent and it didn’t work logistically. Instead, the Cavs traded for Love, giving up their No. 1 pick, Andrew Wiggins.

Anthony is hoping for a deal before the regular season begins.

For now, the broken marriage limps on. While Knicks general manager Scott Perry said the club is keeping an “open mind” on Anthony’s future, team officials stated he will be at Monday’s training camp. Coach Jeff Hornacek said he’d be “crazy not to start him.”

Sources have told The Post neither Anthony nor the Knicks want each other, but the inevitable divorce has to be postponed for now. Perry revealed he traveled to Florida to meet with him in late July and thinks he’ll be a positive influence on the young core.

The remarks contradict recent blog posts by Mills and Perry, in which Anthony’s name was not mentioned.

“Look, Carmelo’s going to be back here,’’ Perry said in a press conference to ring in Monday’s start of camp. “Carmelo has always been a professional. That’s one thing I’ve always respected about him. I think he can set a good example for the young players. He’s been a 10-time All-Star. If he’s back here with the New York Knicks, we expect him to be the professional he’s always exemplified throughout his career and move forward with him.”

However, Perry admitted nothing is set in stone.

“I think in our position, you always keep an open mind,’’ Perry said. “Part of my job is to help this team get better in any way that we can. So we’re going to continue to do that on a daily basis, whether it’s entertaining calls or obviously internal development is going to be important for us. I really can’t comment any further on it other than my job is to help this team get better in any way that we can, in any of the means that are available to us.”

Perry hasn’t given up hope a solution can be found.

“We said if there was something there that made sense both for him and the Knicks organization, then we would strongly consider it,” Perry said. “Obviously we sit here today and that did not happen as of yet.”

Anthony has hosted his own scrimmages in Manhattan and hasn’t attended the voluntary workouts at Tarrytown.

“In terms of Carmelo, we’re just looking forward to seeing him next week,” Perry said. “I won’t get into all the details of the times we talked and not talked.

“I went down to Florida to visit with Carmelo [in late July]. We had a very good meeting, very respectful. He expressed to me his sentiments, as did I, and we both understood at that time there would definitely be a possibility he could be back here. We respect each other well enough that if that was the case that we’re going to move forward and be the professionals that we both are.”

Mills, who attempted to deal Anthony during the Phil Jackson era last season, added: “I think Carmelo is going to be fine with our team. We all went down and saw Carmelo numerous times this summer. We’ve been in communication with him. So we feel he is going to come into our locker room, we’re going to do everything to bring this team together.”

Hornacek said he never thought Anthony would be dealt and has planned for him to be an integral player.

“Carmelo, all summer long when we were going through this stuff, we had him in mind moving forward,” Hornacek said. “I think the role is not going to change. We’re going to implement certain plays and defensive schemes he’s going to be asked to do, but if you don’t think I’m going to start him, you’re crazy. He’s a great player and still is and he’s going to lend a lot to our team.”

Explaining why he didn’t mention Anthony in his August treatise, Mills said he felt it most appropriate to write about his young core of five that even included Ron Baker.

“When we addressed this group in July, what we were trying to do is demonstrate to our fans what the long-term plan for the Knicks is going to be,” Mills said. “That’s why we focused on the young players because that’s what our future is, and this is the long-term project the three of us are embarking upon. That’s really why the younger players are focused on in the correspondence we have.”