Week 2
Week 2
Lecture 4
Slope-Intercept formula
1
2. y = x+1
5
3. y = 2x − 3
3. y = 2x − 3
The slope tells you how to angle the line, and the y-intercept tells you where to anchor it on the y-axis.
Example:
Quadratic function
h(x) = x2
Graph a function by testing input and output pairs, see a pattern, and try to draw a curve
through it. This is similar to querying in supervised learning.
Table of values:
x h(x)
0 02 = 0
1 12 =1
2 22 =4
3 32 =9
2
-1 (-1) =1
• F is strictly increasing
• G is strictly decreasing
• H is neither
Let f:ℝ → ℝ ,
f is strictly increasing if whenever a < b, we have f(a) < f(b).
f is strictly decreasing if whenever a < b, we have f(a) > f(b).
Examples:
2 22 =4 2 3-2 = 1/9 2 22 =4
3 23 =8 3 3-3 = 1/27 3 32 =9
-1 1 2
-1 2 = 1/2 -1 3 =3 -1 (-1) =1
• F is strictly increasing
• G is strictly decreasing
Warning: not every function f : R → R has an inverse.
Warning: if the graph of f fails the horizontal line test, then f has no inverse. The
only invertible functions are those that are either strictly increasing or strictly
decreasing.