Let the equation of the curve be y=f(x).
y=x2−4cosx
The slope of the tangent to the curve at any point x is given by the first derivative, dxdy. Let the slope be denoted by m.
m=dxdy
m=dxd(x2−4cosx)
m=2x−4(−sinx)
m=2x+4sinx
To maximize this function m on the interval [0,π], differentiate m with respect to x and equate it to zero.
dxdm=dxd(2x+4sinx)
dxdm=2+4cosx
Setting dxdm=0 for critical points:
2+4cosx=0
4cosx=−2
cosx=−21
Finding x in the interval [0,π] such that cosx=−21:
Since cosx is negative, x must be in the second quadrant.
Given that cos(3π)=21:
x=π−3π
x=32π
To confirm that this value of x gives a maximum slope, find the second derivative of m:
dx2d2m=dxd(2+4cosx)
dx2d2m=−4sinx
Evaluating at x=32π:
dx2d2mx=32π=−4sin(32π)
dx2d2mx=32π=−4(23)
dx2d2mx=32π=−23
Since the second derivative is negative (<0), the slope m is at a local maximum at x=32π.
Checking the endpoints of the interval [0,π] to ensure it is the global maximum:
At x=0:
m=2(0)+4sin(0)
m=0
At x=π:
m=2π+4sin(π)
m=2π≈6.28
At x=32π:
m=2(32π)+4(23)
m=34π+23≈7.65
The value at x=32π is the highest.
Therefore, the slope of the tangent to the curve is maximum when x=32π.