# Estimating screen visibility at a conference

Idea: Assume that an attendee located front and center at a conference would have better visibility than someone sitting on the side in the last row. For two different conferences having two attendees sitting at different distances and angles relative to the screen centers, determine who enjoys best screen visibility per unit ticket price relative to venue rent price per unit area for that day.

```from math import cos, radians def score(screen_area, distance_from_screen, angle_relative_to_screen_center, conf_seat_ticket_price, daily_venue_rent_per_area): return screen_area / ((distance_from_screen / cos(radians(angle_relative_to_screen_center)))**2 * (conf_seat_ticket_price / daily_venue_rent_per_area)) # Conference 1 conf1_screen_width_m, conf1_screen_height_m = 6, 4 conf1_venue_width_m, conf1_venue_depth_m = 12, 18 conf1_attendee_rows = 8 conf1_attendee_seats_per_row = 40 conf1_venue_day_rent_dollars = 4200 conf1_screen_area_m2 = conf1_screen_width_m * conf1_screen_height_m conf1_venue_area_m2 = conf1_venue_width_m * conf1_venue_depth_m conf1_total_attendees = conf1_attendee_rows * conf1_attendee_seats_per_row conf1_attendee_rows_distances = [4+i for i in range(conf1_attendee_rows)] # 1m distance between rows starting at 4m conf1_venue_rent_per_area = conf1_venue_day_rent_dollars / conf1_venue_area_m2 # Conference 2 conf2_screen_width_m, conf2_screen_height_m = 3.2, 2.4 conf2_venue_width_m, conf2_venue_depth_m = 8, 11 conf2_attendee_rows = 6 conf2_attendee_seats_per_row = 30 conf2_venue_day_rent_dollars = 2300 conf2_screen_area_m2 = conf2_screen_width_m * conf2_screen_height_m conf2_venue_area_m2 = conf2_venue_width_m * conf2_venue_depth_m conf2_total_attendees = conf2_attendee_rows * conf2_attendee_seats_per_row conf2_attendee_rows_distances = [2.5+i*0.7 for i in range(conf1_attendee_rows)] # 70cm distance between rows, starting at 2.5m conf2_venue_rent_per_area = conf2_venue_day_rent_dollars / conf2_venue_area_m2 # Attendee 1 at conference 1 conf1_attendee1_row = 3 conf1_attendee1_distance = conf1_attendee_rows_distances[conf1_attendee1_row-1] conf1_attendee1_viewing_angle = 47 # relative to screen center conf1_attendee1_ticket_price_dollar = 300 # Attendee 2 at conference 1 conf1_attendee2_row = 7 conf1_attendee2_distance = conf1_attendee_rows_distances[conf1_attendee2_row-1] conf1_attendee2_viewing_angle = 10 conf1_attendee2_ticket_price_dollar = 180 # Attendee 1 at conference 2 conf2_attendee1_row = 2 conf2_attendee1_distance = conf2_attendee_rows_distances[conf2_attendee1_row-1] conf2_attendee1_viewing_angle = 15 conf2_attendee1_ticket_price_dollar = 160 # Attendee 2 at conference 2 conf2_attendee2_row = 6 conf2_attendee2_distance = conf2_attendee_rows_distances[conf2_attendee2_row-1] conf2_attendee2_viewing_angle = 32 conf2_attendee2_ticket_price_dollar = 80 print(""" Visibilities: Attendee 1 (conf 1): %.6f Attendee 2 (conf 1): %.6f Attendee 1 (conf 2): %.6f Attendee 2 (conf 2): %.6f """ % ( score( conf1_screen_area_m2, conf1_attendee1_distance, conf1_attendee1_viewing_angle, conf1_attendee1_ticket_price_dollar, conf1_venue_rent_per_area ), score( conf1_screen_area_m2, conf1_attendee2_distance, conf1_attendee2_viewing_angle, conf1_attendee2_ticket_price_dollar, conf1_venue_rent_per_area ), score( conf2_screen_area_m2, conf2_attendee1_distance, conf2_attendee1_viewing_angle, conf2_attendee1_ticket_price_dollar, conf2_venue_rent_per_area ), score( conf2_screen_area_m2, conf2_attendee2_distance, conf2_attendee2_viewing_angle, conf2_attendee2_ticket_price_dollar, conf2_venue_rent_per_area ) )) """ Visibilities: Attendee 1 (conf 1): 0.020098 Attendee 2 (conf 1): 0.025144 Attendee 1 (conf 2): 0.114307 Attendee 2 (conf 2): 0.050125 """```

The first attendee at the second conference, sitting at the second row, at distance 3.2m and viewing angle of 15° enjoys the best visibility terms.