The Tip of the Cartesian Leaf
Todayβs problem is about the Cartesian leaf, named after the great mathematician and philosopher RenΓ© Descartes. In 1638, Descartes challenged Pierre de Fermat (yes, the one with the famous theorem) to find the tangent line to an arbitrary point of the curve. Fermat solved the problem easily, but Descartes was unable to do so. We are going to do something slightly different. We will find the position of the tip of the leaf by using a technique invented by some other French guy of the same era: Joseph-Louis Lagrange.
The Problem
The Cartesian leaf is the curve defined by the equation
If you plot it in the plane, it looks like this (for π=1):
The problem for today is: find the position of the tip of the leaf!
Solution with Python
Using Pythonβs computer algebra package sympy , we start a Jupyter notebook and define the symbols and equation for the Cartesian leaf:
So, where is the tip? Well, it is at a point where the distance from the origin has a maximum. The distance from the origin is simply
But if π has a maximum, also πΒ² has a maximum, too. So we can save ourselves the burden of calculating with square roots. So, we require that
is a maximum. But not for all (π₯,π¦)! Only for those points which satisfy the equation of the Cartesian leaf! So we have to find a maximum with constraints. That should ring a bell, called βLagrange multipliersβ.
We can put all of the Cartesian leaf equation on one side
and call that π(π₯,π¦). So this function π is the zero function. That means, if you differentiate it with respect to π₯ or π¦, it is still zero. The total differential therefore reads
In Python, we write
Remember that we wanted to calculate the maximum of πΒ². So we demand that
So we have that π(πΒ²)=0 and ππ=0. Therefore, for some constant π (called Lagrange multiplier), we also have
Since both πΒ² and π are functions of π₯ and π¦, this equals
Both ππ₯ and ππ¦ are arbitrary, so this can only be true if the terms in braces are zero. Or in Python:
Solve the first equation for π and insert it in the second to eliminate π:
Not only this equation has to be fulfilled, but also the original equation for the curve. So we have to solve
If you look closely at the output, the solution set only contains one real solution, which is
and thatβs the tip of the leaf.