A baseball team plays in a stadium that holds 55,000 spectators. With ticket prices at $10, the average attendance has been 27,000. When ticket prices were lowered to $8, the average attendance rose to 33,000. Find the demand function, assuming that it is linear. How should ticket prices be set so as to maximize revenue?