A curious property of simple functions

January 6, 2016 |

The other day, I was thinking about how, when you first learn calculus, the way you find the derivative of a function at a certain point is to find the slope of a line that passes through two very close points.

For example, for $f(x) = x^2$, we would find the derivative like this:

\lim_{h \to 0}{(u+h)^2 - u^2 \over h} = 2u

Once we know the derivative, we can easily calculate the tangent line at any given point $u$. We'll call the function $tl$ for "tangent line":

tl(x, u) = f'(u)x + f(u) - f'(u)

Those tangent lines neatly frame the original function, like so:

We can also find the lines that pass orthogonally through any point $u$ just as easily. We'll call that $ol$ for "orthogonal line":

ol(x, u) = x \frac{{-1}}{{f'(u)}} + f(u) - u\frac{{-1}}{{f'(u)}}

Which simplifies to:

ol(x,u) = \frac{{(u-x)}}{{f'(u)}} + f(u)

Which in the case of $f(x) = x^2$ comes out to:

\frac{{(u-x)}}{{2u}} + u^2

If we draw a bunch of these orthogonal lines—the exact equivalent of the tagent lines but passing through $u^2$ at $\pi/2$ radians—we see an interesting V-shaped curve emerge.

I wanted to find the function that described this curve, so I started by find the point on that curve for any value of $u$ on the original function ($f(x) = x^2$) by looking at the intersection of two orthogonal lines that were very close together:

ol(x, u) = ol(x, u+h)

Which we might otherwise state as:

\lim_{h \to 0} \frac{{ol(x, u+h)-ol(x, u)}}{{h}}

That looks familiar: It's just the partial derivative of $ol$, $\frac{{\partial ol}}{{\partial u}}$, which in this case is:

\frac{{x}}{{2u^2}} + 2u

which simplifies to:

x = -4u^3

or:

u = ^3\sqrt{\frac{{-x}}{{4}}}

Plugging in $-4u^3$ into $ol$ for $x$ and plotting a bunch of points does, in fact, recreate this curve:

We're almost there! Now we just need to substitute $u = ^3\sqrt{\frac{{-x}}{{4}}}$ for $u$ in $ol$ to get the orthogonal function:

\bot(x) = ol(x,^3\sqrt{\frac{{-x}}{{4}}} ) = \frac{{1}}{{2}} + ^3\sqrt{(\frac{{-x}}{{4}})^2} + \frac{{x}}{{2 * ^3\sqrt{\frac{{-x}}{{4}}}}}

Which simplifies to:

\bot(x) = \frac{{1}}{{4}} (2 + 3 \cdot ^3\sqrt{4} \cdot ^3\sqrt{(-x)^2})

I don't have any idea if this has any application, but I find it surprising that a simple mental exercise in looking at orthogonal lines instead of tangent lines for such a basic function, $f(x) = x^2$, yields such a messy result for $\bot(x)$. And not every function has a valid orthogonal function. The only reason this worked is that we had a relationship between $x$ and $u$ (that is, $x = -4u^3$) that could be reversed to solve for $x$, which isn't always the case. I'll write a future post at some point generalizing these orthogonal functions for any value of $f$.