{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Lecture 10 - Lecture 10 Root Finding Methods and Interfaces...

Info icon This preview shows pages 1–5. Sign up to view the full content.

View Full Document Right Arrow Icon
Lecture 10: Root Finding Methods and Interfaces Problem: Estimate alpha and beta for each wind turbine. Here is one student's approach that uses a stepper method to find the value of alpha given the values of both the mean and the median. This method is not considered good although the Java code works just fine. Not only is the stepper inefficient, but the ratio mean/median is not a sensitive barometer for finding alpha. For your projects it is hoped you will use a better method. The method is invoked as: MyFunctions.findAlpha(mean, median) If it is defined in the class MyFunctions Before using the method you would need to calculate both the mean and median for each array of 1000 wind speed measurements. The method would also need to be placed inside a Java class. What's Wrong: This approach uses the less sensitive mean/median ratio: r 1 = μ median = ! 1 + 1 " # $ % & ( ln(2) 1/ " (and stepper methods though simple, are notoriously inefficient.) Notice β cancels out when we compute this ratio using the first two of the following identities. The Weibull mean is given by: μ = ! " 1 + 1 # $ % & ( ) The Weibull median is given by: Median = ! ln 2 ( ) 1/ " The Weibull variance is given by: ! 2 = " 2 # 1 + 2 $ % & ( ) * + # 1 + 1 $ % & ( ) * 2 % & ( ) * The most serious problem is that around the physically meaningful value of α = 2, the ratio r 1 is not very sensitive.
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
You can see this lack of sensitivity in the following graph. Maple Code: > rhs := GAMMA(1 + 1/alpha)/ln(2)^(1/alpha); > y := 'y': plot( rhs, alpha = 0.25..5.001, y = 0..8, thickness=2, font = [TIMES,BOLD,18], ytickmarks = 10, gridlines=true); For larger values of alpha, this method will not be very sensitive as the curve is very flat! A table can summarize the same info. Example: Suppose you find that the mean divided by the median is 1.2 What would be a good estimate for alpha? Look's like 1.35 should be close. Alpha RHS [1., 1.442695041] [1.1, 1.346455653] [1.2, 1.276662828] [1.3, 1.224376348] [1.4, 1.184175973] [1.5, 1.152607899] [1.6, 1.127380096] [1.7, 1.106919306] [1.8, 1.090114490] [1.9, 1.076161730] Find α if the ratio mean/median = 1.2
Image of page 2
[2.0, 1.064467020] [2.1, 1.054583356] [2.2, 1.046168919] [2.3, 1.038958573] [2.4, 1.032744044] [2.5, 1.027359844] [2.6, 1.022673135] [2.7, 1.018576281] [2.8, 1.014981328] [2.9, 1.011815848] [3.0, 1.009019767] You might try the following stepper method. Parameter Finding Method 1 : Estimate alpha by finding the root of the equation: ! 1 + 1 " # $ % & ( ln(2) 1/ " ) μ median = 0 Again, this is not a good method because the ratio is not sensitive for the range in which we expect to find α and will not earn full marks . Warning: The following stepper method is not recommended, but the Java is good. STEPPER METHOD The fact that the red curve falls monotonically, suggests the following strategy. Start at a small value of alpha and progressively move to the right in small steps of say δ = 0.0001 until the error ratio – mean/median changes sign from positive to negative. The value where this occurs provides an estimate for alpha.
Image of page 3

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Nevertheless, here is the findAlpha method using this rather insensitive approach. public static double findAlpha( double mean, double median ){ double arg, den, num; //1. Calculate ratio(1) by dividing the mean by the median.
Image of page 4
Image of page 5
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern