I need to create a slider that displays the secant line of the function (defined as functionsecant) using the Manipulate function in mathematica, but I can't get it to work and I can't find any tutorials breaking down how the function works and how your supposed to put in input. (I am brand new to Mathematica)
This is what I thought would work, but apparently it doesn't.
Manipulate[
Plot[function[x], functionsecant[x], {x, -10, 10},
PlotRange -> {{-5, 5}, {-5, 5}},
Epilog -> {Red, PointSize[.015], Point@{p, functionsecant[p]}}], {p, 0,
10}]
And it's supposed to plot the secant line from (0,0) to (a,f(a)). How exactly do I do this? I'm at my wit's end D: