Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Definition: CuSum Let t denote the current time. The CuSum primitive calculates a value, S, by the formula S, = max {0, S,-it (1-z)), where
Definition: CuSum Let t denote the current time. The CuSum primitive calculates a value, S, by the formula S, = max {0, S,-it (1-z)), where S, is the value of the function at time t; S-1 is the value of the function at time 1 is a predetermined mean value, either from an expert or possibly calculated over a range of observed data . and x, is the observed value of the temperature sensor at time t. Take a moment to convince yourself that S, is always at least zero, and that it is computed by updating the previous value, S,-1, by the difference between the current observation (x) and an expected mean value (u) Take a moment to convince yourself that r is always at least zero, and that it is computed by updating the previous value 5-1 , by the difference between the current observation (x) and an expected mean value (u) The analysis. You wish to raise an alarm only when the value of S, crosses a predetermined threshold value, , i.e., when S, > . Let's break down this analysis task into smaller parts. Exercise 0 (2 points). Write a function, calc_mean(L), that takes a list of values as input and returns the mean of these values. The returned value should be a float. If L is empty, your function should return 0.0 In : def calc_mean (L): YOUR CODE HERE
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started