Wolfram Function Repository
Instant-use add-on functions for the Wolfram Language
Function Repository Resource:
Generate the Lévy C curve
ResourceFunction["LevyCCurve"][n] generates the line segments of the Lévy C curve with n iterations. | |
ResourceFunction["LevyCCurve"][{p1,p2},n] uses the line connecting the points p1 and p2 as the initial line. | |
ResourceFunction["LevyCCurve"][{p1,p2,… ,pn},n] uses the lines joining the points pi. |
Generate the Lévy C curve for four iterations:
In[1]:= |
Out[1]= |
Generate the line for eight iterations and visualize the result:
In[2]:= |
Out[2]= |
Start from a vertical line segment:
In[3]:= |
Out[3]= |
The length of the Lévy C curve grows approximately exponentially:
In[4]:= |
Out[4]= |
"Inward" and "outward" Lévy C curve starting from a square:
In[5]:= |
Out[5]= |
Color the curve along its length:
In[6]:= |
Out[6]= |
This work is licensed under a Creative Commons Attribution 4.0 International License