The Houston Rockets have answered the defection of Ron Artest to the Los Angeles Lakers by quickly reaching an agreement to sign Trevor Ariza away from L.A.

NBA front-office sources told ESPN.com that Ariza made a verbal commitment Tuesday night to sign a five-year deal with the Rockets on Wednesday -- the first day free agents are permitted to sign new contracts -- not long after the Lakers and Artest reached terms on a three-year deal worth an estimated $18 million.

ESPN.com's Chris Sheridan reports that Ariza, according to sources, will receive the Rockets' full mid-level exception, which is being projected to come in at $5.8 million for next season. If the exception for the 2009-10 season is indeed set at $5.8 million Wednesday when the league announces next season's salary cap and luxury tax, Ariza's deal would be worth $33.5 million.

The Rockets shifted their focus away from Orlando Magic restricted free agent Marcin Gortat on Thursday when it became clear that Gortat was on the verge of reaching terms with the Dallas Mavericks and when it became known leaguewide that Ariza was determined to leave his hometown Lakers -- in spite of his vital contributions to L.A.'s championship run -- because they were unwilling to start his new contract higher than the mid-level exception.

Rockets general manager Daryl Morey immediately flew to Las Vegas to recruit Ariza in person and convinced him to join the Rockets over the Cleveland Cavaliers, who had strong interest in both Ariza and Artest and must now keep searching for a small forward on the open market such as Linas Kleiza or Anthony Parker.

The Lakers effectively declared that they preferred to have Artest -- older, physical, more versatile but also famously unpredictable -- at a lower price than the 6-foot-8 Ariza, who reached new levels of reliability as a defender, shooter and glue guy in the postseason. Ariza shot 49.7 percent from the field and 47.6 percent on 3-pointers in the postseason in 31.4 minutes per game, after averaging just 24.4 minutes per game during the regular season.

Marc Stein is a senior NBA writer for ESPN.com.