Modification of Chaos Game with variation of compression ratio

Chaos Game is a form of game drawing a point on a field with certain rules that are repeated iteratively. In general, the new point in the game chaos is the midpoint of the starting point and reference point. The new point is the result of the dilatation with the center of the reference point with a half dilatation factor. The resulting points will form a pattern by paying attention to the nature of self-similarity. This paper will examine the modification of the game chaos rules in generating new points by varying the r compression ratio applied to triangles and rectangles. The compression ratio will be divided into four different intervals. The results of this study indicate that variations in the compression ratio for r = −1, 1orr → +®or 0 < r < 1or −1 < r < 0 do not produce a fractal object, while r > 1or r < −1 will produce a fractal object.


Introduction
Fractal geometry or commonly referred to as fractals is a branch of mathematics that has developed rapidly with the presence of computers as a form of the development of science and technology. Fractals are geometrical objects that are created through repetitive drawing patterns with certain rules. Fractals have various properties, namely self-similarity, which shows that a fractal object is composed of parts similar to itself, and self-affinity shows that fractal objects are arranged by sequential parts. each other [1]. Some common examples of fractals are the Mandelbrot set, the Julia set, the Cantor set, the Sierpinski triangle, the Sierpinski rug, the Menger sponge, the Koch curve. The Sierpinski Triangle can be raised with a technique or a method called Chaos Game.
Chaos Game is a form of drawing a point in a field with certain rules which are done repeatedly iteratively. The use of three points forming a triangle as a reference point by random selection or can be called random Chaos Game and produce a fractal object that is Sierpinski triangle [2]. The Sierpinski Triangle is formed when the distance of the new point in the Chaos Game method must be half of the vertex. When the distance is changed to 1/3 of the vertex, then what is formed is a hexagon on the inside of the triangle. The Sierpinski Triangle is a linear fractal that has an identical selfsimilarity to infinite iterations [3]. Sierpinski's triangle can be generated using affine transformations, namely dilation and translation. Different patterns will be obtained by changing the field under study but still using the initial rules Chaos Game.
Each point located on the line segment in the Sierpinski triangle will be half-dilated with the center of the dilatation at any vertex. The term "dilated halfway with a vertex" gives the same meaning as generating a midpoint of a line segment connecting a vertex with a triangular vertex [4]. Dilation is a form of geometrical transformation that enlarges or reduces an object without changing the shape of the object.
Taking four corner points as a square and four midpoints on each side with the compression ratio used which is r = 3 can produce a Sierpinski carpet which can be seen in Figure 1 [5]. Compression IOP Publishing doi:10.1088/1742-6596/1538/1/012033 2 ratio is a factor in the Chaos Game rules that are used to limit the distance of the starting point and the chosen corner point. Modify the production rules in the Chaos Game to build a Sierpinski hexagon with six vertexes with different production rules, namely changing the distance between the random point and the selected vertex into a factor of three. Or, it can be said that in this game the compression ratio is done to be three [6].
In relation to the rules of Chaos Game, this study will discuss about the rules of Chaos Game with variations in the compression ratio that will be applied at the reference points that form triangles and rectangles.

Research Methods
There are several stages in this research method. The first step is to study literature which aims to obtain information from journals, books, and theses regarding the Chaos Game library and its modifications. Then, the second step is to modify the Chaos Game rules with variations in the compression ratio that are applied at the reference points that form triangles and rectangles.The steps in the algorithm are almost the same for different r and polygons, such as first determining three triangular points, second determining the starting point outside or inside the plane at random, the third choosing a reference point to be associated with the selected starting point randomly, the fourth determines a new point which is spaced α ie 1 from the selected point. Where the compression ratio r is classified into four, namely r = -1.1 or r →±∞, r> 1, r<-1 and 0 <r<1 or -1 <r <0. The fifth step turns the new point from the previous step into the starting point and finally repeats the third step in the order that it can repeat until the specified iteration. Furthermore, for rectangles, the steps are the same but the difference lies in the first step, which is to determine four rectangular points. The third step of this research method is making a simulation program with three stages, namely input, process, and output. The input will input the number of iterations performed on the Chaos Game, the reference point that forms a flat plane, the compression ratio and determine the starting point for starting the Chaos Game. At the stage of the process the visualization of the algorithm is predetermined. As well as the output generated visualization in accordance with a predetermined algorithm.The last step in this research method is to analyze the results. In the analysis of the results the initial hypothesis is determined for each visualization result of the algorithm. Then conduct proof of each visualization result of each algorithm whether it is in accordance with the initial hypothesis or not.

