Wolfram Function Repository
Instant-use add-on functions for the Wolfram Language
Function Repository Resource:
Display a given number of rows in the Leibniz harmonic triangle
ResourceFunction["LeibnizHarmonicTriangle"][n] creates a two level table representing the first n rows of Leibniz's harmonic triangle. | |
ResourceFunction["LeibnizHarmonicTriangle"][r,c] returns the c-th element in the r-th row of the triangle. |
Display the first five rows of Leibniz's triangle:
In[1]:= | ![]() |
Out[1]= | ![]() |
Show them as a triangle:
In[2]:= | ![]() |
Out[2]= | ![]() |
Reverse hockey-stick property: the blue number 1/3 equals the infinite sum of the numbers along the orange line or the 4th diagonal:
In[3]:= | ![]() |
In[4]:= | ![]() |
In[5]:= | ![]() |
Out[5]= | ![]() |
Verify with symbolic summation with the definition of Leibniz triangle by built-in Beta function:
In[6]:= | ![]() |
Out[6]= | ![]() |
In general the infinite sum along c-th column is L(c-1,c-1):
In[7]:= | ![]() |
Out[7]= | ![]() |
In[8]:= | ![]() |
Out[8]= | ![]() |
The sum of denominators in r-th row is r·2r-1:
In[9]:= | ![]() |
In[10]:= | ![]() |
Out[10]= | ![]() |
In[11]:= | ![]() |
Out[11]= | ![]() |
The Leibniz harmonic triangle is related to binomial triangle:
In[12]:= | ![]() |
Out[12]= | ![]() |
In[13]:= | ![]() |
Out[13]= | ![]() |
In[14]:= | ![]() |
Out[14]= | ![]() |
The original Sierpiński triangle pattern:
In[15]:= | ![]() |
In[16]:= | ![]() |
Out[16]= | ![]() |
Sierpiński triangle using fraction mod 3:
In[17]:= | ![]() |
Out[18]= | ![]() |
Sierpiński triangle using fraction mod 5:
In[19]:= | ![]() |
Out[20]= | ![]() |
Wolfram Language 14.0 (January 2024) or above
This work is licensed under a Creative Commons Attribution 4.0 International License