Gary Gutting has an interesting opinion piece where he argues that the Bishops don't have the right to define the teachings of the Catholic Church for the purposes of American political discussion, because most American Catholics disagree with them on matters like contraception.
Imagine the Tall Persons' Club, where by well-established and generations-old tradition, the executive council is made up of the three tallest members, and the president is the tallest member. I voluntarily join the Tall Persons' Club, because I love many of its traditionally established activities, such as the annual cleaning of the giraffe enclosure in the local zoo, the discounted tickets to basketball games and the spectacular fireworks on Robert Pershing Wadlow's birthday.
However, I believe that the governing structure is an unfortunate one, because I think (a) height does not correlate with intelligence, (b) a focus on absolute rather than group-relative height is unfair to some ethnic groups, and (c) we should also do more for ostrich conservation than the present leadership does. Moreover, many members are with me on this. But nonetheless, by voluntarily joining the club, I have given its three tallest members a certain right to speak on my behalf on club-related matters. This is particularly true if there are other clubs that engage in similar activities but have a governing structure closer to what I like.
There are a number of important disanalogies, of course. For instance, one might believe that membership in the Catholic Church is necessary for eternal salvation. If one believes that, then one will have a very serious reason to be a member of the Church no matter how much one disagrees with the Magisterium, and the voluntariness that was essential to my story about the Tall Persons' Club is decreased. However, I don't know of any Catholics who disagree with the Magisterium on contraception who think that membership in the Catholic Church is necessary for salvation.
Another disanalogy is that many people become members of the Catholic Church not by their own choice, but by infant baptism (which, as I think Augustine notes, emphasizes that salvation is not by works). However, given a pluralistic society like ours, they are at least typically remaining in the Church voluntarily.
What counts as "the opinion of a group" is a really tough question. But it certainly isn't determined by looking at what the majority believe. For instance, it is false to say that it is the opinion of the Music Department that the earth goes around the sun, though no doubt that is the opinion of the majority of the members of the Music Department. It is not the opinion of the Music Department because the Music Department has not come to this view by the established methods for forming a corporate view of a matter proper to the Music Department. So majority opinion is not a sufficient condition for group opinion. Nor is it a necessary condition for something to be the opinion of a group that the majority believe it, even in the case of an institution whose traditional governance is by simple majority vote. A group can come up with a joint compromise proposition, approved by a majority vote, where in fact no one individual in the group endorses the proposition in its entirety (whether it is ever morally licit to vote in favor of a group resolution to endorse a proposition one takes to be false is a different question).
(Also, the following rather interesting thing can happen in a group. There may be two groups with the same or almost the same membership but with different governance structures, and opinions, preferences and decisions will then be differently attributable to the two groups. For instance, there may be the Music Department as an academic department and the Music Department as a social group. Perhaps the Music Department as a social group likes a particular brand of beer, but that preference is not of the Music Department as an academic group unless they vote for it in a Department meeting. It could be that there is the Tall Persons' Club as such and the Tall Persons' Club as a majority-governed group of individuals. We should then say that ostrich protection is a goal of the second group but not of the first.)
Furthermore, those of us who at least in principle like the idea of constitutional democracies (or monarchies, for that matter--I am Canadian, after all) should not say that the authority of a group derives from synchronic endorsement by the members. For it is a crucial feature (and very important for protecting minorities) of a constitutional system that it persists in authority even when at a particular time the majority fail to respect that authority (in this way, it is like marriage; one also thinks of Ulysses tied to the mast). The military oath in the United States is, importantly, an oath to protect the Constitution, not the present preferences and choices of the American people.
But I am out of my depth in the social/political philosophy stuff.