The result
Program simulation is done by varying the compression ratio at the reference point forming triangles and squares. For example, given a reference point between A1, A2, A3 and A4. The selection of the vertex as a reference point is random and the starting point can be outside or inside the plane. The new point in the Chaos Game is obtained from the value α which is 1 the distance between the starting point and the reference point.  After determining the α interval, it is at the same time the case in this study. In the simulation program, it has been explained how to obtain the results of visualization on triangles and squares. Each vertex has a different color so the color of the new point will match the selected reference point.
Case 1: Value α = -1, 0 or 1 In the first case done for α = -1, 0 or 1 with the results of the visualization that can be seen in Figures  2, 3 and 4. In Figure 2 the visualization produced using α = -1. The resulting object is different in each experiment. But it can be seen that each experiment produces dots that form two symmetrical patterns.   Subsequent experiments were applied to the quadrilateral by producing a pattern that was relatively similar to the triangle. In Figure 4(a) it produces two symmetrical shapes, and Figure 4  Thus, the object produced in the first case for r = -1,1 or r →±∞ applied to triangles and rectangles cannot be said to be a fractal because the object does not produce a particular shape and does not have one of the important fractal properties, namely self -Similarity.

Case 2: Value 0 <α <1
The second case is carried out for variations of 0 <α <1 with visualization results which can be seen in Figures 5 and 6. In Figures 5(a), (b), (c) and (d), the points produced in groups resemble triangle shapes with different colors according to the reference point and spread at each reference point, or it can be said that the triangle inside the triangle. Large triangles are composed by other small triangles. Furthermore, in Figure 5(e), (f), (g) and (h) the resulting shapes are less visible and overlap. But it can be seen that each reference point produces the same shape.
In Figures 5(a) through (e) we can see the movement of shapes produced in the middle of the basic structure. There is a condition where a polygon will not be formed in the middle when α = 2/3 shown in Figure 5(f). The three triangles at each reference point intersect. When using a triangle weight line, for example, each reference point A1, A2 and A3 are drawn to the midpoint of the side before it, then the lines intersect at a point equal to the intersection of the three triangles and the ratio of the segments from the vertex as 2 to 1. The center of gravity is the point obtained from the third intersection of the triangle's weight line [7]. The three triangles intersect each other at the center of gravity of the basic shape so that they don't form in the middle of the triangle. In Figure 5(a) to (f) it can be seen that if α is used close to 2/3, the polygon in the middle of the base shape gets smaller. If α is used close to 0 then the polygon in the middle of the base shape is getting bigger.
In Figure 5(a) to (g) the points formed by Chaos Game are gathered in a triangle. When α = 1/2 the object produced is the Sierpinski triangle. If the α used is close to 0 then the resulting points will be attracted to each of the reference points shown in Figures 5(a), (b) and (c). If the α used is close to 1 then the resulting points will move away from the reference point and be pulled toward the middle shown in Figures 5(e), (f), (g) and (h). Subsequent experiments were applied to the quadrilateral by producing a pattern that was relatively similar to the triangle. In Figure 6(a) and (b) the points produced in groups resemble rectangular shapes with different colors according to the reference points and spread at each reference point. Whereas in Figure 6(c) and (d) the resulting shapes are less visible and overlapping. In the triangle when α = 3/2 it no longer produces a shape that is formed in the middle of the base plane while the quadrilateral applies when α = 1/2 no longer produces a shape in the middle of the base plane.
Thus, the object produced in the second case for r> 1 can be said to be a fractal because the object forms a certain pattern and has one of the important properties of fractals, namely self-similarity. If the r used is close to posive infinity(∞) then the fractal property approaches the dust cantor. If the r used is close to 1, the fractal properties are less obvious.

