UVA CS 150 - Lecture 20: Sex, Religion, and Politics

Unformatted text preview:

1David Evanshttp://www.cs.virginia.edu/evansCS150: Computer ScienceUniversity of VirginiaComputer ScienceLecture 20: Sex, Religion, and Politicshttp://www.pbs.org/wgbh/nova/sciencenow/3313/nn-video-toda-w-220.htmlScience's Endless Golden Age3Lecture 20: GrowthAstrophysics• “If you’re going to use your computer to simulate some phenomenon in the universe, then it only becomes interesting if you change the scale of that phenomenon by at least a factor of 10. … For a 3D simulation, an increase by a factor of 10 in each of the three dimensions increases your volume by a factor of 1000.”• How much work is astrophysics simulation (in Θnotation)?Θ(n3)When we double the size of the simulation, the work octuples! (Just like oceanography octopi simulations)4Lecture 20: GrowthOrders of Growth0204060801001201401 2 3 4 5n3 n2 ninsert-sortsimulatinguniversefind-best5Lecture 20: GrowthOrders of Growth02000004000006000008000001000000120000014000001 11 21 31 41 51 61 71 81 91 101insert-sortsimulatinguniversefind-best6Lecture 20: GrowthAstrophysics and Moore’s Law• Simulating universe is Θ(n3)• Moore’s law: computing power doubles every 18 months• Dr. Tyson: to understand something new about the universe, need to scale by 10x• How long does it take to know twice as much about the universe?27Lecture 20: Growth;;; doubling every 18 months = ~1.587 * every 12 months(define (computing-power nyears)(if (= nyears 0) 1 (* 1.587 (computing-power (- nyears 1)))));;; Simulation is Θ(n3) work(define (simulation-work scale) (* scale scale scale)) (define (log10 x) (/ (log x) (log 10))) ;;; log is base e;;; knowledge of the universe is log10the scale of universe ;;; we can simulate(define (knowledge-of-universe scale) (log10 scale))Knowledge of the Universe8Lecture 20: Growth(define (computing-power nyears)(if (= nyears 0) 1 (* 1.587 (computing-power (- nyears 1)))));;; doubling every 18 months = ~1.587 * every 12 months(define (simulation-work scale) (* scale scale scale)) ;;; Simulation is O(n^3) work(define (log10 x) (/ (log x) (log 10))) ;;; primitive log is natural (base e)(define (knowledge-of-universe scale) (log10 scale));;; knowledge of the universe is log 10 the scale of universe we can simulate(define (find-knowledge-of-universe nyears)(define (find-biggest-scale scale);;; today, can simulate size 10 universe = 1000 work(if (> (/ (simulation-work scale) 1000) (computing-power nyears))(- scale 1)(find-biggest-scale (+ scale 1))))(knowledge-of-universe (find-biggest-scale 1)))Knowledge of the Universe9Lecture 20: Growth> (find-knowledge-of-universe 0)1.0> (find-knowledge-of-universe 1)1.041392685158225> (find-knowledge-of-universe 2)1.1139433523068367> (find-knowledge-of-universe 5)1.322219294733919> (find-knowledge-of-universe 10)1.6627578316815739> (find-knowledge-of-universe 15)2.0> (find-knowledge-of-universe 30)3.00560944536028> (find-knowledge-of-universe 60)5.0115366121349325> (find-knowledge-of-universe 80)6.348717927935257Will there be any mystery left in the Universe when you die?Only two things are infinite, the universe and human stupidity, and I'm not sure about the former. Albert Einstein10Lecture 20: GrowthThe Endless Golden Age• Golden Age – period in which knowledge/quality of something doubles quickly• At any point in history, half of what is known about astrophysics was discovered in the previous 15 years!– Moore’s law today, but other advances previously: telescopes, photocopiers, clocks, agriculture, etc.11Lecture 20: GrowthEndless/Short Golden Ages• Endless golden age: at any point in history, the amount known is twice what was known 15 years ago– Always exponential growth: Θ(kn)k is some constant, n is number of years• Short golden age: knowledge doubles during a short, “golden” period, but only improves linearly most of the time– Usually linear growth: Θ(n)n is number of years12Lecture 20: Growth010,000,00020,000,00030,000,00040,000,00050,000,00060,000,00070,000,00080,000,00019691972197519781981198419871990199319961999200220052008Computing Power 1969-2008(in Apollo Control Computer Units)Moore’s “Law”: computing power roughly doubles every 18 months!313Lecture 20: Growth02,0004,0006,0008,00010,00012,00014,00016,00018,00019691970.519721973.519751976.519781979.519811982.519841985.519871988.51990Computing Power 1969-1990(in Apollo Control Computer Units)14Lecture 20: Growth11.522.533.544.555.56193019341938195019541958196219661970197419781982198619901994199820022006Average Goals per Game, FIFA World CupsChanged goalkeeperpassback ruleGoal-den age15Lecture 20: GrowthEndless Golden Age and “Grade Inflation”• Average student gets twice as smart and well-prepared every 15 years– You had grade school teachers (maybe even parents) who went to college!• If average GPA in 1977 is 2.00 what should it be today (if grading standards didn’t change)?16Lecture 20: GrowthGrade Inflation or Deflation?2.00 average GPA in 1977 (“gentleman’s C”?)* 2 better students 1977-1992* 2 better students 1992-2007* 1.49 population increase* 0.74 increase in enrollmentAverage GPA today should be: 8.82(but our expectations should also increase)Students 1976: 10,330Students 2006: 13,900Virginia 1976: ~5.1MVirginia 2006: ~7.6M17Lecture 20: GrowthThe Real Golden Rule?Why do fields like astrophysics, medicine, biology and computer science have “endless golden ages”, but fields like– music (1775-1825)– rock n’ roll (1962-1973, or whatever was popular when you were 16)– philosophy (400BC-350BC?)– art (1875-1925?)– soccer (1950-1966)– baseball (1925-1950?)– movies (1920-1940?) have short golden ages? Thanks to Leah Nylen for correcting this (previously I had only 1930-1940, but thatis only true for Hollywood movies).18Lecture 20: GrowthGolden AgesorGolden Catastrophes?419Lecture 20: GrowthPS4, Question 1eQuestion 1: For each f and g pair below, argue convincingly whether or not g is (1) O(f), (2) Ω(f), and (3) Θ(g) …(e) g: the federal debt n years from today, f: the US population n years from today20Lecture 20: GrowthMalthusian CatastropheReverend Thomas Robert Malthus, Essay on the Principle of Population, 1798“The great and unlooked for discoveries that have taken place of late years in natural philosophy, the increasing diffusion of general knowledge from the extension of the art of printing, the ardent and unshackled spirit of inquiry that prevails throughout the lettered and even unlettered world, …


View Full Document

UVA CS 150 - Lecture 20: Sex, Religion, and Politics

Documents in this Course
Objects

Objects

6 pages

Load more
Download Lecture 20: Sex, Religion, and Politics
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Lecture 20: Sex, Religion, and Politics and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Lecture 20: Sex, Religion, and Politics 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?