# a2 - York University EECS 3101 Homework Assignment#2 Due at...

• Test Prep
• 1

This preview shows page 1. Sign up to view the full content.

York University EECS 3101 September 17, 2015 Homework Assignment #2 Due: September 24, 2015 at 4:00 p.m. 1. In this question we will consider functions f : IR IR. A value x IR is called a fixed point of f if f ( x ) = x . A function f is called strictly decreasing if, for all x, y IR, x < y f ( x ) > f ( y ). In solving this problem, you may use the following result from calculus. Bolzano’s Theorem Let g : IR IR be a continuous function, and let a and b be real numbers with a < b , g ( a ) < 0 and g ( b ) > 0. Then, there exists a real number c such that a < c < b and g ( c ) = 0. For the remainder of this assignment, let f : IR IR be any continuous, strictly decreas- ing function f that has f (0) > 0. (a) Let f : IR IR be a continuous strictly decreasing function and let a and b be real numbers such that a < b , f ( a ) a and f ( b ) < b . Prove that there exists a fixed point c of f such that a c < b . (b) Show that f has a fixed point x such that 0 x < f (0). (c) Provide pseudocode for an algorithm that outputs an integer
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: n such that there is a ﬁxed point of f in the interval [ n,n + 1) = { x ∈ IR : n ≤ x < n + 1 } . The number of times your algorithm calls the function f should be O (log | f (0) | ). Your pseudocode should include pre- and post-conditions. If you use a loop, you should also include a loop invariant in the pseudocode that you can use for part (c), below. (d) Prove that the algorithm given in part (b) is correct. Note: you do not have to prove that your algorithm calls f O (log | f (0) | ) times, but it should be true in order for your algorithm to get full marks. Example: The graph below shows the strictly decreasing function f ( x ) = (7-x ) 3 30 . It has a ﬁxed point between 2 and 3, so if your algorithm is run with this function f , it should output 2. 1...
View Full Document

{[ snackBarMessage ]}

### What students are saying

• 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.

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

• 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.

Dana University of Pennsylvania ‘17, Course Hero Intern

• 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.

Jill Tulane University ‘16, Course Hero Intern