Case 3: Value -1 <α <0
The third case is carried out for variations -1 <α <0 with the visualization results which can be seen in Figures 7 and 8. In this case the resulting pattern is almost the same as the second case except that the points formed are outside the basal plane. The resulting points resemble the shape of a triangle whose composition is opposite each other at each reference point in a different color according to the reference point. Each vertex of a large triangle will form a small triangle that is opposite to each other. The object produced in the third case for r<-1 can be said to be a fractal because the object forms a certain pattern and has one important fractal property, namely self-similarity. If the r used is close to ∞ then the fractal property approaches the dust Cantor. If the r used is close to -1 then the fractal properties are less obvious.

Case 4: Value α> 1 or α <-1
In this section, visualization results for α> 1 or α <-1 will be shown. When α> 1 the visualization results can be seen in Figure 9 using the value α = 2 and iteration of 10. The formed points obtained do not produce a particular shape and do not spread to all points of reference. In Figures 9(a) and (b) can be seen the points produced form like a straight line in a particular direction. The resulting dots will continue to extend away from the base plane. During certain iterations, three reference points will be considered the same as one reference point. The new points generated move from the starting point in a particular direction. The direction of the formation can be seen from the points produced. In Figure 10 the new points produced in the triangle T1 and T2 point to the sides A1A2. Whereas when T3 the direction changes and does not follow the previous point. Location of T3 is outside the right side of the triangle. The next new point does not change direction to the other side. For example, starting point T3 by selecting different reference points A1, A2 and A3 will produce new points T41, T42 and T43 remain on the same side as T3 which can be seen in Figure 10. The next new point will continue to extend in the direction of T3. The location of the first new point that is outside the plane can affect the direction of the points formed. When α <-1 the visualization results can be seen in Figure 11. The results do not produce a particular form until the iteration is determined. The iterations used in this experiment were 20. The formation points did not spread to all reference points. In Figure 11(a) and (b) it can be seen that the points extend in two opposite directions until the iteration is determined. These points look like straight lines. The resulting points will continue to elongate and during certain iterations, three reference points will be considered the same as one reference point. Subsequent experiments were applied to the quadrilateral by producing a pattern that was relatively similar to the triangle. The results of the visualization can be seen in Figure 12(a) and (b). In Figure 12(a) it can be seen that the points produced form a straight line from the starting point in a particular direction. In Figure 12(b) we can see the resulting points extending in two opposite directions until the iteration is determined and looks like a straight line. The resulting dots will continue to extend and stay away from the base plane. Visualization results in the fourth case 0 <r<1 or -1 <r<0 cannot be called a fractal. The resulting object does not form a certain pattern and does not have one of the important properties of fractals, namely self-similarity.
In each experiment with different numbers of reference points forming triangles and quadrilateral, the patterns were relatively similar in each case. The difference in the number of reference points used with the same r value does not affect the resulting pattern. However, the resulting shape is different from following the basic shapes used.

Conclusions and suggestions
Based on the results and discussion, simulations that have been carried out by modifying the Chaos Game rules with variations in the compression ratio r applied to triangles and rectangles randomly for r = -1.1 or r →±∞ or 0 <r<1 or -1 <r<0 do not produce a fractal object and r> 1 or r<-1 produce a fractal object.Chaos Game rules with variations in the compression ratio r have the same relative effect for triangles and quadrilateral.
In this study, a modified Chaos Game with variations in compression ratios applied to triangles and rectangles was randomly limited to analyzing program results. It is expected that in subsequent research analytical studies can be developed for the formation of fractal patterns at each compression ratio.