There is a professional line service which provides both offshore books and Las Vegas sportsbooks with the "opening line." It is called Las Vegas Sports Consultants, or commonly LVSC. For many of the people that work there, their entire job is to determine accurate lines from games. They determine these lines by using sophisticated software programs, psychology, injury reports, and other information to determine power rankings. The power rankings tell them what the score should be on a neutral field, and then they take into account the home field advantage, weather, whether the game is at night or during the day, and other information like that.
From there, it gets even more interesting. Let's say the sportsbook receives the LVSC lines and they say Patriots are a 2 point favorite over Indianapolis. Well, the sportsbook knows everybody is going to bet on the Patriots, so why let them do it at -2 points? They'll bet it just the same at 3.5 points. So the books often manipulate the "mathematical" professional lines provided by the LVSC based upon their knowledge of bettors. I believe the line provided by the LVSC for Indianapolis versus the Patriots was 2 points. This turned out to be almost exactly accurate . The books opened the line at 3.5 points, and it was almost immediately bet up to 4.5 points. From there it went as high as 6, before the smart money came in late and brought it back down to 4.5.
I could go on for another long while about the importance of the number 3 in sports betting, but that's a whole different issue.
Sports betting is a very fascinating enterprise :)