I would like to know how to draw these kolams/rangoli programmatically. in any language, what kind of math is required? They are fascinating works of symmetry, thus I feel it should be possible, but don't know where to start.
-
This isn't really a mathematics question, so it may be closed here. I suspect there are folks at http://tex.stackexchange.com who would tackle this problem with the TeX tikz package. You might consider posting it there instead. (If you post in both places please link each question to the other). – Ethan Bolker Mar 13 '17 at 13:52
-
3If the OP knows an algorithm for tracing and wants help implementing said algorithm, I'd agree that it's off topic. But I think a big part of the question is knowing what the path of the curve should be. (Interested readers may want to look up the works of Claudia Zaslavsky (possibly Ascher too, I forget), whose son Thomas is also a mathematician!) – pjs36 Mar 13 '17 at 21:48
-
The program Mathematica is also an option. Downside compared to TeX is that it is not free. – Paul Mar 13 '17 at 21:52
-
1@Suraj the closest thing to your patterns I can recall is a "Hilbert curve", a continuous fractal-space filling curve. You might get ideas about how to modify the fractal to obtain something closer to your designs. There is some code too in the wiki page. It is not the same but could be a starting point. Good luck! https://en.wikipedia.org/wiki/Hilbert_curve. – iadvd Mar 13 '17 at 23:40
-
1@iadvd you may also look into "Kolams indiens, dessins sur le sable aux îles Vanuatu, courbe de Sierpinski et morphismes de monoïde." by G. & J.-P. Allouche from France about monoid Morphism, the Sierpinski curve and Kolam sand-designs on the Vanuatu islands. https://webusers.imj-prg.fr/~jean-paul.allouche/kolam.pdf – stefan123t Oct 14 '24 at 20:47
-
@stefan123t Than you very much! That sounds fantastic. I will have a look as soon as possible! I was also aware of the Molas Kunas (Colombia). They also use traditionally designs that extend to the whole available space through recursions. Not so evident as the designs shown in this question, but quite close. Just in case here is a link, cheers!: https://en.wikipedia.org/wiki/Mola_(art_form) – iadvd Oct 21 '24 at 23:50
2 Answers
There is a research paper from Kiwamu Yanagisawa and Shijiro Nagata: "Fundamental Study on Design System of Kolam Pattern" e.g. here https://www.researchgate.net/publication/237442288_Fundamental_Study_on_Design_System_of_Kolam_Pattern
YANAGISAWA, Kiwamu & NAGATA, Shojiro. (2007). Fundamental Study on Design System of Kolam Pattern. "Kolam" is a kind of string/knot pattern seen primarily in Tamilnadu state of South India, which has a very attractive system of pattern formation, that is to say, countless complicated Kolam patterns can be drawn following extremely simple elements and drawing rules. In this paper, the fundamental characteristic of Kolam patterns' designing system is considered by converting these patterns into numbers and linear diagrams. Further discussions on the drawing methods to create new Kolams will also be given.
There is a set of 16 (sic) basic curve shapes at / around each dot which can be represented with the hexadecimal numbers 0x0 .. 0xF.
Table 1. 16 Constituent units of Kolam Patterns, corresponding to hexadecimal numbers.

