The first thing we'll need to do is calculate #f'(x)# at #x = (15pi)/8#.

Let's do this term by term. For the #sec^2(x)# term, note that we have two functions embedded within one another: #x^2#, and #sec(x)#. So, we'll need to use a chain rule here:

#d/dx(sec(x))^2 = 2sec(x) * d/dx(sec(x))#

#color(blue)(= 2sec^2(x)tan(x))#

For the 2nd term, we'll need to use a product rule. So:

#d/dx(xcos(x-pi/4)) = color(red)(d/dx(x))cos(x-pi/4) + color(red)(d/dxcos(x-pi/4))(x)#

#color(blue)(= cos(x-pi/4) - xsin(x-pi/4))#

You may wonder why we didn't use a chain rule for this part, since we have an #(x - pi/4)# inside the cosine. The answer is we implicitly did, but we ignored it. Notice how the derivative of #(x - pi/4)# is simply 1? Hence, multiplying that on doesn't change anything, so we do not write it out in calculations.

Now, we put everything together:

#d/dx(sec^2x-xcos(x-pi/4)) = color(violet)(2sec^2(x)tan(x) - cos(x-pi/4) + xsin(x-pi/4))#

*Watch your signs.*

Now, we need to find the slope of the line tangent to #f(x)# at #x = (15pi)/8#. To do this, we just plug this value into #f'(x)#:

#f'((15pi)/8) = (2sec^2((15pi)/8)tan((15pi)/8) - cos((15pi)/8-pi/4) + (15pi)/8sin((15pi)/8-pi/4)) = color(violet)(~~-6.79)#

However, what we want is not the line tangent to f(x), but the line *normal* to it. To get this, we just take the negative reciprocal of the slope above.

#m_(norm) = -1/-15.78 color(violet)(~~0.015) #

Now, we just fit everything into point slope form:

#y = m(x-x_0) + y_0

#=> y = 0.063(x - (15pi)/8) - 1.08#

Take a look at this interactive graph to see what this looks like!

Hope that helped :)