SUNY Geneseo Department of Mathematics
Tuesday, October 28
Math 221 10
Fall 2014
Prof. Doug Baldwin
> f = function(x) { x^2 - 3*x }
> f(1)
[1] -2
> f(0)
[1] 0
> curve( f(x), 1, 4 )
> a = 1
> b = 4
> ( f(b) - f(a) ) / (b - a)
[1] 2
> curve( 2*x - 4, add=TRUE, col="purple")
> c = 2.5
> f(c)
[1] -1.25
> curve( 2*x - 6.25, add=TRUE, col="red")
> g = function(x) { x^3/3 - x}
> curve( g(x), -2, 2 )
> curve( x/3, add=TRUE, col="purple")
> c = -2 / sqrt(3)
> c
[1] -1.154701
> g(c)
[1] 0.6415003
> m = 1/3
> t1 = function(x) { m*x - m*c + g(c) }
> curve( t1(x), add=TRUE, col="red")
> c = 2 / sqrt(3)
> curve( t1(x), add=TRUE, col="red")