The shapes are called with names (circle, drop, saddle, pupil, fan and diamond) and can be described by a matrix of 4 bits (0, 0, 0, 0) to (1, 1, 1, 1). The least significant bit is the one which is defined for the lower, right corner in a 2*2 convolution. You have to slant this matrix 45° into the right hand direction, so the center point of the convolution is on the diagonal of the resulting 1-3-1 diamond shape. The LSB (Bit 0) is then the lower corner, Bit 1 is the left corner, Bit 3 is the right corner and MSB (Bit 4) is the top corner of this slanted 2x2 matrix or 1-3-1 diamond shape. Each bit signifies either no connection (tangent) or a crossing of the lines surrounding the 5 points. So with the four potential connections around each point we can create exactly 16 different elemental shapes which have designated names and symmetrical / mirror properties.
I tried to add a description of the individual shapes in Table 1 and its rotational and mirror symmetrical properties in the following list:
- 0 circle (N°, fully rotational symmetric)
- 1 drop (180°, upwards)
- 2 drop (270°, right)
- 3 saddle (225°)
- 4 drop (90°, left)
- 5 saddle (135°)
- 6 pupil (0°, 180° symmetry, horizontal mirror)
- 7 fan (0°, upright)
- 8 drop (0°, down)
- 9 pupil (90° / 180° symmetry, vertical mirror)
- A saddle (-45° / 315°)
- B fan (90°, right)
- C saddle (45°)
- D fan (270°, left)
- E fan (180°, down)
- F diamond (90° rotational symmetry)
With that "simple" language you can describe & define all possible Kolam pattern's that adhere to the given definition.
The authors continue on to review special properties of Kolam's with 5x5 and 7x7 diamond shapes:
Some of these special Kolam pattern's have a lot in common with convolution kernels used in image manipulation, pattern recognition, convolutional neural networks and deep learning. If you look at it from a 45° angle you can see how the convolution matrix and the underlying equations are calculated (e.g. in respect to FFT's).
See here a screenshot detailing the simple 3*3 vector convolution of (1,2,3) * (4,5,6) = (4,13,28,27,18) from a recent video by Grant "3 Blue 1 Brown" Sanderson
$(1+2x+3x^2)(4+5x+6x^2) = 4+13x+28x^2+27x^3+18x^4$
| $1$ | $2x$ | $3x^2$ | |
|---|---|---|---|
| $4$ | 4 | 8 | 12 |
| $5x$ | 5 | 10 | 15 |
| $6x^2$ | 6 | 12 | 18 |
But what is a convolution? https://www.youtube.com/watch?v=KuXjwB4LzSA
- 181
-
-
I did not know how to format the images right to convey the message I was trying to get over. Here unfortunately an image says more than a thousand words. I would suggest to read the other excellent research papers by Shojiro Nagata of the InterVision Institute as they also explain how they make this comprehensible to blind persons or persons with learning disabilities. The original poster may also want to "look" at the implementation of the OnMouseKolamDrawer – stefan123t Jan 26 '23 at 16:56
-
-
1
-
1@SidharthGhoshal there is a paper on the "Kolam designs based on Fibonacci series" by S. Naranan, et. al. https://www.nieuwarchief.nl/serie5/pdf/naw5-2019-20-3-195.pdf which goes into explaining why any four-integer sequence of the Fibonacci series starting with an even number (every third is even) would allow to construct a square kolam. It also mentions the so called Edouard Zeckendorf array. Maybe Professor Naranan from Chennai can contribute more to his research when contacted over his homepage: https://vindhiya.com/Naranan/Fibonacci-Kolams/ – stefan123t Oct 14 '24 at 20:10
-
1I am not aware of a OEIS sequence counting the 240 one-stroke-able 1-5-1 kolam patterns in the above paper nor for any arbitrary array sized kolam patterns. This may be a subject for further research.
There was a conference program on "Combinatorial Enumeration of rectangular kolam designs of the Tamil land." by Rethinasamy K Kittappa at the Joint Mathematics Meetings San Diego, CA, January 6-9, 2008 but I could not get hold of a digital copy of the lecture notes online.
– stefan123t Oct 14 '24 at 20:10 -
1See here for the program outline and details Joint Mathematics Meetings Program by Day https://jointmathematicsmeetings.org/meetings/national/jmm/2109_program_tuesday.html – stefan123t Oct 14 '24 at 20:17
-
Just seeing this now, here is a LaTeX-Tikz code for the same.
\documentclass{article}
\usepackage{tikz} % Required for inserting images
\usetikzlibrary{shapes}
\usetikzlibrary{plotmarks}
\usetikzlibrary{calc,arrows,hobby}
\def\centerarc#1(#3:#4:#5) { \draw[#1] ($(#2)+({#5cos(#3)},{#5sin(#3)})$) arc (#3:#4:#5); }
\begin{document}
\begin{tikzpicture}
\filldraw (5,5) circle (3pt);
\filldraw (3.5858,5) circle (3pt);
\filldraw (2.1716,5) circle (3pt);
\filldraw (.7574,5) circle (3pt);
\filldraw (-.6568,5) circle (3pt);
\filldraw (3.5858,3.5858) circle (3pt);
\filldraw (.7574,3.5858) circle (3pt);
\filldraw (2.1716,3.5858) circle (3pt);
\filldraw (2.1716,2.1716) circle (3pt);
\filldraw (3.5858,6.4142) circle (3pt);
\filldraw (2.1716,6.4142) circle (3pt);
\filldraw (.7574,6.4142) circle (3pt);
\filldraw (2.1716,7.8284) circle (3pt);
%\draw [-,very thick] (-4,5) to[out=90,in=180] (-2,6);
%\draw (-4,5) to[curve through={(-3,6)}] (-2.293,5.707);
%\draw (-2.293,5.707) to (-2,5);
%\centerarcred,thick(215:45:1)
\centerarcred,thick(315:45:.5)
\draw [red,thick] (-.30325,5.35355) -- (1.1109,3.9393);
\centerarcred,thick(45:0:.5)
\centerarcred,thick(-180:0:.5)
\centerarcred,thick(135:180:.5)
\draw [red,thick] (.7574,4.2929) -- (3.2323, 6.7677);
\draw [red,thick] (.7574,4.2929) -- (.4039,3.9385);
\centerarcred,thick(0:135:.5)
\centerarcred,thick(225:360:.5)
\draw [red,thick] (3.2323,6.0607) -- (1.8181,7.4749);
\centerarcred,thick(0:225:.5)
\centerarcred,thick(315:360:.5)
\draw [red,thick] (2.5251,7.4749) -- (1.1109,6.0607);
\centerarcred,thick(45:315:.5)
\draw [red,thick] (2.5251,5.3535) -- (1.1109,6.7677);
\centerarcred,thick(315:405:.5)
\draw [red,thick] (2.5251,2.5251) -- (1.8181,3.2323);
\centerarcred,thick(135:225:.5)
\draw [red,thick] (2.5251, 4.6465) -- (1.8181,3.9385);
\centerarcred,thick(135:405:.5)
\draw [red,thick] (1.8180,2.5251) -- (4.6644,5.37);
\centerarcred,thick(225:495:.5)
\draw [red,thick] (4.6465,4.6465) -- (3.9393,5.3535);
\centerarcred,thick(45:225:.5)
\draw [red,thick] (3.2323,4.6465) -- (3.9391,3.9391);
\centerarcred,thick(225:405:.5)
\draw [red,thick] (3.2323,3.2323) -- (1.1109,5.3535);
\centerarcred,thick(45:135:.5)
\draw [red,thick] (.4039,5.3535) -- (-.3033,4.6465);
\end{tikzpicture}
\end{document}
- 22,850
- 9
- 28
- 48
- 31
-
Thanks for your LaTeX-Tikz example. Is it possible to define the primitives (circle, drop, saddle, pupil, fan, diamond) and use a "meta-language" LaTeX-plugin based on Tikz e.g. an hex-array to describe the kolam designs ? Maybe adding an option to pre-/post-rotate the designs by 45° degree (counter-)clockwise would allow most kolam designs to be specified in simple terms. – stefan123t Oct 14 '24 at 20:23



