"""
weight_of_new_york.py

Calculates upper and lower bounds for the weight of New York
"""


# from Dennis 
"""
With respect to estimating the weight of NYC, we can approximate a lower bound. With about 8.3 million people in NYC, at an average weight of say, 65 kilos (this is just a guess, to account for men, women, and children), the mass of the people alone will be about 540 million kilos. 

Assume each person owns about 100 kilos worth of stuff (this is probably low-balling it) and that brings our estimate of the lower bound to 1.84 billion kilos, without even taking into account vehicles or buildings.
"""
people_and_stuff_mass = 1.84e11

# from http://www.funtrivia.com/askft/Question65399.html
"""
According to the "ANNUAL REPORT ON THE NYC REAL PROPERTY TAX, Fiscal Year 2006," by the City of New York Department of Finance, p.2 (p.8 in the PDF), the total count of buildings for NYC is roughly 900,000.
"""
num_buildings = 9e5
 
# from http://en.wikipedia.org/wiki/Empire_State_Building
"""
The Empire State Building weighs approximately 370,000 short tons (336,000,000 kg) 
"""
empire_state = 3.36e8

buildings_mass = empire_state * num_buildings

LOWER_BOUND = people_and_stuff_mass + buildings_mass

# from http://science.howstuffworks.com/question30.htm
"""
The measurement of the planet's weight (derived from the gravitational attraction that the Earth has for nearby objects) is 6,000,000,000,000,000,000,000,000 kilograms (6E+24 kilograms / 1.3E+25 pounds). 
"""
earth_mass = 6e24

# from http://amonline.net.au/geoscience/earth/structure.htm
"""
The Earth's crust makes up only 0.5% of its total mass and can be subdivided into two main parts, continental and oceanic... oceanic crust only comprises some 30% of the crustal mass, as the continental crust is much thicker.
"""
crust_mass = .005 * earth_mass
continental_mass = .7 * crust_mass

# from http://en.wikipedia.org/wiki/Continents
"""
The total land area of all continents is 148,647,000 km^2,
"""
continental_area = 1.49e8

# from http://en.wikipedia.org/wiki/New_York_City
"""
New York City occupies ~ 305 square miles (790 km^2).
"""
nyc_area = 790

percent_of_continents_occupied_by_nyc = nyc_area / continental_area

UPPER_BOUND = continental_mass * percent_of_continents_occupied_by_nyc

print 'NYC weighs between {:,.0f} and {:,.0f} kg'.format(LOWER_BOUND, UPPER_BOUND)