Virginia Madsen (Sideways) has signed on to star opposite Jim Carrey in New Line Cinema's Joel Schumacher-directed thriller The Number 23. Madsen will play Carrey's wife in the film, which stars Carrey as a man who comes into contact with an obscure book titled "The Number 23." As he reads the book, he becomes increasingly convinced that it is based on his own life. His obsession with the number 23 starts to consume him and he realizes the book forecasts far graver consequences for his life than he could have ever imagined. The film is scheduled to start production this month.

"We've been fans of Virginia Madsen's work for a long time and are thrilled to have her on board," says producer Beau Flynn. "She will really add something special to this film and we are looking forward to seeing the chemistry she develops with Jim Carrey play out on the screen."

The Number 23 is being produced by Flynn and Tripp Vinson of Contrafilm from a screenplay by Fernley Phillips. It is being executive produced by Brooklyn Weaver and overseen for New Line by production executives Richard Brener, Keith Goldberg, and Emmerich.

Best known for her work in Sideways, which earned her an Academy Award nomination for Best Supporting Actress, Madsen can next be seen opposite Harrison Ford in the thriller Firewall which opens next month and in the upcoming Robert Altman-directed A Prairie Home Companion for Picturehouse.