It hasn’t been the best of weeks for Stanford basketball.

On the heels of the Lopez twins declaring for the NBA draft on Monday, former Stanford coach Mike Montgomery headed across the Bay to accept a coaching position at Cal. He was officially sworn in as the Bears’ coach on Saturday.

“I’m sure when I show up next year at Maples (Pavilion), they won’t have the welcome wagon out,” Montgomery told The Almanac in Menlo Park. “But that’s part of the experience . . . You will never get me to say anything bad about Stanford. I love the place. They were great to me, and now I’m here.”

Montgomery, who led the Cardinal to a 393-167 record and 12 NCAA Tournament berths in 18 seasons, had returned to the Farm in September in a part-time position as assistant to Athletic Director Bob Bowlsby. He also did broadcast work for Fox Sports Net, Comcast and CBS radio.

In an interview with The Daily earlier this year, the 61-year-old Montgomery expressed a desire to return to the sidelines. He had been in a state of semi-retirement since August 2006, when he was released as head coach of the NBA’s Golden State Warriors after two seasons and a 68-96 record.

“[T]here’s still a lot of basketball in my blood, just because you do something for that long,” he told The Daily in February. “We’ll have to wait and see if anything develops there . . . You’ve done something for 37 years, and it’s just what you do.”

The winningest coach in school history, Montgomery helped usher in Stanford basketball’s rise to national prominence. He led the Cardinal to four regular season Pac-10 championships, an NCAA Final Four appearance in 1998 and a Pac-10 Tournament title in 2004.