0
$\begingroup$

Consider the following paragraph from Numerical Computation of deep learning book that says derivative as a slope of the function curve at a point

Suppose we have a function $y= f(x)$, where both $x$ and $y$ are real numbers. The derivative of this function is denoted as $f'(x)$ or as $\dfrac{dy}{dx}$ . The derivative $f'(x)$ gives the slope of $f(x)$ at the point $x$. In other words, it specifies how to scale a small change in the input to obtain the corresponding change in the output: $f(x+ \epsilon) \approx f(x)+\epsilon f'(x)$.

Slope of a function $f(x)$ at a point $a$ is generally defined as the $\tan$ of the angle made by the tangent line at the point $a$ on the curve of the function $f(x)$ to the positive x-axis in anti-clock wise direction. That is, if $\theta$ is the angle made by the tangent of the curve $f(x)$ at a point $(a, f(a))$ to the positive x-axis in anti-clock wise direction. Then the slope of $f(x)$ at point $a$ is $\tan \theta$.

In theory, tangent line should touch the curve of $f(x)$ at a single point only. Most of the textbooks draws nice convex curves and then show slope as $\tan \theta$. But, i think it is not possible for many functions to draw a tangent line at a point that touches the curve at that single point only. Else it may be a tangent line or some other traversal.

How to understand slope as $\tan \theta$ in such cases? Where am I going wrong?

$\endgroup$
0
$\begingroup$

Slope is not defined like this. You are confusing slope with angle. The slope definition will be more natural, as seen below.

Intuitively, the slope of a curve at a point is directly how steeply it changes as a function of change of horizontal distance: a flat road doesn't change in height as you drive on it, but driving on a ramp constantly elevates you as you drive up it. Typically this is understood as a ratio, so a 45 degree angle has a slope of 1, and a slope of 30 degrees has a slope of $\sqrt3$. This will be formalized in trigonometry, but if I recall correctly, the definition can go the other direction as well (that the ratio approach defines the angle).

We use ratios measurements of slopes instead of degree measurements of angles because calculating the derivative using the limit definition gives the slope as a ratio directly. This graphic shows the idea rather nicely, but this article provides a clearer exposition.

There's also the case that the slope as a ratio makes more sense since the backpropagation technique is effectively adding/subtracting $Ξ΅$ to some $x$ given known $\Delta f(x)$, the error signal, relying on the equation you posted above: $f(π‘₯+πœ–)β‰ˆπ‘“(π‘₯)+πœ–π‘“β€²(π‘₯)$.

We can rewrite the equation above to obtain $𝑓(π‘₯) - f(π‘₯+πœ–) β‰ˆ - πœ–π‘“β€²(π‘₯) $. Since $\Delta f(x)$ and 𝑓′(π‘₯) are known, we can also compute $πœ–$, but note that only the righthand expression of $πœ–$ is computed since $𝑓(π‘₯) - f(π‘₯+πœ–)$ is obtained as $Δ𝑓(π‘₯)$. We can resolve this with the update rule $x \rightarrow x - \epsilon$

$\endgroup$
5
  • $\begingroup$ Do you mean $\dfrac{dy}{dx} = \tan \theta$ may not be valid in some cases? $\endgroup$
    – hanugm
    Aug 24 at 5:43
  • 1
    $\begingroup$ i think you are confusing the word "tangent" for the trig expression $\tan$. these are different. $\endgroup$ Aug 24 at 5:47
  • $\begingroup$ $\theta$ inside $\tan \theta$ is the angle made by which line? It is tangent line right? $\endgroup$
    – hanugm
    Aug 24 at 5:50
  • $\begingroup$ relative to what other angle? you'll eventually have to use the limit approach anyways i believe... $\endgroup$ Aug 24 at 5:51
  • 1
    $\begingroup$ sorry i meant to say: the line that defines the tangent is characterized by the limit approach; without it, you will find it hard to "draw a line" that only "touches the curve" at a single point $\endgroup$ Aug 24 at 5:54

Your Answer

By clicking β€œPost Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.