5 Pages

HW_1_partial_solutions

Course: CEE 5970, Spring 2012
School: Cornell
Rating:
 
 
 
 
 

Word Count: 1131

Document Preview

5970 Spring CEE 2009 Homework # 1 Partial Solutions HW #1 Point Breakdown Q1) 8 points Q2) 8 points Q3) 10 points Q4) 10 points Q5) 12 points Q6) 12 points Q7) 40 points HW#1 Partial Solutions General Comments: Please read the question posed and answer all questions completely. For example, give your point answers for question 7(c), when t = 1,2,3 - NOT just an equation. If you are asked about how to...

Register Now

Unformatted Document Excerpt

Coursehero >> New York >> Cornell >> CEE 5970

Course Hero has millions of student submitted documents similar to the one
below including study guides, practice problems, reference materials, practice exams, textbook help and tutor support.

Course Hero has millions of student submitted documents similar to the one below including study guides, practice problems, reference materials, practice exams, textbook help and tutor support.
5970 Spring CEE 2009 Homework # 1 Partial Solutions HW #1 Point Breakdown Q1) 8 points Q2) 8 points Q3) 10 points Q4) 10 points Q5) 12 points Q6) 12 points Q7) 40 points HW#1 Partial Solutions General Comments: Please read the question posed and answer all questions completely. For example, give your point answers for question 7(c), when t = 1,2,3 - NOT just an equation. If you are asked about how to estimate the risk of a certain activity and you discuss exposure to the activity please be specific. For example, do not just say I would find out how many people were exposed. Instead discuss how you would judge that someone was exposed (ie. one ride, x miles traveled, an afternoon of the activity) and give some justification for the exposure measure. If a question says Explain, please provide a good discussion. Answers can be concise, but must address key issues. For instance, for question #3, an explanation was required for the ranking of each case. A long detailed discussion is not necessary, just one concise sentence regarding the key issues for each case is sufficient. Obviously you had to think about why you would rank the cases as you did, so just outline your thought process in your answer. QUESTION #7: Part (a) You are asked to use the additive-effects model to predict the fatality rate (F) for the driver in question. Some fundamental notes that you should be aware of and think about before you begin: - the symbol equals change and a change can be positive or negative - the model you suggest should be reasonable!!! For example, whatever model you develop, you want the fatality rate of a SAFE driver to be lower than the average fatality rate for all drivers (which is 12.56 deaths/billion) - Always think about units you cannot add a death rate to a dimensionless number to predict another death rate The approach to this question is to try and determine, in a reasonable manner, factors for your additive model from the multiplicative factors in the multiplicative model. The most straightforward way to do this is to determine additive factors that match the multiplicative model predictions when one changes one factor at a time. CEE 5970 Spring 2009 For each factor, i, solve for i: Fav + i = MiFav i = MiFav - Fav = Fav(Mi 1) (Mi is the multiplicative factor from Evans) (Mi 1 is now the additive model factor) End up with additive model prediction of: Fatality rate (deaths/billion) = Fav + age + alcohol + seat-belt + mass + road-type = 12.56 + (-5.68) + (-4.92) + (-6.38) + (-3.30) + (-5.90) = -13.56 You should note that since this prediction is less than 0 (i.e. Safe drivers are procreating, not dying in accidents!) the additive model would not be very good. The multiplicative model is better because it will not predict impossibly low fatality rates. You cannot just use the factors from the multiplicative model directly in the additive model think about the units! 7 (b): Evans et al. assume that the number of takeoffs and landings are independent of trip distance (page 243 of the article). Notice that this does not necessarily imply that all trips are assumed to be composed of one takeoff and one landing. Their assumption simply means that Evans et al. did not consider the impact of multiple takeoffs and landings on their risk estimates. 7 (c): Compare risk of driving d miles for a flight with t (=1, 2, 3) takeoffs and landings. First, estimate the driving risk for the driver in question using Evans et al. multiplicative model fatality gives rate = 2 deaths/billion miles Note that the age factor for the 25 year old can be determined directly from Figure 2 in Evans et al. as about 1. To clarify the units of the airline risk measures, for those who may have been confused by them, note the following regarding Evans et al. derivation of their equation (16): 880 miles * 0.55 fatalities = 484 fatalities average trip 109 miles 109 trips now we are given that the airline passenger death rate is 300 fatalities/10 9 flight segments (instead of 484 above). From equation (16) we can now say that: r = 300/d where r is the fatality risk, d is the distance flown CEE 5970 Spring 2009 However, if we want to consider multiple takeoffs and landings then we can say that: r = 300t/d where t is the number of takeoffs and landings To find the breakpoints of when it is better to fly or drive, solve the above equation for d when r=2 at each value of t. End up finding that: When t = 1, it is better to drive if d < 150 miles t =2, d < 300 miles t = 3, d < 450 miles 7 (d): Plot the results you get above two ways (ie. two graphs) following the Evans et al. plot and the Sivak et al. plot. Also include a second driver in the analysis. For each graph, we are looking for 2 drivers and 3 flights (t=1,2,3). A few notes: - best to show how you calculate the fatality rate and the probability for the graphs instead of just giving the graphed results. - excel graphs are always nicest! - Watch the units of the y-axis! For Evans et al. type plot (deaths vs trip distance): Use r = 300t/d to obtain the death rates for flying while the driving death rate is constant at the rate you calculate from the multiplicative model (eg. 2 deaths/billion). For Sivak et al. type plot (probability of death vs trip distance): Probability of death from travelling d miles by: a) driving is Probability = (death rate/109)d eg: = 2d/109 Note: you dont need to use the equation on page 148 of Sivak et al. b) flying only varies with number of segments, Probability = (300 deaths/109 segments)t = 300t/109 See graphs on following pages for examples of what they look like (note that 3 stops is not asked for in this question). The relative advantages of each should also have been given (marked easy if you tried to answer this). Some reasonable answers are: deaths vs trip distance natural and constant representation of driving risk, fit all results on same graph probability of death vs trip distance natural representation for airline risk, actual risk for choice CEE 5970 Spring 2009 7 (e): Calculate the expected loss of life expectancy of a 25-yr old taking a 600-mile non-stop flight. Expected value of this, E[X], has the units of life expectancy and is calculated from the probability of dying on this flight as: E[X] = P(X)*(amount of life lost) = 300/109 * (75yrs 25yrs) = 1.5*10-5 years = 8 min. Note: you must assume an average age that the 25 year old would live to here it is 75. Also note that we dont need to use the trip distance of 600 miles we just use the fact that the flight is non-stop (t=1). Evans et.al. Plot 10 Deaths per Billion M iles 9 Driver 1 8 Driver 2 7 Non-stop One-stop 6 Two-stops 5 4 3 2 drivers 1 0 0 500 1000 Distance (miles) 1500 2000 CEE 5970 Spring 2009 Sivak et.al. Plot 4500 Fatality Probability x 109 4000 3500 3000 Driver 1 2500 Driver 2 2000 Non-stop One-stop 1500 Two-stops 1000 500 0 0 500 1000 Distance (miles) 1500 2000
Find millions of documents on Course Hero - Study Guides, Lecture Notes, Reference Materials, Practice Exams and more. Course Hero has millions of course specific materials providing students with the best way to expand their education.

Below is a small sample set of documents:

Cornell - CEE - 5970
CEE 5970Spring 2009Homework #2 Partial SolutionsHW#2 Point BreakdownQ1) 12 pointsQ2) 27 pointsQ3) 1 pointQ4) 3 pointsQ5) 12 pointsQ6) 8 pointsQ7) 15 pointsQ8) 10 pointsQ9) 12 pointsHW#2 Partial Solutions1. Three Mile Island Case Study (12 po
Cornell - CEE - 5970
CEE 5970Spring 2009HW# 3 Pont Breakdown and Partial SolutionsHW#3 Point BreakdownQ1) 12 pointsQ2) 8 pointsQ3) 20 pointsQ4) 15 pointsQ5) 20 pointsQ6) 12 pointsQ7) 8 pointsQ8) 5 pointsHW #3 Partial Solutions3. Event Tree (20 points)Tips for ev
Cornell - CEE - 5970
CEE 5970 Risk Analysis and ManagementFinal Exam 2009Final EXAM Wed. May 13, 2009, 7-9:30 pmTest is open book &amp; open notes. You have 150 minutes for this 150 point exam.Write clearly and show important steps.1. (10 pts) Swine Flu was in the news this
Cornell - CEE - 5970
CEE 5970 Risk Analysis and ManagementFinal Exam 2011Final EXAM Friday May 13, 2011, 2 - 4:30 pmTest is open book &amp; open notes. You have 150 minutes for this 150 point exam.Write clearly and show important steps.1. This has been a terrible semester fo
Cornell - CEE - 5970
CEE 5970 Risk Analysis and ManagementFinal EXAMMon. May 17, 2010, 9-11:30 amTest is open book &amp; open notes. You have 150 minutes for this 150 point exam.Write clearly and show important steps. Answer essays carefully and completely.1. (12 pts) In not
Cornell - CEE - 5970
CEE 5970 Risk Analysis and ManagementEvening Midterm Exam (revised to be an example)March 10, 2011Test is open book and open notes. You have 90 minutes to complete this 90 point exam.Please show readable work to justify partial credit.1. (10 pts) The
Cornell - CEE - 5970
Cornell - CEE - 5970
CEE 5970 Statistics Review SessionExamples1. An engineer is responsible for ensuring that fire detectors in a controlled experimentidentify the presence of fire on average within 10 seconds. Every week 15 detectors aretaken from the production line, t
Rio Salado - BIO - 201
Cornell - CEE - 5970
CS 2110 Summer 2011: Assignment 1 HangmanDue July 5 at 5pmThis assignment is to be done by students individually; future assignments will done ingroups of two. You are expected to respect the code of academic integrity, as describedin the course sylla
Cornell - CEE - 5970
CS 2110 Summer 2011: Assignment 2 BoggleDue July 12 at 5pmThis assignment is to be done in pairs. Information about partners will be providedseparately.Playing Boggle11In this assignment, we continue the theme of games. Unlike the last assignment, w
Cornell - CEE - 5970
CS 2110 Summer 2011: Assignment 3 Sorting It OutDue July 19 at 5pmThis assignment is to be in groups of at most two students. You are expected to respectthe code of academic integrity, as described in the course syllabus.Primary Learning Objectives B
Cornell - CEE - 5970
CS 2110 Summer 2011: Assignment 4 Hufng and UnhufngDue July 26 at 5pmThis assignment is to be done in groups as assigned via CMS. You are expected to respect the code of academic integrity, as described in the course syllabus.Huffman Compression11Th
Cornell - CEE - 5970
CS 2110 Summer 2011: Assignment 5 Graphical UserInterface DesignDue August 2 at 5pmThis assignment is to be in groups of at most two students. You are expected to respectthe code of academic integrity, as described in the course syllabus.Median Avera
Cornell - CEE - 5970
CS 2110 Summer 2011: Assignment 6 The NaturalistDue August 10 at 5pmThis assignment is to be done in groups as assigned via CMS. You are expected to respect the code of academic integrity, as described in the course syllabus.Naturalist11For this assi
Cornell - CEE - 5970
Name _ NetID _ CS 2110 Summer 2011 Final Exam CS 2110 Final ExamQuestion 0. (0 Points) Write your name and net ID on each page.Question 1. (10 Points)a) (4 Points) Consider a hashtable of fixed size 6 that hashes object x using the hash
Cornell - CEE - 5970
Solutions for CS 2110 Summer 2011 Final Exam. (Text written in parenthesis is additional commentary, but not required for a full credit response.) QUESTION 1 Question 1.a) i. index: values 0: 1: 2
Cairo University - SYS - 10
April 21, 2009 17:7spi-b7279in x 6inb727-ch01Chapter 1Basic Knowledge and Modelingon Epidemic DynamicsZhien Ma and Jia Li1.1.IntroductionThe spread of infectious diseases has always been of concerns and a threatto public health. It has caused s
University of Phoenix - DDBA - 8860
Demystifying the DBA Doctoral StudyComponents of the 3-SectionDBA Doctoral StudySee the Notes section for additional informationObjectives of this Presentation Evaluate key components within the3-section doctoral study Discuss and examine the DBA D
Ashford University - PSYCH - 101
describing ways to find out what websites can be credible to use or not dependable
FIU - CHML - 1032
Experiment7InvestigationofaPowderName:Directions: Make sure that you write your name in the header region sothat it appears on each page. Use italics for everything that you type in thislab so that it stands out from the lab itself. This will help in
Ashford University - BUS - 300
Organizational CultureJustin BringasBUS600: Management Communications with Technology ToolsProfessor TvorikJune 16, 2011Lets take a closer look at organizational culture. Organizational culture can be defined as thevalues and behaviors that contribu
Akita International University - ECON - 102
5/14/2009Apple Inc. Case StudyKey Success FactorsExpertise in particular technology/research Proven ability to improve production processes Customer-need satisfaction Continued innovationRecommended StrategySpread out consumer confidence in Steve
Akita International University - ECON - 102
Executive SummaryFrom the humble beginnings as a quirky but scrappy underdog that flew mainly to secondaryairports, Southwest has climbed up through the industry ranks to become the major competitiveforce in the domestic segment of the US airline indus
MIT - CS - 11
Problem Wk.1.3.1: Fibonacci numbersPaste your code for the Fibonnaci program described in the Design Lab handout.You should not attempt to debug your code here; debug it using Idle on your machine.The test cases are random, so you should Check a few ti
MIT - CS - 11
Problem Wk.1.3.2: Simple OOPsFill in what gets printed by the interpreter after the following expressions. Assume thatall the previous expressions have been evaluated. If the expression would generate anerror, enter error. Hint: remember string quotes.
MIT - CS - 11
Problem Wk.1.3.3: TranscriptBelow is a transcript of a session with the Python shell. This means that we are doingeach of the statements in sequence, so for example, previous definitions andassignments are still in effect.Provide the value of the expr
MIT - CS - 11
Problem Wk.1.3.4: 2D vector arithmeticWrite the V2 class, as specified in the software lab handout.MIT OpenCourseWarehttp:/ocw.mit.edu6.01SC Introduction to Electrical Engineering and Computer ScienceSpring 2011For information about citing these mat
MIT - CS - 11
Problem Wk.1.3.5: Polynomial RepresentationsPart 1: Polynomial algebraFirst, let's review algebraic operations on polynomials.The answers below require you to enter sequences of coefficients for polynomials.Enter the coefficients in the order that the
MIT - CS - 11
Problem Wk.1.3.6: Polynomial classPaste your code for the Polynomial class that is described in the lab handout. We willcheck the code with random inputs; the tests are arranged to that they test eachmethod separately and then combinations of them. Loo
MIT - CS - 11
Problem Wk.1.4.1: Structured assignmentsRead the section on structured assignment in the course notes. Note that structuredassignments are often preferable to using list indices to access elements of lists (ortuples). You can give the list elements mne
MIT - CS - 11
Problem Wk.1.4.2: Nested and Shared StructuresUse lists, not tuples, in all your answers.Part 1: NestingGive a Python statement which, when evaluated, would give rise to this memorystructure:Part 2: Sharing 1Give a Python statement which, when evalu
MIT - CS - 11
Problem Wk.1.4.3: List ComprehensionsPart 1: Even SquaresDefine a procedure, called evenSquares that takes a list of numbers as input and returnsa list of the squares of the input values that are even. Use a list comprehension. Youcan test whether a n
MIT - CS - 11
Problem Wk.1.4.4: OOPsPart 1: Thing 1Below is a transcript of a session with the Python shell. This means that we are doingeach of the statements in sequence, so for example, previous definitions andassignments are still in effect.Provide the value o
MIT - CS - 11
Problem Wk.1.4.5: OOPsPart 1: AssignWrite a procedure, called assignThing, that takes two Things, thing1 and thing2, asarguments and sets the stored value (x) of thing1 to the stored value of thing2.Use the set and get methods of Thing, do not access
MIT - CS - 11
Problem Wk.1.4.6: OOPsPart 1: Thing cloneAdd a method called clone to the Thing class which returns a completely new Thing withthe same stored value.&gt;&gt;&gt;&gt;3a = Thing()a.set(3)b = a.clone()b.get()Use the set and get methods of Thing, do not acce
MIT - CS - 11
Problem Wk.1.4.7: Palindrome [Optional]Write a procedure, called isPalindrome, that takes a string as an argument and returnsTrue if the string is a palindrome, that is, if the string is identical to the reversed string.It should return False otherwise
Berkeley - PHYSICS - 8A
MasteringPhysics: Assignment Print View12/22/11 5:02 PMHwk # 0 - Introduction to MasteringPhysics (FOR PRACTICE ONLY)Due: 11:00pm on Wednesday, August 31, 2011Note: To understand how points are awarded, read your instructor's Grading Policy.[Switch t
MIT - CS - 11
Problem Wk.1.4.8: Substring [Optional]Write a procedure, called isSubstring, that takes two strings as inputs and returns Truewhen the first string is a substring of the second one, that is, when all of the charactersin the first string occur contiguou
MIT - CS - 11
Problem Wk.1.4.9: Extract tags [Optional]Write a procedure, called extractTags, that takes a string as input and returns a list ofstrings corresponding to the names of the bracketed tags in the string. Bracketed tagsstart with [ and end with ]. You can
MIT - CS - 11
Problem Wk.1.4.10: Fruit Class [Optional]Part 1: Fruit SaladDefine a class FruitSalad with class attributes fruits, which is initially ['melons','pineapples'] and servings which is initially 4.Write an _init_ method that takes arguments ingredients (a
MIT - CS - 11
Problem Wk.1.4.11: Warehouse [Optional]We'll be building a set of procedures to model a simple warehouse accounting system,which maintains the inventory for a set of commodities, which we will represent bystrings, e.g. 'a', 'b', 'c'. So, the warehouse
MIT - CS - 11
Problem Wk.2.1.1: State machinesConsider a state machine with:inputs: 0, 1, 2states: 0, 1, 2, 3outputs: 0, 1, 2, 3initial state: 0transition function:Input012old state: 0 1 3 0old state: 1 2 0 0old state: 2 3 1 0old state: 3 0 2 0output funct
MIT - CS - 11
Problem Wk.2.1.2: Turnstile state machineHere is a state transition diagram for a turnstile.It has states 'locked' and 'unlocked'It has inputs 'coin', 'none', and 'turn'It has outputs 'enter' and 'pay'The idea is that if it is locked and someone puts
MIT - CS - 11
Problem Wk.2.1.3: Double Delay State MachineWrite a (non-terminating) state machine class (assume you have the sm.SM class) thatdelays its input by two time steps, so output at time i is the input at time i-2. The classshould take two arguments, which
MIT - CS - 11
Problem Wk.2.1.4: Comments MachineWrite a state machine whose inputs are the characters of a string (representing aPython program) and which outputs either (a) the input character if it is part of acomment or (b) None. As you know, comments start with
MIT - CS - 11
Problem Wk.2.1.5: First Word Machine [Optional]Write a state machine whose inputs are the characters of a string and which outputseither (a) the input character if it is part of the first word on a line or (b) None. For thepurposes here, a word is any
MIT - CS - 11
Problem Wk.2.3.1: Inheritance IConsider the following program:class NN:def _init_(self):self.n = 0def get(self):self.n += 1 return str(self.n)def reset(self):self.n = 0 class NS(NN):def get(self, s):return s + NN.get(self)The following statem
MIT - CS - 11
Problem Wk.2.3.2: Inheritance IIYou are told that we have a class AccountDollars, with one initialization argument, theinitial balance, with a method depositDollars that takes one argument (a depositamount) and returns a number (the balance after the d
MIT - CS - 11
Problem Wk.2.3.3: Inheritance and State MachinesRecall that we have defined a Python class sm.SM to represent state machines. Here weconsider a special type of state machine, whose states are always integers that start at0 and increment by 1 on each tr
MIT - CS - 11
Problem Wk.2.3.4: Introduction to RecursionPart 1: AddIn a recursive procedure definition we have one or more base cases and one or morerecursive cases. Base cases terminate the recursion and return a value without callingthe recursive procedure again
MIT - CS - 11
Problem Wk.2.3.5: Slow modSuppose we want to implement the modulus (mod) operation (Python % operator), butonly have the operations of addition, subtraction, and simple tests available to us.Write a recursive Python procedure slowMod that takes two arg
MIT - CS - 11
Problem Wk.3.1.1: Simulating CascadeYou are given the following state machines:class Delay(sm.SM):def _init_(self, v0):self.startState = v0def getNextValues(self, state, inp):# Output is old statereturn (inp, state)class Increment(sm.SM):startSta
MIT - CS - 11
Problem Wk.3.1.2: Cascading MachinesWrite the Cascade combinator for state machines described in the class notes. Makesure that you have read Section 4.2 of the course notes (about Cascade and Parallel).Your implementation should read the startState at
MIT - CS - 11
Problem Wk.3.1.3: Function MachinesWhen composing state machines, we often want to have a pure function machine thatcan be used in a cascade to operate on the output of a state machine. In this problem,we define a subclass of SM that simply applies a g
MIT - CS - 11
Problem Wk.3.1.4: Combining accountsConsider two different kinds of bank accounts:BA1:Fee of $100 on every (non-zero) deposit and withdrawal; 2% interest pertime step.class BA1(sm.SM):startState = 0def getNextValues(self, state, inp):if inp != 0:
MIT - CS - 11
Problem Wk.3.1.5: Sequential combinationsPart 1: Sum machineDefine a terminating state machine class whose inputs are numbers, which outputs thesum of its inputs so far, and which terminates when the sum is &gt; 100. The currentinput should be reflected
MIT - CS - 11
Problem Wk.3.1.6: Feedback SMRead Section 4.2.3 of the Notes, about feedback composition of state machines.Define negate to be an instance of a sm.PureFunction machine that takes a Boolean asinput and returns the negation of that Boolean.Use sm.Feedba
MIT - CS - 11
Problem Wk.3.3.1: MapPart 1: mapListDefine a procedure mapList that takes two arguments, a procedure of one argumentand a list. It returns the list of the results of applying the procedure to each of theelements of the list.&gt; def sq(x): return x*x&gt;
MIT - CS - 11
Problem Wk.3.3.2: Indexing Nested ListsIt would be handy to have a procedure that allows accessing lists that are nested toarbitrary depth. It would take a nested list and some sort of an index, and return thepart of the list at that index (which could
MIT - CS - 11
Problem Wk.3.3.3: Finding systemsA difference equation is in the form:Determine the difference equation representation for the following systems.Specify the dCoeffs:and the cCoeffs:for each of the differenceequations below. For each question, enter